diff --git a/deluge/ui/gtkui/glade/preferences_dialog.ui b/deluge/ui/gtkui/glade/preferences_dialog.ui
index f41c218f1..defa382b4 100644
--- a/deluge/ui/gtkui/glade/preferences_dialog.ui
+++ b/deluge/ui/gtkui/glade/preferences_dialog.ui
@@ -431,7 +431,7 @@
False
False
- 5
+ 3
0
@@ -763,7 +763,7 @@ and daemon (does not apply in Standalone mode).
False
False
- 5
+ 3
1
@@ -839,7 +839,7 @@ and daemon (does not apply in Standalone mode).
False
False
- 5
+ 3
2
@@ -878,7 +878,56 @@ and daemon (does not apply in Standalone mode).
-
+
+
True
False
10
@@ -898,11 +947,11 @@ and daemon (does not apply in Standalone mode).
True
True
- 1
+ 2
-
+
True
False
10
@@ -919,30 +968,6 @@ and daemon (does not apply in Standalone mode).
-
- True
- True
- 2
-
-
-
-
- True
- False
- 10
-
-
- Enable Application Indicator
- False
- True
- False
- False
- False
- True
- True
-
-
-
True
True
@@ -950,7 +975,7 @@ and daemon (does not apply in Standalone mode).
-
+
True
False
3
@@ -976,12 +1001,12 @@ and daemon (does not apply in Standalone mode).
-
+
True
False
20
-
+
True
False
5
@@ -1046,7 +1071,7 @@ and daemon (does not apply in Standalone mode).
False
True
- 5
+ 3
3
@@ -1699,18 +1724,6 @@ used sparingly.
GTK_FILL
-
-
-
-
-
-
-
-
-
-
-
-
True
@@ -1743,6 +1756,18 @@ used sparingly.
+
+
+
+
+
+
+
+
+
+
+
+
True
@@ -1982,12 +2007,6 @@ used sparingly.
GTK_FILL
-
-
-
-
-
-
True
@@ -2020,6 +2039,12 @@ used sparingly.
+
+
+
+
+
+
diff --git a/deluge/ui/gtkui/preferences.py b/deluge/ui/gtkui/preferences.py
index 25cd0d583..fc6a4a29d 100644
--- a/deluge/ui/gtkui/preferences.py
+++ b/deluge/ui/gtkui/preferences.py
@@ -188,6 +188,14 @@ class Preferences(component.Component):
"on_checkbutton_language_toggled": self._on_checkbutton_language_toggled,
})
+ if not deluge.common.osx_check() and not deluge.common.windows_check():
+ try:
+ import appindicator
+ except ImportError:
+ pass
+ else:
+ self.builder.get_object("alignment_tray_type").set_visible(True)
+
from deluge.ui.gtkui.gtkui import DEFAULT_PREFS
self.COLOR_DEFAULTS = {}
for key in ("missing", "waiting", "downloading", "completed"):
@@ -489,7 +497,7 @@ class Preferences(component.Component):
self.gtkui_config["close_to_tray"])
self.builder.get_object("chk_start_in_tray").set_active(
self.gtkui_config["start_in_tray"])
- self.builder.get_object("chk_enable_appindicator").set_active(
+ self.builder.get_object("radio_appind").set_active(
self.gtkui_config["enable_appindicator"])
self.builder.get_object("chk_lock_tray").set_active(
self.gtkui_config["lock_tray"])
@@ -654,7 +662,7 @@ class Preferences(component.Component):
new_gtkui_config["start_in_tray"] = \
self.builder.get_object("chk_start_in_tray").get_active()
new_gtkui_config["enable_appindicator"] = \
- self.builder.get_object("chk_enable_appindicator").get_active()
+ self.builder.get_object("radio_appind").get_active()
new_gtkui_config["lock_tray"] = \
self.builder.get_object("chk_lock_tray").get_active()
passhex = sha(self.builder.get_object("txt_tray_password").get_text()).hexdigest()
@@ -863,7 +871,7 @@ class Preferences(component.Component):
"spin_outgoing_port_max": False},
"chk_use_tray": {"chk_min_on_close": True,
"chk_start_in_tray": True,
- "chk_enable_appindicator": True,
+ "alignment_tray_type": True,
"chk_lock_tray": True},
"chk_lock_tray": {"txt_tray_password": True,
"password_label": True},