reactivate artist button ready for new artist treeview

Esse commit está contido em:
fossfreedom
2013-10-31 21:57:05 +00:00
commit 7027112b58
6 arquivos alterados com 62 adições e 6 exclusões
+23 -1
Ver Arquivo
@@ -52,7 +52,7 @@ class ArtistShowingPolicy(GObject.Object):
self._album_manager = album_manager
self._model = album_manager.model
class ArtistView(AbstractView):
class ArtistView(Gtk.TreeView, AbstractView):
__gtype_name__ = "ArtistView"
name = 'artistview'
@@ -64,9 +64,31 @@ class ArtistView(AbstractView):
self._external_plugins = None
self.gs = GSetting()
self.show_policy = ArtistShowingPolicy(self)
self.view = self
self._has_initialised = False
def initialise(self, source):
if self._has_initialised:
return
self._has_initialised = True
self.view_name = "artist_view"
self.source = source
self.plugin = source.plugin
self.shell = source.shell
self.album_manager = source.album_manager
self.ext_menu_pos = 6
self._connect_properties()
self._connect_signals()
def _connect_properties(self):
setting = self.gs.get_setting(self.gs.Path.PLUGIN)
pass
def _connect_signals(self):
pass
def get_view_icon_name(self):
+4 -4
Ver Arquivo
@@ -979,8 +979,6 @@ class Toolbar(GObject.Object):
builder.get_object(button).controller = controller
if not webkit_support():
button = builder.get_object('iconview_button')
button.set_visible(False)
button = builder.get_object('flowview_button')
button.set_visible(False)
separator = builder.get_object('properties_separator')
@@ -1103,7 +1101,7 @@ class ToolbarManager(GObject.Object):
controllers['iconview_button'] = viewmgr.controller
controllers['flowview_button'] = viewmgr.controller
#controllers['artistview_button'] = viewmgr.controller
controllers['artistview_button'] = viewmgr.controller
return controllers
@@ -1138,7 +1136,9 @@ class ViewManager(GObject.Object):
'ui/coverart_iconview.ui'))
self._views[CoverIconView.name] = ui.get_object('covers_view')
self._views[CoverFlowView.name] = CoverFlowView()
self._views[ArtistView.name] = ArtistView()
ui.add_from_file(rb.find_plugin_file(source.plugin,
'ui/coverart_artistview.ui'))
self._views[ArtistView.name] = ui.get_object('artist_view')
self._lastview = None
self.controller = ViewController(source.plugin, self)
+3 -1
Ver Arquivo
@@ -32,6 +32,9 @@
<glade-widget-class title="CoverIconView" name="CoverIconView"
generic-name="CoverIconView" parent="GtkIconView"
icon-name="widget-gtk-iconview"/>
<glade-widget-class title="ArtistView" name="ArtistView"
generic-name="ArtistView" parent="GtkTreeView"
icon-name="widget-gtk-treeview"/>
<glade-widget-class title="PanedCollapsible" name="PanedCollapsible"
generic-name="PanedCollapsible" parent="GtkPaned"
icon-name="widget-gtk-paned"/>
@@ -49,5 +52,4 @@
<glade-widget-class-ref name="EnhancedIconView"/>
<glade-widget-class-ref name="PanedCollapsible"/>
</glade-widget-group>
</glade-catalog>
+12
Ver Arquivo
@@ -0,0 +1,12 @@
<?xml version="1.0" encoding="UTF-8"?>
<interface>
<!-- interface-requires gtk+ 3.0 -->
<!-- interface-requires coverart_widgets 1.0 -->
<object class="ArtistView" id="artist_view">
<property name="visible">True</property>
<property name="can_focus">True</property>
<property name="hexpand">True</property>
<property name="tooltip_column">0</property>
<property name="object_column">2</property>
</object>
</interface>
+1
Ver Arquivo
@@ -210,6 +210,7 @@
<object class="ImageRadioButton" id="artistview_button">
<property name="label">Artist</property>
<property name="use_action_appearance">False</property>
<property name="visible">True</property>
<property name="can_focus">True</property>
<property name="receives_default">False</property>
<property name="use_action_appearance">False</property>
+19
Ver Arquivo
@@ -185,6 +185,25 @@
<property name="position">1</property>
</packing>
</child>
<child>
<object class="ImageRadioButton" id="artistview_button">
<property name="label" translatable="yes">Artist</property>
<property name="use_action_appearance">False</property>
<property name="visible">True</property>
<property name="can_focus">True</property>
<property name="receives_default">False</property>
<property name="halign">center</property>
<property name="use_action_appearance">False</property>
<property name="xalign">0.5</property>
<property name="draw_indicator">False</property>
<property name="group">iconview_button</property>
</object>
<packing>
<property name="expand">False</property>
<property name="fill">True</property>
<property name="position">2</property>
</packing>
</child>
</object>
<packing>
<property name="expand">False</property>