[Banshee-List] Hello from Germany



Hello Aaron,

Well to the point I was missing the support for the Genre of the tracks, I looked at the code and saw that only the GUI
part was missing so I went ahead and implement it. 

I am attaching the patch files for the changes, I hope you like it and use it.

regards,

Oscar Forero
? Makefile
? Makefile.in
? banshee.desktop
? banshee.gladep
? banshee.schemas
? images
? org.gnome.Banshee.service
Index: banshee.glade
===================================================================
RCS file: /cvs/gnome/banshee/data/banshee.glade,v
retrieving revision 1.6
diff -r1.6 banshee.glade
20d19
<   <property name="urgency_hint">False</property>
484d482
<   <property name="urgency_hint">False</property>
842c840
< 		  <property name="n_rows">3</property>
---
> 		  <property name="n_rows">4</property>
1113a1112,1200
> 
> 		  <child>
> 		    <widget class="GtkHBox" id="hbox15">
> 		      <property name="visible">True</property>
> 		      <property name="homogeneous">False</property>
> 		      <property name="spacing">5</property>
> 
> 		      <child>
> 			<widget class="GtkButton" id="GenreSync">
> 			  <property name="visible">True</property>
> 			  <property name="can_focus">True</property>
> 			  <property name="relief">GTK_RELIEF_NORMAL</property>
> 			  <property name="focus_on_click">True</property>
> 
> 			  <child>
> 			    <widget class="GtkImage" id="image9">
> 			      <property name="visible">True</property>
> 			      <property name="stock">gtk-copy</property>
> 			      <property name="icon_size">1</property>
> 			      <property name="xalign">0.5</property>
> 			      <property name="yalign">0.5</property>
> 			      <property name="xpad">0</property>
> 			      <property name="ypad">0</property>
> 			    </widget>
> 			  </child>
> 			</widget>
> 			<packing>
> 			  <property name="padding">0</property>
> 			  <property name="expand">False</property>
> 			  <property name="fill">False</property>
> 			</packing>
> 		      </child>
> 
> 		      <child>
> 			<widget class="GtkLabel" id="label63">
> 			  <property name="visible">True</property>
> 			  <property name="label" translatable="yes">_Genre</property>
> 			  <property name="use_underline">True</property>
> 			  <property name="use_markup">False</property>
> 			  <property name="justify">GTK_JUSTIFY_LEFT</property>
> 			  <property name="wrap">False</property>
> 			  <property name="selectable">False</property>
> 			  <property name="xalign">0.5</property>
> 			  <property name="yalign">0.5</property>
> 			  <property name="xpad">0</property>
> 			  <property name="ypad">0</property>
> 			  <property name="mnemonic_widget">Title</property>
> 			  <property name="ellipsize">PANGO_ELLIPSIZE_NONE</property>
> 			  <property name="width_chars">-1</property>
> 			  <property name="single_line_mode">False</property>
> 			  <property name="angle">0</property>
> 			</widget>
> 			<packing>
> 			  <property name="padding">0</property>
> 			  <property name="expand">False</property>
> 			  <property name="fill">False</property>
> 			</packing>
> 		      </child>
> 		    </widget>
> 		    <packing>
> 		      <property name="left_attach">0</property>
> 		      <property name="right_attach">1</property>
> 		      <property name="top_attach">3</property>
> 		      <property name="bottom_attach">4</property>
> 		      <property name="x_options">fill</property>
> 		      <property name="y_options">fill</property>
> 		    </packing>
> 		  </child>
> 
> 		  <child>
> 		    <widget class="GtkEntry" id="Genre">
> 		      <property name="visible">True</property>
> 		      <property name="can_focus">True</property>
> 		      <property name="editable">True</property>
> 		      <property name="visibility">True</property>
> 		      <property name="max_length">0</property>
> 		      <property name="text" translatable="yes"></property>
> 		      <property name="has_frame">True</property>
> 		      <property name="invisible_char">*</property>
> 		      <property name="activates_default">False</property>
> 		    </widget>
> 		    <packing>
> 		      <property name="left_attach">1</property>
> 		      <property name="right_attach">2</property>
> 		      <property name="top_attach">3</property>
> 		      <property name="bottom_attach">4</property>
> 		      <property name="y_options"></property>
> 		    </packing>
> 		  </child>
1417c1504
< 	  <property name="expanded">False</property>
---
> 	  <property name="expanded">True</property>
1936d2022
<   <property name="urgency_hint">False</property>
2234d2319
<   <property name="urgency_hint">False</property>
? AmazonSearchService.cs
? AssemblyInfo.cs
? Banshee.Base
? Banshee.Dap
? Banshee.MediaEngine
? Banshee.Plugins
? Banshee.Widgets
? GtkSharpBackports
? Makefile
? Makefile.in
? MusicBrainz
? banshee
? banshee.exe.config
? banshee.exe.mdb
Index: PlayerInterface.cs
===================================================================
RCS file: /cvs/gnome/banshee/src/PlayerInterface.cs,v
retrieving revision 1.134
diff -r1.134 PlayerInterface.cs
440a441
>             fields.Add(Catalog.GetString("Genre"));
1538a1540,1541
>             } else if(field == Catalog.GetString("Genre")) {
>                 match = ti.Genre;
1543c1546,1547
<                     ti.Title
---
>                     ti.Title,
> 					ti.Genre
Index: PlaylistView.cs
===================================================================
RCS file: /cvs/gnome/banshee/src/PlaylistView.cs,v
retrieving revision 1.37
diff -r1.37 PlaylistView.cs
57a58
> 			Genre,
91a93,95
>             columns.Add(new PlaylistColumn(this, Catalog.GetString("Genre"), "Genre", 
>                 new TreeCellDataFunc(TrackCellGenre), new CellRendererText(),
>                 3, (int)ColumnId.Genre));
94c98
<                 3, (int)ColumnId.Album));
---
>                 4, (int)ColumnId.Album));
97c101
<                 4, (int)ColumnId.Time));
---
>                 5, (int)ColumnId.Time));
99c103
<             PlaylistColumn _RatingColumn = new PlaylistColumn(this, 
---
> 			PlaylistColumn _RatingColumn = new PlaylistColumn(this, 
102c106
<                 5, (int)ColumnId.Rating);
---
>                 6, (int)ColumnId.Rating);
110c114
<                 6, (int)ColumnId.PlayCount);
---
>                 7, (int)ColumnId.PlayCount);
118c122
<                 7, (int)ColumnId.LastPlayed);
---
>                 8, (int)ColumnId.LastPlayed);
398c402,413
<         protected void TrackCellAlbum(TreeViewColumn tree_column,
---
>         protected void TrackCellGenre(TreeViewColumn tree_column,
>             CellRenderer cell, TreeModel tree_model, TreeIter iter)
>         {
>             TrackInfo ti = model.IterTrackInfo(iter);
>             if(ti == null) {
>                 return;
>             }
>             
>             SetRendererAttributes((CellRendererText)cell, ti.Genre, iter);
>         }
>         
> 		protected void TrackCellAlbum(TreeViewColumn tree_column,
Index: TrackProperties.cs
===================================================================
RCS file: /cvs/gnome/banshee/src/TrackProperties.cs,v
retrieving revision 1.21
diff -r1.21 TrackProperties.cs
46a47
> 		public string Genre;
62a64
> 			Genre = track.Genre;
72a75
> 			track.Genre = Genre;
99a103,104
>         [Widget] private Button GenreSync;
>         [Widget] private Label GenreLabel;
104a110
>         [Widget] private Entry Genre;
151a158
>             GenreSync.Clicked += OnGenreSyncClicked;
155a163
> 			Genre.Changed += OnValueEdited;
166a175
>             GenreSync.Visible = TrackSet.Count > 1;
173a183
>             tips.SetTip(GenreSync, Catalog.GetString("Set all Genres to this value"), "genres");
210a221
>             (glade["Genre"] as Entry).Text = track.Genre;
323a335,341
>         private void OnGenreSyncClicked(object o, EventArgs args)
>         {
>             foreach(EditorTrack track in TrackSet) {
>                 track.Genre = Genre.Text;
>             }
>         }
>         
336a355
> 			track.Genre = Genre.Text;


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]