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:
authorSergey Sharybin <sergey.vfx@gmail.com>2011-09-19 14:48:15 +0400
committerSergey Sharybin <sergey.vfx@gmail.com>2011-09-19 14:48:15 +0400
commit1c0bdad8354139593cecb7cbbe3de27d8c5f6017 (patch)
tree82fada8c6425a9cd8194d0ac06b91981c7b5087a /source/blender/windowmanager
parent9b7b8464b9b09f4ca74e40624d3d6c8dffb0247e (diff)
parent226ff0d4da13ac66991f1708251faa5dff3f7dea (diff)
svn merge -r40222:40344 ^/trunk/blender
Diffstat (limited to 'source/blender/windowmanager')
-rw-r--r--source/blender/windowmanager/intern/wm_init_exit.c2
-rw-r--r--source/blender/windowmanager/intern/wm_operators.c8
2 files changed, 9 insertions, 1 deletions
diff --git a/source/blender/windowmanager/intern/wm_init_exit.c b/source/blender/windowmanager/intern/wm_init_exit.c
index 510b3403c05..83086201730 100644
--- a/source/blender/windowmanager/intern/wm_init_exit.c
+++ b/source/blender/windowmanager/intern/wm_init_exit.c
@@ -300,6 +300,8 @@ int WM_init_game(bContext *C)
WM_operator_name_call(C, "VIEW3D_OT_game_start", WM_OP_EXEC_DEFAULT, NULL);
+ sound_exit();
+
return 1;
}
else
diff --git a/source/blender/windowmanager/intern/wm_operators.c b/source/blender/windowmanager/intern/wm_operators.c
index ab18792d75b..921ef006de2 100644
--- a/source/blender/windowmanager/intern/wm_operators.c
+++ b/source/blender/windowmanager/intern/wm_operators.c
@@ -81,6 +81,7 @@
#include "BLF_api.h"
#include "IMB_imbuf_types.h"
+#include "IMB_imbuf.h"
#include "ED_screen.h"
#include "ED_util.h"
@@ -1206,6 +1207,9 @@ static int wm_resource_check_prev(void)
static uiBlock *wm_block_create_splash(bContext *C, ARegion *ar, void *UNUSED(arg))
{
+ extern char datatoc_splash_png[];
+ extern int datatoc_splash_png_size;
+
uiBlock *block;
uiBut *but;
uiLayout *layout, *split, *col;
@@ -1214,6 +1218,8 @@ static uiBlock *wm_block_create_splash(bContext *C, ARegion *ar, void *UNUSED(ar
int i;
MenuType *mt= WM_menutype_find("USERPREF_MT_splash", TRUE);
char url[96];
+ /* hardcoded to splash, loading and freeing every draw, eek! */
+ ImBuf *ibuf= IMB_ibImageFromMemory((unsigned char*)datatoc_splash_png, datatoc_splash_png_size, IB_rect);
#ifdef WITH_BUILDINFO
int ver_width, rev_width;
@@ -1237,7 +1243,7 @@ static uiBlock *wm_block_create_splash(bContext *C, ARegion *ar, void *UNUSED(ar
block= uiBeginBlock(C, ar, "_popup", UI_EMBOSS);
uiBlockSetFlag(block, UI_BLOCK_KEEP_OPEN);
- but= uiDefBut(block, BUT_IMAGE, 0, "", 0, 10, 501, 282, NULL, 0.0, 0.0, 0, 0, "");
+ 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);
uiBlockSetFunc(block, wm_block_splash_refreshmenu, block, NULL);