9c1b0b33c2
X windows at once. This allows you, for example, to control a number of terminals connected to different but similar hosts for purposes of mass- administration. You can also select non-terminals. If you come up with a reasonable use for this ability I'd be interested in hearing about it. The program can select windows to send to either by matching their titles (using a substring) or by clicking on them (in a method similar to GIMP's screenshot feature). The program also features the ability to spawn off multiple instances of gnome-terminal executing a single command on multiple arguments (for example executing 'ssh' on several hosts). The gnome-terminals are invoked with the profile 'keyboardcast' if it exists (so, for example, your font size can be smaller). WWW: https://launchpad.net/keyboardcast PR: ports/142744 Submitted by: eimar.koort
24 lines
730 B
C
24 lines
730 B
C
--- window-list.c.orig 2005-12-06 04:57:05.000000000 +0200
|
|
+++ window-list.c 2010-01-11 13:37:39.000000000 +0200
|
|
@@ -15,6 +15,12 @@
|
|
* along with this program; if not, write to the Free Software
|
|
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110 USA
|
|
*/
|
|
+#include <sys/param.h>
|
|
+#ifdef __FreeBSD__
|
|
+#define LINKPATH "/proc/%d/file"
|
|
+#else
|
|
+#define LINKPATH "/proc/%d/exe"
|
|
+#endif
|
|
|
|
#define WNCK_I_KNOW_THIS_IS_UNSTABLE wankfactor
|
|
|
|
@@ -57,7 +63,7 @@
|
|
if( pid < 0 || pid == getpid() ) // never list myself
|
|
return FALSE;
|
|
|
|
- path = g_strdup_printf( "/proc/%d/exe", pid );
|
|
+ path = g_strdup_printf( LINKPATH, pid );
|
|
len = readlink( path, destination, sizeof destination );
|
|
g_free( path );
|
|
|