vte r2112 - trunk/src



Author: chpe
Date: Mon Oct 13 11:44:59 2008
New Revision: 2112
URL: http://svn.gnome.org/viewvc/vte?rev=2112&view=rev

Log:
Add vte_terminal_get_pty().

Modified:
   trunk/src/vte.c
   trunk/src/vte.h

Modified: trunk/src/vte.c
==============================================================================
--- trunk/src/vte.c	(original)
+++ trunk/src/vte.c	Mon Oct 13 11:44:59 2008
@@ -12498,6 +12498,23 @@
 }
 
 /**
+ * vte_terminal_get_pty:
+ * @terminal: a #VteTerminal
+ * @pty_master: a file descriptor of the master end of a PTY
+ *
+ * Returns: the file descriptor of the master end of @terminal's PTY,
+ *   or -1 if the terminal has no PTY.
+ *
+ * Since: 0.17.5
+ */
+int vte_terminal_get_pty(VteTerminal *terminal)
+{
+  g_return_val_if_fail (VTE_IS_TERMINAL (terminal), -1);
+
+  return terminal->pvt->pty_master;
+}
+
+/**
  * vte_terminal_get_child_exit_status:
  * @terminal: a #VteTerminal
  *

Modified: trunk/src/vte.h
==============================================================================
--- trunk/src/vte.h	(original)
+++ trunk/src/vte.h	Mon Oct 13 11:44:59 2008
@@ -417,6 +417,7 @@
 /* Attach an existing PTY master side to the terminal widget.  Use
  * instead of vte_terminal_fork_command(). */
 void vte_terminal_set_pty(VteTerminal *terminal, int pty_master);
+int vte_terminal_get_pty(VteTerminal *terminal);
 
 /* Accessors for bindings. */
 GtkAdjustment *vte_terminal_get_adjustment(VteTerminal *terminal);



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]