Skip to content

Commit 938edb2

Browse files
committed
(ckb) Re-added session workaround after CLI parser
1 parent 26302dd commit 938edb2

File tree

2 files changed

+8
-2
lines changed

2 files changed

+8
-2
lines changed

VERSION

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
beta-v0.2.4
1+
beta-v0.2.4+t02

src/ckb/main.cpp

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -208,7 +208,13 @@ int main(int argc, char *argv[]){
208208
break;
209209
}
210210

211-
// Launch in background if requested
211+
#ifdef Q_OS_LINUX
212+
// This isn't technically a command line option, but some WMs will add it when restoring a previous session.
213+
// We don't want to activate the window when that happens.
214+
if(qApp->arguments().contains("-session") || qApp->arguments().contains("--session"))
215+
background = true;
216+
#endif
217+
212218
if(isRunning(background ? 0 : "Open")){
213219
printf("ckb is already running. Exiting.\n");
214220
return 0;

0 commit comments

Comments
 (0)