ToastFreeware
/
gregoa
/
zavai.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
a72b722
)
Remove %foo arguments
author
Enrico Zini
<enrico@enricozini.org>
Mon, 3 Aug 2009 22:29:11 +0000
(23:29 +0100)
committer
Enrico Zini
<enrico@enricozini.org>
Mon, 3 Aug 2009 22:29:11 +0000
(23:29 +0100)
src/app_wm.vala
patch
|
blob
|
history
diff --git
a/src/app_wm.vala
b/src/app_wm.vala
index a1cfbeb93e360ec548b9e89ed8fb3593652d730e..68cb28c08411f76358bba362e5d60aea1b4ba9d8 100644
(file)
--- a/
src/app_wm.vala
+++ b/
src/app_wm.vala
@@
-148,11
+148,19
@@
public class LauncherButton : Gtk.Button
public void on_clicked()
{
zavai.log.info("Run program: " + exec);
public void on_clicked()
{
zavai.log.info("Run program: " + exec);
- string[] args = new string[] { exec, null };
+ string[] args = exec.split(" ");
+ string[] args1 = new string[args.length + 1];
+ int cout = 0;
+ for (int cin = 0; cin < args.length; ++cin)
+ {
+ if (args[cin][0] == '%') continue;
+ args1[cout++] = args[cin];
+ }
+ args1[cout] = null;
Pid pid;
Process.spawn_async(
Environment.get_home_dir(),
Pid pid;
Process.spawn_async(
Environment.get_home_dir(),
- args,
+ args
1
,
null,
SpawnFlags.SEARCH_PATH,
null,
null,
SpawnFlags.SEARCH_PATH,
null,