[Swingosc-devel] [ok-to-commit?] open, openURL
Brought to you by:
sciss
From: nescivi <ne...@gm...> - 2009-01-03 03:16:57
|
Hiho, following the discussion today with Scott... ok to commit this? sincerely, Marije Index: SuperCollider/SCClassLibrary/SwingOSC/JSCViews1.sc =================================================================== --- SuperCollider/SCClassLibrary/SwingOSC/JSCViews1.sc (revision 131) +++ SuperCollider/SCClassLibrary/SwingOSC/JSCViews1.sc (working copy) @@ -2314,7 +2314,12 @@ path = path.tr($\\, $/); }); path = path.replace( ' ', '%20' ); - this.openURL( "file://"++path ); + + if ( path.contains( "://" ).not, { + if ( path.first.asString != "/" ) { path = String.scDir +/+ path; }; + path = "file://"++path; + }); + this.openURL( path ); } defaultKeyDownAction { arg key, modifiers, unicode; |