[banshee] Set tooltip and sensitive for location Reset btn
- From: Gabriel Burt <gburt src gnome org>
- To: svn-commits-list gnome org
- Cc:
- Subject: [banshee] Set tooltip and sensitive for location Reset btn
- Date: Wed, 23 Sep 2009 01:37:24 +0000 (UTC)
commit ec664709b944d70cb754bf6e3719c85485f2e2ed
Author: Gabriel Burt <gabriel burt gmail com>
Date: Tue Sep 22 18:22:25 2009 -0700
Set tooltip and sensitive for location Reset btn
.../DefaultPreferenceWidgets.cs | 6 +++++-
1 files changed, 5 insertions(+), 1 deletions(-)
---
diff --git a/src/Core/Banshee.ThickClient/Banshee.Preferences.Gui/DefaultPreferenceWidgets.cs b/src/Core/Banshee.ThickClient/Banshee.Preferences.Gui/DefaultPreferenceWidgets.cs
index 5bc5f3e..41e5d29 100644
--- a/src/Core/Banshee.ThickClient/Banshee.Preferences.Gui/DefaultPreferenceWidgets.cs
+++ b/src/Core/Banshee.ThickClient/Banshee.Preferences.Gui/DefaultPreferenceWidgets.cs
@@ -116,7 +116,10 @@ namespace Banshee.Preferences.Gui
box.Spacing = 2;
box.PackStart (new Image (Stock.Undo, IconSize.Button), false, false, 0);
box.PackStart (new Label (Catalog.GetString ("Reset")), false, false, 0);
- reset = new Button ();
+ reset = new Button () {
+ Sensitive = dir != source.DefaultBaseDirectory,
+ TooltipText = String.Format (Catalog.GetString ("Reset location to default ({0})"), source.DefaultBaseDirectory)
+ };
reset.Clicked += OnReset;
reset.Add (box);
@@ -145,6 +148,7 @@ namespace Banshee.Preferences.Gui
private void OnChooserChanged (object o, EventArgs args)
{
preference.Value = chooser.Filename;
+ reset.Sensitive = chooser.Filename != source.DefaultBaseDirectory;
}
protected override void OnUnrealized ()
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]