def _switch_widget_icons(self, widget, icon_id):
"""
Switch icon type version ``regular`` to ``activated`` or the other way
around depending on ``widget`` current icon.
:param widget: :class:`Gtk.ToolButton`
:param icon_id: icon name as :class:`str`
"""
icon = self.images.switch_icon_version(icon_id, widget.get_icon_widget())
widget.set_icon_widget(icon)
widget.show_all()
评论列表
文章目录