change return type of ForkCommand to gint
update sample to use ForkCommand, still missing signals svn path=/trunk/gtk-sharp/; revision=22216
This commit is contained in:
parent
5bf3b285bb
commit
6a6a552861
3 changed files with 13 additions and 2 deletions
|
@ -25,7 +25,8 @@ class T
|
||||||
ScrolledWindow sw = new ScrolledWindow ();
|
ScrolledWindow sw = new ScrolledWindow ();
|
||||||
Terminal term = new Terminal ();
|
Terminal term = new Terminal ();
|
||||||
term.CursorBlinks = true;
|
term.CursorBlinks = true;
|
||||||
term.ScrollOnOutput = true;
|
term.MouseAutohide = true;
|
||||||
|
term.ScrollOnKeystroke = true;
|
||||||
//term.BackgroundTransparent = true;
|
//term.BackgroundTransparent = true;
|
||||||
term.Encoding = "UTF-8";
|
term.Encoding = "UTF-8";
|
||||||
|
|
||||||
|
@ -33,6 +34,15 @@ class T
|
||||||
Console.WriteLine (term.Encoding);
|
Console.WriteLine (term.Encoding);
|
||||||
Console.WriteLine (term.StatusLine);
|
Console.WriteLine (term.StatusLine);
|
||||||
|
|
||||||
|
string argv = Environment.GetCommandLineArgs () [0];
|
||||||
|
|
||||||
|
string envv = "";
|
||||||
|
// FIXME: send the env vars to ForkCommand
|
||||||
|
Console.WriteLine (Environment.GetEnvironmentVariables ().Count);
|
||||||
|
|
||||||
|
int pid = term.ForkCommand ("/bin/bash", argv, envv, "/home/jluke", false, true, true);
|
||||||
|
Console.WriteLine ("Child pid: " + pid);
|
||||||
|
|
||||||
sw.AddWithViewport (term);
|
sw.AddWithViewport (term);
|
||||||
|
|
||||||
app.Contents = sw;
|
app.Contents = sw;
|
||||||
|
|
|
@ -1,3 +1,4 @@
|
||||||
<metadata>
|
<metadata>
|
||||||
<attr path="/api/namespace/object[@cname='VteReaper']" name="hidden">1</attr>
|
<attr path="/api/namespace/object[@cname='VteReaper']" name="hidden">1</attr>
|
||||||
|
<attr path="/api/namespace/object[@cname='VteTerminal']/method[@name='ForkCommand']/return-type" name="type">gint</attr>
|
||||||
</metadata>
|
</metadata>
|
||||||
|
|
|
@ -266,7 +266,7 @@
|
||||||
</parameters>
|
</parameters>
|
||||||
</method>
|
</method>
|
||||||
<method name="ForkCommand" cname="vte_terminal_fork_command">
|
<method name="ForkCommand" cname="vte_terminal_fork_command">
|
||||||
<return-type type="pid_t"/>
|
<return-type type="gint"/>
|
||||||
<parameters>
|
<parameters>
|
||||||
<parameter type="const-char*" name="command"/>
|
<parameter type="const-char*" name="command"/>
|
||||||
<parameter type="char**" name="argv"/>
|
<parameter type="char**" name="argv"/>
|
||||||
|
|
Loading…
Add table
Reference in a new issue