diff options
Diffstat (limited to 'backends/platform/sdl')
-rw-r--r-- | backends/platform/sdl/posix/posix.cpp | 9 | ||||
-rw-r--r-- | backends/platform/sdl/sdl.cpp | 2 |
2 files changed, 8 insertions, 3 deletions
diff --git a/backends/platform/sdl/posix/posix.cpp b/backends/platform/sdl/posix/posix.cpp index f124a3af7d..94f8d95ffb 100644 --- a/backends/platform/sdl/posix/posix.cpp +++ b/backends/platform/sdl/posix/posix.cpp @@ -51,8 +51,8 @@ void OSystem_POSIX::init() { _fsFactory = new POSIXFilesystemFactory(); #if defined(USE_TASKBAR) - // Initialize taskbar manager - _taskbarManager = new UnityTaskbarManager(); + // Initialize taskbar manager + _taskbarManager = new UnityTaskbarManager(); #endif // Invoke parent implementation of this method @@ -66,6 +66,11 @@ void OSystem_POSIX::initBackend() { // Invoke parent implementation of this method OSystem_SDL::initBackend(); + +#if defined(USE_TASKBAR) + // Register the taskbar manager as an event source (this is necessary for the glib event loop to be run) + _eventManager->getEventDispatcher()->registerSource((UnityTaskbarManager *)_taskbarManager, false); +#endif } bool OSystem_POSIX::hasFeature(Feature f) { diff --git a/backends/platform/sdl/sdl.cpp b/backends/platform/sdl/sdl.cpp index 4520b74861..4743dbb558 100644 --- a/backends/platform/sdl/sdl.cpp +++ b/backends/platform/sdl/sdl.cpp @@ -385,7 +385,7 @@ void OSystem_SDL::setupIcon() { if (sscanf(scummvm_icon[0], "%d %d %d %d", &w, &h, &ncols, &nbytes) != 4) { warning("Wrong format of scummvm_icon[0] (%s)", scummvm_icon[0]); - + return; } if ((w > 512) || (h > 512) || (ncols > 255) || (nbytes > 1)) { |