webbrowser.*: let's open the file in a detached process
Seems more useful overall and matches how it already works on Windows.db4
parent
7646ae71dd
commit
3718137969
|
@ -6,4 +6,4 @@ USING: arrays io.launcher kernel present system webbrowser ;
|
||||||
IN: webbrowser.linux
|
IN: webbrowser.linux
|
||||||
|
|
||||||
M: linux open-file ( path -- )
|
M: linux open-file ( path -- )
|
||||||
present "xdg-open" swap 2array try-process ;
|
present "xdg-open" swap 2array run-detached drop ;
|
||||||
|
|
|
@ -6,4 +6,4 @@ USING: arrays io.launcher kernel present system webbrowser ;
|
||||||
IN: webbrowser.macosx
|
IN: webbrowser.macosx
|
||||||
|
|
||||||
M: macosx open-file ( path -- )
|
M: macosx open-file ( path -- )
|
||||||
present "open" swap 2array try-process ;
|
present "open" swap 2array run-detached drop ;
|
||||||
|
|
|
@ -8,8 +8,8 @@ IN: webbrowser
|
||||||
HELP: open-file
|
HELP: open-file
|
||||||
{ $values { "path" string } }
|
{ $values { "path" string } }
|
||||||
{ $description
|
{ $description
|
||||||
"Open a specified file or directory using the default "
|
"Open a specified file or directory in a detached process using "
|
||||||
"application, similar to double-clicking the file's icon."
|
"the default application, similar to double-clicking the file's icon."
|
||||||
} ;
|
} ;
|
||||||
|
|
||||||
HELP: open-url
|
HELP: open-url
|
||||||
|
|
Loading…
Reference in New Issue