[banshee] [Last.fm] Add the Last.fm badge in the preferences page



commit 422071c639f54a6540418720183b7ee46d4cd273
Author: Bertrand Lorentz <bertrand lorentz gmail com>
Date:   Sat Nov 14 14:16:24 2009 +0100

    [Last.fm] Add the Last.fm badge in the preferences page
    
    Displaying a button linking to Last.fm is required by their Terms of
    Service : http://www.last.fm/api/tos, paragraph 2.7.

 .../Banshee.Lastfm.Radio/LastfmSource.cs           |    7 ++++++-
 1 files changed, 6 insertions(+), 1 deletions(-)
---
diff --git a/src/Extensions/Banshee.Lastfm/Banshee.Lastfm.Radio/LastfmSource.cs b/src/Extensions/Banshee.Lastfm/Banshee.Lastfm.Radio/LastfmSource.cs
index b01dde1..445073a 100644
--- a/src/Extensions/Banshee.Lastfm/Banshee.Lastfm.Radio/LastfmSource.cs
+++ b/src/Extensions/Banshee.Lastfm/Banshee.Lastfm.Radio/LastfmSource.cs
@@ -33,6 +33,7 @@ using System.Collections.Generic;
 using Mono.Unix;
 
 using Lastfm;
+using Lastfm.Gui;
 using Hyena.Data;
 
 using Banshee.Base;
@@ -349,8 +350,12 @@ namespace Banshee.Lastfm.Radio
 
             signup_button.Visible = String.IsNullOrEmpty (user_pref.Value);
 
+            var button_box = new Gtk.HBox () { Spacing = 6 };
+            button_box.PackStart (new Badge (account) { Visible = true}, false, false, 0);
+            button_box.PackStart (signup_button, true, true, 0);
+
             user_pref.DisplayWidget = auth_box;
-            pref_section["lastfm-signup"].DisplayWidget = signup_button;
+            pref_section["lastfm-signup"].DisplayWidget = button_box;
         }
 
         public override string PreferencesPageId {



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