From 22a829cb1907c79bfe68ad91314a1dddbf1beeb3 Mon Sep 17 00:00:00 2001 From: Miller Puckette Date: Tue, 1 Sep 2009 18:22:23 +0000 Subject: merge in HC's new tcl code and start taking patches svn path=/trunk/; revision=12166 --- pd/src/g_editor.c | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'pd/src/g_editor.c') diff --git a/pd/src/g_editor.c b/pd/src/g_editor.c index 7ef5266a..0890d465 100644 --- a/pd/src/g_editor.c +++ b/pd/src/g_editor.c @@ -2251,6 +2251,8 @@ restore: static void canvas_cut(t_canvas *x) { + if (!x->gl_editor) /* ignore if invisible */ + return; if (x->gl_editor && x->gl_editor->e_selectedline) canvas_clearline(x); else if (x->gl_editor->e_textedfor) @@ -2343,6 +2345,8 @@ static void canvas_paste(t_canvas *x) static void canvas_duplicate(t_canvas *x) { + if (!x->gl_editor) + return; if (x->gl_editor->e_onmotion == MA_NONE && x->gl_editor->e_selection) { t_selection *y; @@ -2360,6 +2364,8 @@ static void canvas_duplicate(t_canvas *x) static void canvas_selectall(t_canvas *x) { t_gobj *y; + if (!x->gl_editor) + return; if (!x->gl_edit) canvas_editmode(x, 1); /* if everyone is already selected deselect everyone */ -- cgit v1.2.1