diff --git a/src/dorkbox/systemTray/SystemTray.java b/src/dorkbox/systemTray/SystemTray.java index e46fcfd..bbf0009 100644 --- a/src/dorkbox/systemTray/SystemTray.java +++ b/src/dorkbox/systemTray/SystemTray.java @@ -94,11 +94,10 @@ class SystemTray { @Property /** Enables auto-detection for the system tray. This should be mostly successful. *
- * Auto-detection will use DEFAULT_WINDOWS_SIZE or DEFAULT_LINUX_SIZE as a 'base-line' for determining what size to use. On Linux, - * `gsettings get org.gnome.desktop.interface scaling-factor` is used to determine the scale factor (for HiDPI configurations). + * Auto-detection will use DEFAULT_TRAY_SIZE or DEFAULT_MENU_SIZE as a 'base-line' for determining what size to use. *
- * If auto-detection fails and the incorrect size is detected or used, disable this and specify the correct DEFAULT_WINDOWS_SIZE or
- * DEFAULT_LINUX_SIZE to use them instead
+ * If auto-detection fails and the incorrect size is detected or used, disable this and specify the correct DEFAULT_TRAY_SIZE or
+ * DEFAULT_MENU_SIZE instead
*/
public static boolean AUTO_TRAY_SIZE = true;
@@ -476,7 +475,7 @@ class SystemTray {
// Fedora KDE requires GtkStatusIcon
trayType = selectTypeQuietly(useNativeMenus, TrayType.GtkStatusIcon);
} else {
- // kde (at least, plasma 5.5.6) requires appindicator
+ // kde (at least, plasma 5.5.6) requires appindicator
trayType = selectTypeQuietly(useNativeMenus, TrayType.AppIndicator);
}
@@ -487,7 +486,11 @@ class SystemTray {
// http://bazaar.launchpad.net/~wingpanel-devs/wingpanel/trunk/view/head:/sample/SampleIndicator.vala
if (!useNativeMenus && AUTO_FIX_INCONSISTENCIES) {
- logger.warn("Cannot use non-native menus with pantheon (elementaryOS). Forcing native menus.");
+ if (OS.isElementaryOSInstalled()) {
+ logger.warn("Cannot use non-native menus with pantheon (elementaryOS). Forcing native menus.");
+ } else {
+ logger.warn("Cannot use non-native menus with pantheon DE. Forcing native menus.");
+ }
useNativeMenus = true;
}
@@ -504,6 +507,21 @@ class SystemTray {
}
if ("gnome".equalsIgnoreCase(GDM)) {
+ if (OS.isArchInstalled()) {
+ if (DEBUG) {
+ logger.debug("Running Arch Linux.");
+ }
+ if (!Extension.isInstalled()) {
+ logger.info("You may need a work-around for showing the SystemTray icon - we suggest installing the " +
+ "the [Top Icons] plugin (https://extensions.gnome.org/extension/1031/topicons/) which moves " +
+ "icons from the *notification drawer* (it is normally collapsed) at the bottom left corner " +
+ "of the screen to the menu panel next to the clock.");
+ }
+ } else {
+ // Automatically install the extension for everyone except Arch. It's bonkers.
+ Extension.install();
+ }
+
// are we fedora? If so, what version?
// now, what VERSION of fedora? 23/24/25 don't have AppIndicator installed, so we have to use GtkStatusIcon
int fedoraVersion = OS.getFedoraVersion();
@@ -516,9 +534,9 @@ class SystemTray {
System.setProperty("SystemTray_IS_FEDORA_GNOME_ADJUST_SIZE", Integer.toString(fedoraVersion));
// 23 is gtk, 24/25 is gtk (but also wrong size unless we adjust it)
- Extension.install();
trayType = selectTypeQuietly(useNativeMenus, TrayType.GtkStatusIcon);
} else {
+ // arch likely will have problems unless the correct/appropriate libraries are installed.
trayType = selectTypeQuietly(useNativeMenus, TrayType.AppIndicator);
}
}
@@ -664,15 +682,13 @@ class SystemTray {
final AtomicReference