forked from dorkbox/SystemTray
Removed SHELL_RESTART_TIMEOUT_MILLIS
This commit is contained in:
parent
92ecb56bdc
commit
f62cb4f4f2
@ -40,10 +40,6 @@ class GnomeShellExtension {
|
|||||||
/** Permit the gnome-shell to be restarted when the extension is installed. */
|
/** Permit the gnome-shell to be restarted when the extension is installed. */
|
||||||
public static boolean ENABLE_SHELL_RESTART = true;
|
public static boolean ENABLE_SHELL_RESTART = true;
|
||||||
|
|
||||||
@Property
|
|
||||||
/** Default timeout to wait for the gnome-shell to completely restart. This is a best-guess estimate. */
|
|
||||||
public static long SHELL_RESTART_TIMEOUT_MILLIS = 5000L;
|
|
||||||
|
|
||||||
@Property
|
@Property
|
||||||
/** Command to restart the gnome-shell. It is recommended to start it in the background (hence '&') */
|
/** Command to restart the gnome-shell. It is recommended to start it in the background (hence '&') */
|
||||||
public static String SHELL_RESTART_COMMAND = "gnome-shell --replace &";
|
public static String SHELL_RESTART_COMMAND = "gnome-shell --replace &";
|
||||||
@ -267,14 +263,7 @@ class GnomeShellExtension {
|
|||||||
restartShell.addArgument(SHELL_RESTART_COMMAND);
|
restartShell.addArgument(SHELL_RESTART_COMMAND);
|
||||||
restartShell.start();
|
restartShell.start();
|
||||||
|
|
||||||
// have to give the shell time to restart
|
// We don't care when the shell restarts, since WHEN IT DOES restart, our extension will show our icon.
|
||||||
try {
|
|
||||||
Thread.sleep(SHELL_RESTART_TIMEOUT_MILLIS);
|
|
||||||
} catch (InterruptedException e) {
|
|
||||||
e.printStackTrace();
|
|
||||||
}
|
|
||||||
|
|
||||||
logger.info("Shell restarted.");
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user