[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [51605] trunk/blender/source/blender: fix [#32938] The Splash Screen doesn't show up correctly .....

Campbell Barton ideasman42 at gmail.com
Thu Oct 25 04:58:00 CEST 2012


Revision: 51605
          http://projects.blender.org/scm/viewvc.php?view=rev&root=bf-blender&revision=51605
Author:   campbellbarton
Date:     2012-10-25 02:57:55 +0000 (Thu, 25 Oct 2012)
Log Message:
-----------
fix [#32938] The Splash Screen doesn't show up correctly .....

applying window clipping to the splash on startup gave strange/annoying problems.

Modified Paths:
--------------
    trunk/blender/source/blender/editors/include/UI_interface.h
    trunk/blender/source/blender/editors/interface/interface_regions.c
    trunk/blender/source/blender/windowmanager/intern/wm_operators.c

Modified: trunk/blender/source/blender/editors/include/UI_interface.h
===================================================================
--- trunk/blender/source/blender/editors/include/UI_interface.h	2012-10-25 00:49:47 UTC (rev 51604)
+++ trunk/blender/source/blender/editors/include/UI_interface.h	2012-10-25 02:57:55 UTC (rev 51605)
@@ -108,7 +108,7 @@
 #define UI_BLOCK_REDRAW         2
 #define UI_BLOCK_SEARCH_MENU    4
 #define UI_BLOCK_NUMSELECT      8
-/*#define UI_BLOCK_ENTER_OK		16*/ /*UNUSED*/
+#define UI_BLOCK_NO_WIN_CLIP    16      /* don't apply window clipping */ /* was UI_BLOCK_ENTER_OK */
 #define UI_BLOCK_CLIPBOTTOM     32
 #define UI_BLOCK_CLIPTOP        64
 #define UI_BLOCK_MOVEMOUSE_QUIT 128

Modified: trunk/blender/source/blender/editors/interface/interface_regions.c
===================================================================
--- trunk/blender/source/blender/editors/interface/interface_regions.c	2012-10-25 00:49:47 UTC (rev 51604)
+++ trunk/blender/source/blender/editors/interface/interface_regions.c	2012-10-25 02:57:55 UTC (rev 51605)
@@ -1548,7 +1548,11 @@
 static void ui_popup_block_clip(wmWindow *window, uiBlock *block)
 {
 	int winx, winy;
-	
+
+	if (block->flag & UI_BLOCK_NO_WIN_CLIP) {
+		return;
+	}
+
 	wm_window_get_size(window, &winx, &winy);
 	
 	if (block->rect.xmin < MENU_SHADOW_SIDE)

Modified: trunk/blender/source/blender/windowmanager/intern/wm_operators.c
===================================================================
--- trunk/blender/source/blender/windowmanager/intern/wm_operators.c	2012-10-25 00:49:47 UTC (rev 51604)
+++ trunk/blender/source/blender/windowmanager/intern/wm_operators.c	2012-10-25 02:57:55 UTC (rev 51605)
@@ -1320,7 +1320,11 @@
 #endif  /* WITH_BUILDINFO */
 
 	block = uiBeginBlock(C, ar, "_popup", UI_EMBOSS);
-	uiBlockSetFlag(block, UI_BLOCK_KEEP_OPEN);
+
+	/* note on UI_BLOCK_NO_WIN_CLIP, the window size is not always synchronized
+	 * with the OS when the splash shows, window clipping in this case gives
+	 * ugly results and clipping the splash isn't useful anyway, just disable it [#32938] */
+	uiBlockSetFlag(block, UI_BLOCK_KEEP_OPEN | UI_BLOCK_NO_WIN_CLIP);
 	
 	but = uiDefBut(block, BUT_IMAGE, 0, "", 0, 10, 501, 282, ibuf, 0.0, 0.0, 0, 0, ""); /* button owns the imbuf now */
 	uiButSetFunc(but, wm_block_splash_close, block, NULL);




More information about the Bf-blender-cvs mailing list