Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCampbell Barton <ideasman42@gmail.com>2010-01-27 12:16:28 +0300
committerCampbell Barton <ideasman42@gmail.com>2010-01-27 12:16:28 +0300
commit107f6cb269c6c3e3b4df2c13dc48f0be352ca4f9 (patch)
tree0de40608ca04aa56ca15c63f0f56a7bd5f9b60d8 /source/blender/windowmanager
parentde56a6384957d00c49d5e3846a8bcf7350e96daa (diff)
- duplicate window crasheing when it was full screen
- keymap item was missing NULL check crash - editmode object in inactive layer crash
Diffstat (limited to 'source/blender/windowmanager')
-rw-r--r--source/blender/windowmanager/intern/wm_operators.c14
1 files changed, 13 insertions, 1 deletions
diff --git a/source/blender/windowmanager/intern/wm_operators.c b/source/blender/windowmanager/intern/wm_operators.c
index a3d32cf41fe..cbcad5ce941 100644
--- a/source/blender/windowmanager/intern/wm_operators.c
+++ b/source/blender/windowmanager/intern/wm_operators.c
@@ -1241,6 +1241,18 @@ static void WM_OT_call_menu(wmOperatorType *ot)
/* ************ window / screen operator definitions ************** */
+/* this poll functions is needed in place of WM_operator_winactive
+ * while it crashes on full screen */
+static int wm_operator_winactive_normal(bContext *C)
+{
+ wmWindow *win= CTX_wm_window(C);
+
+ if(win==NULL || win->screen==NULL || win->screen->full != SCREENNORMAL)
+ return 0;
+
+ return 1;
+}
+
static void WM_OT_window_duplicate(wmOperatorType *ot)
{
ot->name= "Duplicate Window";
@@ -1248,7 +1260,7 @@ static void WM_OT_window_duplicate(wmOperatorType *ot)
ot->description="Duplicate the current Blender window.";
ot->exec= wm_window_duplicate_op;
- ot->poll= WM_operator_winactive;
+ ot->poll= wm_operator_winactive_normal;
}
static void WM_OT_save_homefile(wmOperatorType *ot)