mirror of
https://github.com/davatorium/rofi.git
synced 2025-04-14 17:43:01 -04:00
Add -display flag.
This commit is contained in:
parent
8d0bf427e0
commit
c9513afaad
1 changed files with 3 additions and 2 deletions
|
@ -1293,12 +1293,13 @@ int main( int argc, char *argv[] )
|
|||
if ( find_arg( argc, argv, "-help" ) >= 0
|
||||
|| find_arg( argc, argv, "--help" ) >= 0
|
||||
|| find_arg( argc, argv, "-h" ) >= 0 ) {
|
||||
fprintf( stderr, "See the man page or visit http://github.com/DaveDavenport/simpleswitcher\n" );
|
||||
fprintf( stderr, "See the man (man 1 simpleswitcher) page or visit http://github.com/DaveDavenport/simpleswitcher\n" );
|
||||
fprintf( stderr, "Original code can be found: http://github.com/seanpringle/simpleswitcher\n" );
|
||||
return EXIT_FAILURE;
|
||||
}
|
||||
|
||||
if ( !( display = XOpenDisplay( 0 ) ) ) {
|
||||
const char *display_str= find_arg_str(argc, argv, "-display", getenv("DISPLAY"));
|
||||
if ( !( display = XOpenDisplay( display_str ) ) ) {
|
||||
fprintf( stderr, "cannot open display!\n" );
|
||||
return EXIT_FAILURE;
|
||||
}
|
||||
|
|
Loading…
Add table
Reference in a new issue