File src/term.c changed (mode: 100644) (index 773d505..902bab3) |
33 |
33 |
#include <gdk/gdkx.h> |
#include <gdk/gdkx.h> |
34 |
34 |
#include <gdk/gdkprivate.h> |
#include <gdk/gdkprivate.h> |
35 |
35 |
#include <gdk/gdkkeysyms.h> |
#include <gdk/gdkkeysyms.h> |
36 |
|
#include<gnome.h> |
|
37 |
|
#include <zvt/vt.h> |
|
|
36 |
|
/* #include<gnome.h> */ |
|
37 |
|
/* #include <zvt/vt.h> */ |
38 |
38 |
#include<X11/Xatom.h> |
#include<X11/Xatom.h> |
39 |
39 |
|
|
40 |
40 |
|
|
|
... |
... |
term_key_cb(GtkWidget *widget, GdkEventKey *event, ZvtTerm *term); |
44 |
44 |
void |
void |
45 |
45 |
write_to_term(ZvtTerm *term, gchar *message) |
write_to_term(ZvtTerm *term, gchar *message) |
46 |
46 |
{ |
{ |
47 |
|
write(term->vx->vt.keyfd, message, strlen(message)); |
|
|
47 |
|
/* write(term->vx->vt.keyfd, message, strlen(message)); */ |
48 |
48 |
} |
} |
49 |
49 |
|
|
50 |
50 |
void |
void |
|
... |
... |
set_color_scheme(ZvtTerm *term) |
203 |
203 |
} |
} |
204 |
204 |
|
|
205 |
205 |
|
|
206 |
|
zvt_term_set_color_scheme((ZvtTerm *)term, red, green, blue); |
|
207 |
|
c.pixel = term->colors[17]; |
|
|
206 |
|
/* zvt_term_set_color_scheme((ZvtTerm *)term, red, green, blue); */ |
|
207 |
|
/* c.pixel = term->colors[17]; */ |
208 |
208 |
gdk_window_set_background(GTK_WIDGET(term)->window, &c); |
gdk_window_set_background(GTK_WIDGET(term)->window, &c); |
209 |
209 |
gtk_widget_queue_draw(GTK_WIDGET(term)); |
gtk_widget_queue_draw(GTK_WIDGET(term)); |
210 |
210 |
} |
} |
|
... |
... |
get_focus_zvt(GtkNotebook *notebook, gint page_number) |
231 |
231 |
{ |
{ |
232 |
232 |
ch = ((GtkBoxChild*)(tmp->data))->widget; |
ch = ((GtkBoxChild*)(tmp->data))->widget; |
233 |
233 |
|
|
234 |
|
if(ZVT_IS_TERM(ch)) |
|
|
234 |
|
/* if(ZVT_IS_TERM(ch)) */ |
|
235 |
|
if(0) |
235 |
236 |
{ |
{ |
236 |
237 |
gint term_number = GPOINTER_TO_INT(gtk_object_get_data(GTK_OBJECT(ch), |
gint term_number = GPOINTER_TO_INT(gtk_object_get_data(GTK_OBJECT(ch), |
237 |
238 |
"term_number")); |
"term_number")); |
238 |
239 |
if(term_number == focus_term) |
if(term_number == focus_term) |
239 |
240 |
{ |
{ |
240 |
|
return ZVT_TERM(ch); |
|
|
241 |
|
return NULL;//ZVT_TERM(ch); |
241 |
242 |
} |
} |
242 |
243 |
} |
} |
243 |
244 |
} |
} |
|
... |
... |
get_nth_zvt(GtkNotebook *notebook, gint n) |
263 |
264 |
{ |
{ |
264 |
265 |
ch = ((GtkBoxChild*)(tmp->data))->widget; |
ch = ((GtkBoxChild*)(tmp->data))->widget; |
265 |
266 |
|
|
266 |
|
if(ZVT_IS_TERM(ch)) |
|
267 |
|
return ZVT_TERM(ch); |
|
|
267 |
|
if(0 /*ZVT_IS_TERM(ch)*/) |
|
268 |
|
return NULL;//ZVT_TERM(ch); |
268 |
269 |
} |
} |
269 |
270 |
return NULL; |
return NULL; |
270 |
271 |
} |
} |
|
... |
... |
void UpdateTerm (ZvtTerm * term) |
273 |
274 |
{ |
{ |
274 |
275 |
if(zvt.use_pixmap) |
if(zvt.use_pixmap) |
275 |
276 |
{ |
{ |
276 |
|
zvt_term_set_background(ZVT_TERM(term), zvt.pixmap, |
|
277 |
|
zvt.transparent, ZVT_BACKGROUND_SHADED); |
|
|
277 |
|
/* zvt_term_set_background(ZVT_TERM(term), zvt.pixmap, */ |
|
278 |
|
/* zvt.transparent, ZVT_BACKGROUND_SHADED); */ |
278 |
279 |
} |
} |
279 |
280 |
else if(zvt.transparent) |
else if(zvt.transparent) |
280 |
281 |
{ |
{ |
281 |
|
zvt_term_set_background(term, NULL, zvt.transparent, 0); |
|
|
282 |
|
/* zvt_term_set_background(term, NULL, zvt.transparent, 0); */ |
282 |
283 |
} |
} |
283 |
284 |
else |
else |
284 |
|
zvt_term_set_background(ZVT_TERM(term), NULL, 0, 0); |
|
|
285 |
|
;/* zvt_term_set_background(ZVT_TERM(term), NULL, 0, 0); */ |
285 |
286 |
|
|
286 |
|
zvt_term_set_font_name(ZVT_TERM (term), zvt.term_font); |
|
287 |
|
zvt_term_set_scrollback(ZVT_TERM (term), zvt.scroll_lines); |
|
288 |
|
zvt_term_set_blink (ZVT_TERM (term), zvt.use_blinking_cursor); |
|
289 |
|
zvt_term_set_bell (ZVT_TERM (term), zvt.terminal_bell); |
|
|
287 |
|
/* zvt_term_set_font_name(ZVT_TERM (term), zvt.term_font); */ |
|
288 |
|
/* zvt_term_set_scrollback(ZVT_TERM (term), zvt.scroll_lines); */ |
|
289 |
|
/* zvt_term_set_blink (ZVT_TERM (term), zvt.use_blinking_cursor); */ |
|
290 |
|
/* zvt_term_set_bell (ZVT_TERM (term), zvt.terminal_bell); */ |
290 |
291 |
|
|
291 |
|
set_color_scheme (ZVT_TERM(term)); |
|
|
292 |
|
/* set_color_scheme (ZVT_TERM(term)); */ |
292 |
293 |
|
|
293 |
294 |
|
|
294 |
|
zvt_term_set_scroll_on_keystroke (ZVT_TERM (term), zvt.scroll_on_keystroke); |
|
295 |
|
zvt_term_set_scroll_on_output (ZVT_TERM (term), zvt.scroll_on_output); |
|
|
295 |
|
/* zvt_term_set_scroll_on_keystroke (ZVT_TERM (term), zvt.scroll_on_keystroke); */ |
|
296 |
|
/* zvt_term_set_scroll_on_output (ZVT_TERM (term), zvt.scroll_on_output); */ |
296 |
297 |
|
|
297 |
298 |
gtk_widget_queue_draw (GTK_WIDGET(term)); |
gtk_widget_queue_draw (GTK_WIDGET(term)); |
298 |
299 |
} |
} |
|
... |
... |
void update_all_terms() |
304 |
305 |
|
|
305 |
306 |
while ((ch = get_nth_zvt(GTK_NOTEBOOK(app.notebook),a))) |
while ((ch = get_nth_zvt(GTK_NOTEBOOK(app.notebook),a))) |
306 |
307 |
{ |
{ |
307 |
|
UpdateTerm (ZVT_TERM(ch)); |
|
|
308 |
|
/* UpdateTerm (ZVT_TERM(ch)); */ |
308 |
309 |
a++; |
a++; |
309 |
310 |
} |
} |
310 |
311 |
|
|
|
... |
... |
void update_all_terms() |
337 |
338 |
|
|
338 |
339 |
gtk_widget_hide(GTK_WIDGET(term)); |
gtk_widget_hide(GTK_WIDGET(term)); |
339 |
340 |
|
|
340 |
|
zvt_term_closepty(term); |
|
|
341 |
|
/* zvt_term_closepty(term); */ |
341 |
342 |
gtk_widget_destroy(GTK_WIDGET(term)); |
gtk_widget_destroy(GTK_WIDGET(term)); |
342 |
343 |
gtk_object_set_data(GTK_OBJECT(vbox), "term_count", |
gtk_object_set_data(GTK_OBJECT(vbox), "term_count", |
343 |
344 |
GUINT_TO_POINTER(term_count)); |
GUINT_TO_POINTER(term_count)); |
|
... |
... |
void update_all_terms() |
347 |
348 |
for(tmp = child; tmp != NULL; tmp = tmp->next) |
for(tmp = child; tmp != NULL; tmp = tmp->next) |
348 |
349 |
{ |
{ |
349 |
350 |
ch = ((GtkBoxChild*)(tmp->data))->widget; |
ch = ((GtkBoxChild*)(tmp->data))->widget; |
350 |
|
if(ZVT_IS_TERM(ch)) |
|
351 |
|
{ |
|
352 |
|
term_number++; |
|
353 |
|
gtk_object_set_data(GTK_OBJECT(ch), "term_number", |
|
354 |
|
GUINT_TO_POINTER(term_number)); |
|
355 |
|
} |
|
|
351 |
|
/* if(ZVT_IS_TERM(ch)) */ |
|
352 |
|
/* { */ |
|
353 |
|
/* term_number++; */ |
|
354 |
|
/* gtk_object_set_data(GTK_OBJECT(ch), "term_number", */ |
|
355 |
|
/* GUINT_TO_POINTER(term_number)); */ |
|
356 |
|
/* } */ |
356 |
357 |
} |
} |
357 |
358 |
/* set focus_term and notebook tab */ |
/* set focus_term and notebook tab */ |
358 |
359 |
|
|
|
... |
... |
void update_all_terms() |
398 |
399 |
cfg.term_count--; |
cfg.term_count--; |
399 |
400 |
} |
} |
400 |
401 |
|
|
401 |
|
zvt_term_closepty(term); |
|
|
402 |
|
/* zvt_term_closepty(term); */ |
402 |
403 |
/* reset the notebook tabs and vi buffer list */ |
/* reset the notebook tabs and vi buffer list */ |
403 |
404 |
page = 1; |
page = 1; |
404 |
405 |
while((tmp_term = get_nth_zvt(GTK_NOTEBOOK(app.notebook), page))) |
while((tmp_term = get_nth_zvt(GTK_NOTEBOOK(app.notebook), page))) |
|
... |
... |
switch_term_key_cb(GtkWidget *widget, GdkEventKey *event, ZvtTerm *term) |
479 |
480 |
for(tmp = child; tmp != NULL; tmp = tmp->next) |
for(tmp = child; tmp != NULL; tmp = tmp->next) |
480 |
481 |
{ |
{ |
481 |
482 |
ch = ((GtkBoxChild*)(tmp->data))->widget; |
ch = ((GtkBoxChild*)(tmp->data))->widget; |
482 |
|
if(ZVT_IS_TERM(ch)) |
|
483 |
|
tmp_num = GPOINTER_TO_INT(gtk_object_get_data(GTK_OBJECT(ch), |
|
484 |
|
"term_number")); |
|
|
483 |
|
/* if(ZVT_IS_TERM(ch)) */ |
|
484 |
|
/* tmp_num = GPOINTER_TO_INT(gtk_object_get_data(GTK_OBJECT(ch), */ |
|
485 |
|
/* "term_number")); */ |
485 |
486 |
if(tmp_num == next_term) |
if(tmp_num == next_term) |
486 |
487 |
{ |
{ |
487 |
488 |
GtkWidget *term_label; |
GtkWidget *term_label; |
|
... |
... |
switch_term_key_cb(GtkWidget *widget, GdkEventKey *event, ZvtTerm *term) |
518 |
519 |
case 'm': |
case 'm': |
519 |
520 |
{ |
{ |
520 |
521 |
gchar buf[256]; |
gchar buf[256]; |
521 |
|
gchar * word = zvt_term_get_buffer(term, NULL, VT_SELTYPE_WORD, |
|
522 |
|
term->vx->vt.cursorx, term->vx->vt.cursory, |
|
523 |
|
term->vx->vt.cursorx, term->vx->vt.cursory); |
|
524 |
|
g_snprintf(buf, sizeof(buf), "%s %s", cfg.man_program, word); |
|
|
522 |
|
/* gchar * word = zvt_term_get_buffer(term, NULL, VT_SELTYPE_WORD, */ |
|
523 |
|
/* term->vx->vt.cursorx, term->vx->vt.cursory, */ |
|
524 |
|
/* term->vx->vt.cursorx, term->vx->vt.cursory); */ |
|
525 |
|
/* g_snprintf(buf, sizeof(buf), "%s %s", cfg.man_program, word); */ |
525 |
526 |
create_zterm(buf, FALSE); |
create_zterm(buf, FALSE); |
526 |
527 |
/* |
/* |
527 |
528 |
g_print("cursorx is %d\n", term->vx->vt.cursorx); |
g_print("cursorx is %d\n", term->vx->vt.cursorx); |
528 |
529 |
g_print("cursory is %d\n", term->vx->vt.cursory); |
g_print("cursory is %d\n", term->vx->vt.cursory); |
529 |
530 |
g_print("word under cursor is %s\n", word); |
g_print("word under cursor is %s\n", word); |
530 |
531 |
*/ |
*/ |
531 |
|
g_free(word); |
|
|
532 |
|
/* g_free(word); */ |
532 |
533 |
} |
} |
533 |
534 |
break; |
break; |
534 |
535 |
default: |
default: |
|
... |
... |
term_key_cb(GtkWidget *widget, GdkEventKey *event, ZvtTerm *term) |
626 |
627 |
} |
} |
627 |
628 |
} |
} |
628 |
629 |
|
|
|
630 |
|
typedef int VTTITLE_TYPE; |
629 |
631 |
|
|
630 |
632 |
static void |
static void |
631 |
633 |
title_changed_event (ZvtTerm *term, VTTITLE_TYPE type, char *newtitle) |
title_changed_event (ZvtTerm *term, VTTITLE_TYPE type, char *newtitle) |
|
... |
... |
create_zterm (gchar *command, gboolean new_page) |
706 |
708 |
/* reset the page to the real notebook page number */ |
/* reset the page to the real notebook page number */ |
707 |
709 |
page = cfg.term_count +1; |
page = cfg.term_count +1; |
708 |
710 |
|
|
709 |
|
term = (ZvtTerm *)zvt_term_new_with_size(80,24); |
|
|
711 |
|
/* term = (ZvtTerm *)zvt_term_new_with_size(80,24); */ |
710 |
712 |
gtk_object_set_data(GTK_OBJECT(term), "label_text", buf); |
gtk_object_set_data(GTK_OBJECT(term), "label_text", buf); |
711 |
713 |
|
|
712 |
714 |
if(new_page) |
if(new_page) |
|
... |
... |
create_zterm (gchar *command, gboolean new_page) |
754 |
756 |
|
|
755 |
757 |
/* set terminal options */ |
/* set terminal options */ |
756 |
758 |
gtk_widget_show (GTK_WIDGET(term)); |
gtk_widget_show (GTK_WIDGET(term)); |
757 |
|
zvt_term_set_font_name(ZVT_TERM (term), zvt.term_font); |
|
758 |
|
zvt_term_set_blink (ZVT_TERM (term), zvt.use_blinking_cursor); |
|
759 |
|
zvt_term_set_bell (ZVT_TERM (term), zvt.terminal_bell); |
|
760 |
|
zvt_term_set_scrollback(ZVT_TERM (term), zvt.scroll_lines); |
|
761 |
|
zvt_term_set_scroll_on_keystroke (ZVT_TERM (term), zvt.scroll_on_keystroke); |
|
762 |
|
zvt_term_set_scroll_on_output (ZVT_TERM (term), zvt.scroll_on_output); |
|
763 |
|
zvt_term_set_wordclass (ZVT_TERM (term), "-A-Za-z0-9/_:.,?+%="); |
|
|
759 |
|
/* zvt_term_set_font_name(ZVT_TERM (term), zvt.term_font); */ |
|
760 |
|
/* zvt_term_set_blink (ZVT_TERM (term), zvt.use_blinking_cursor); */ |
|
761 |
|
/* zvt_term_set_bell (ZVT_TERM (term), zvt.terminal_bell); */ |
|
762 |
|
/* zvt_term_set_scrollback(ZVT_TERM (term), zvt.scroll_lines); */ |
|
763 |
|
/* zvt_term_set_scroll_on_keystroke (ZVT_TERM (term), zvt.scroll_on_keystroke); */ |
|
764 |
|
/* zvt_term_set_scroll_on_output (ZVT_TERM (term), zvt.scroll_on_output); */ |
|
765 |
|
/* zvt_term_set_wordclass (ZVT_TERM (term), "-A-Za-z0-9/_:.,?+%="); */ |
764 |
766 |
if(zvt.use_pixmap) |
if(zvt.use_pixmap) |
765 |
767 |
{ |
{ |
766 |
|
zvt_term_set_background(ZVT_TERM(term), zvt.pixmap, |
|
767 |
|
zvt.transparent, ZVT_BACKGROUND_SHADED); |
|
|
768 |
|
/* zvt_term_set_background(ZVT_TERM(term), zvt.pixmap, */ |
|
769 |
|
/* zvt.transparent, ZVT_BACKGROUND_SHADED); */ |
768 |
770 |
} |
} |
769 |
771 |
else if(zvt.transparent) |
else if(zvt.transparent) |
770 |
772 |
{ |
{ |
771 |
|
zvt_term_set_background(term, NULL, zvt.transparent, 0); |
|
|
773 |
|
/* zvt_term_set_background(term, NULL, zvt.transparent, 0); */ |
772 |
774 |
} |
} |
773 |
775 |
else |
else |
774 |
|
zvt_term_set_background(ZVT_TERM(term), NULL, 0, 0); |
|
|
776 |
|
;/* zvt_term_set_background(ZVT_TERM(term), NULL, 0, 0); */ |
775 |
777 |
|
|
776 |
|
zvt_term_set_del_key_swap(ZVT_TERM(term), zvt.swap_backspace); |
|
|
778 |
|
/* zvt_term_set_del_key_swap(ZVT_TERM(term), zvt.swap_backspace); */ |
777 |
779 |
if(new_page) |
if(new_page) |
778 |
780 |
cfg.term_count++; |
cfg.term_count++; |
779 |
781 |
gtk_notebook_set_show_tabs(GTK_NOTEBOOK(app.notebook), zvt.show_tabs); |
gtk_notebook_set_show_tabs(GTK_NOTEBOOK(app.notebook), zvt.show_tabs); |
|
... |
... |
create_zterm (gchar *command, gboolean new_page) |
849 |
851 |
env_copy [i] = NULL; |
env_copy [i] = NULL; |
850 |
852 |
|
|
851 |
853 |
|
|
852 |
|
/* fork the shell or program */ |
|
853 |
|
switch (zvt_term_forkpty(ZVT_TERM (term), ZVT_TERM_DO_UTMP_LOG | ZVT_TERM_DO_WTMP_LOG)) { |
|
854 |
|
case -1: |
|
855 |
|
perror("ERROR: unable to fork:"); |
|
856 |
|
exit(1); |
|
857 |
|
break; |
|
858 |
|
|
|
859 |
|
case 0: |
|
860 |
|
{ |
|
861 |
|
GString *shell, *name; |
|
862 |
|
gchar *args[4]; |
|
863 |
|
|
|
864 |
|
/* get shell from passwd */ |
|
865 |
|
pw = getpwuid(getuid()); |
|
866 |
|
if (pw) { |
|
867 |
|
shell = g_string_new(pw->pw_shell); |
|
868 |
|
if (login_shell) |
|
869 |
|
name = g_string_new("-"); |
|
870 |
|
else |
|
871 |
|
name = g_string_new(""); |
|
872 |
|
|
|
873 |
|
g_string_append(name, strrchr(pw->pw_shell, '/')); |
|
874 |
|
} else { |
|
875 |
|
shell = g_string_new("/bin/sh"); |
|
876 |
|
if (login_shell) |
|
877 |
|
name = g_string_new("-sh"); |
|
878 |
|
else |
|
879 |
|
name = g_string_new("sh"); |
|
880 |
|
} |
|
881 |
|
|
|
882 |
|
/* |
|
883 |
|
* Without this the title change may not work. |
|
884 |
|
* I'm not sure why but if you launch vide from a shell this is |
|
885 |
|
* not needed. But if you launch it from a window manager menu |
|
886 |
|
* the title_changed event is not caught unless you specify the |
|
887 |
|
* term window id. This is from the gnome-terminal application |
|
888 |
|
* and is undocumented in the zvt docs. |
|
889 |
|
*/ |
|
890 |
|
sprintf(buffer, "WINDOWID=%d", |
|
891 |
|
(int) GDK_WINDOW_XWINDOW(GTK_WIDGET(term)->window)); |
|
892 |
|
env_copy[winid_pos] = buffer; |
|
893 |
|
|
|
894 |
|
|
|
895 |
|
if(!strcmp(command, "sh")) |
|
896 |
|
{ |
|
897 |
|
execle(shell->str, name->str, NULL, env_copy); |
|
898 |
|
_exit(127); |
|
899 |
|
} |
|
900 |
|
else |
|
901 |
|
{ |
|
902 |
|
args[0] = "sh"; |
|
903 |
|
args[1] = "-c"; |
|
904 |
|
args[2] = command; |
|
905 |
|
args[3] = NULL; |
|
906 |
|
|
|
907 |
|
/* This ensures that the signals are sent to the correct window |
|
908 |
|
* see the previous comment |
|
909 |
|
*/ |
|
910 |
|
environ = env_copy; |
|
911 |
|
|
|
912 |
|
execvp(args[0], args); |
|
913 |
|
_exit(127); |
|
914 |
|
} |
|
915 |
|
} |
|
916 |
|
|
|
917 |
|
default: |
|
918 |
|
break; |
|
919 |
|
} |
|
|
854 |
|
// /* fork the shell or program */ |
|
855 |
|
// switch (zvt_term_forkpty(ZVT_TERM (term), ZVT_TERM_DO_UTMP_LOG | ZVT_TERM_DO_WTMP_LOG)) { |
|
856 |
|
// case -1: |
|
857 |
|
// perror("ERROR: unable to fork:"); |
|
858 |
|
// exit(1); |
|
859 |
|
// break; |
|
860 |
|
// |
|
861 |
|
// case 0: |
|
862 |
|
// { |
|
863 |
|
// GString *shell, *name; |
|
864 |
|
// gchar *args[4]; |
|
865 |
|
// |
|
866 |
|
// /* get shell from passwd */ |
|
867 |
|
// pw = getpwuid(getuid()); |
|
868 |
|
// if (pw) { |
|
869 |
|
// shell = g_string_new(pw->pw_shell); |
|
870 |
|
// if (login_shell) |
|
871 |
|
// name = g_string_new("-"); |
|
872 |
|
// else |
|
873 |
|
// name = g_string_new(""); |
|
874 |
|
// |
|
875 |
|
// g_string_append(name, strrchr(pw->pw_shell, '/')); |
|
876 |
|
// } else { |
|
877 |
|
// shell = g_string_new("/bin/sh"); |
|
878 |
|
// if (login_shell) |
|
879 |
|
// name = g_string_new("-sh"); |
|
880 |
|
// else |
|
881 |
|
// name = g_string_new("sh"); |
|
882 |
|
// } |
|
883 |
|
// |
|
884 |
|
// /* |
|
885 |
|
// * Without this the title change may not work. |
|
886 |
|
// * I'm not sure why but if you launch vide from a shell this is |
|
887 |
|
// * not needed. But if you launch it from a window manager menu |
|
888 |
|
// * the title_changed event is not caught unless you specify the |
|
889 |
|
// * term window id. This is from the gnome-terminal application |
|
890 |
|
// * and is undocumented in the zvt docs. |
|
891 |
|
// */ |
|
892 |
|
// sprintf(buffer, "WINDOWID=%d", |
|
893 |
|
// (int) GDK_WINDOW_XWINDOW(GTK_WIDGET(term)->window)); |
|
894 |
|
// env_copy[winid_pos] = buffer; |
|
895 |
|
// |
|
896 |
|
// |
|
897 |
|
// if(!strcmp(command, "sh")) |
|
898 |
|
// { |
|
899 |
|
// execle(shell->str, name->str, NULL, env_copy); |
|
900 |
|
// _exit(127); |
|
901 |
|
// } |
|
902 |
|
// else |
|
903 |
|
// { |
|
904 |
|
// args[0] = "sh"; |
|
905 |
|
// args[1] = "-c"; |
|
906 |
|
// args[2] = command; |
|
907 |
|
// args[3] = NULL; |
|
908 |
|
// |
|
909 |
|
// /* This ensures that the signals are sent to the correct window |
|
910 |
|
// * see the previous comment |
|
911 |
|
// */ |
|
912 |
|
// environ = env_copy; |
|
913 |
|
// |
|
914 |
|
// execvp(args[0], args); |
|
915 |
|
// _exit(127); |
|
916 |
|
// } |
|
917 |
|
// } |
|
918 |
|
// |
|
919 |
|
// default: |
|
920 |
|
// break; |
|
921 |
|
// } |
920 |
922 |
|
|
921 |
923 |
if(new_page) |
if(new_page) |
922 |
924 |
gtk_notebook_set_page(GTK_NOTEBOOK(app.notebook), -1); |
gtk_notebook_set_page(GTK_NOTEBOOK(app.notebook), -1); |