X-Git-Url: https://git.artsoft.org/?a=blobdiff_plain;f=src%2Flibgame%2Fsdl.c;h=32635b5341a6f4ff7bfb6530742ae22482628e1b;hb=02527edeeaafdc8c3fafecea772b82fd770abc9b;hp=8b8720c320fcfe182b5bdbbb3958d03034aeb9ce;hpb=6b8e0388206475c9fae364474c84624fa5a49599;p=rocksndiamonds.git diff --git a/src/libgame/sdl.c b/src/libgame/sdl.c index 8b8720c3..32635b53 100644 --- a/src/libgame/sdl.c +++ b/src/libgame/sdl.c @@ -454,7 +454,7 @@ void SDLInitVideoBuffer(DrawBuffer **backbuffer, DrawWindow **window, /* !!! SDL2 can only set the window icon if the window already exists !!! */ /* set window icon */ - SDLSetWindowIcon(program.sdl_icon_filename); + SDLSetWindowIcon(program.icon_filename); /* set window and icon title */ #if defined(TARGET_SDL2) @@ -716,9 +716,12 @@ boolean SDLSetVideoMode(DrawBuffer **backbuffer, boolean fullscreen) SDLRedrawWindow(); // map window #endif +#ifdef DEBUG +#if defined(PLATFORM_WIN32) + // experimental drag and drop code + SDL_EventState(SDL_SYSWMEVENT, SDL_ENABLE); -#if defined(PLATFORM_WIN32) { SDL_SysWMinfo wminfo; HWND hwnd; @@ -743,6 +746,7 @@ boolean SDLSetVideoMode(DrawBuffer **backbuffer, boolean fullscreen) DragAcceptFiles(hwnd, TRUE); } } +#endif #endif return success; @@ -2373,7 +2377,10 @@ void SDLNextEvent(Event *event) void SDLHandleWindowManagerEvent(Event *event) { +#ifdef DEBUG #if defined(PLATFORM_WIN32) + // experimental drag and drop code + SDL_SysWMEvent *syswmevent = (SDL_SysWMEvent *)event; SDL_SysWMmsg *syswmmsg = (SDL_SysWMmsg *)(syswmevent->msg); @@ -2411,6 +2418,7 @@ void SDLHandleWindowManagerEvent(Event *event) #endif } #endif +#endif }