Commit Graph

477 Commits

Author SHA1 Message Date
Filippos Karapetis
6cb0a4c1b0 SDL: Fix compilation with SDL 2.0 under MSVC
In SDL 2.0, intrin.h is now included in SDL_cpuinfo.h, which includes
setjmp.h. SDL_cpuinfo.h is included from SDL.h and SDL_syswm.h.
Thus, we remove the exceptions for setjmp and longjmp before these two
includes.
2015-03-06 02:57:09 +02:00
Matthew Hoops
5936f7c9d1 MACOSX: Fix compilation
Broken by 3f22c12
2015-03-05 08:02:54 -05:00
Johannes Schickel
066e71f61a SDL: Call setupIcon for each window creation with SDL2.
This should make sure that the logo is properly set on Win32 with SDL2.
2015-03-01 16:21:53 +01:00
Johannes Schickel
71cc9e41e8 WINCE: Fix compilation. 2015-02-18 05:24:45 +01:00
Johannes Schickel
3745ddbefd WIN32: Add experimental SDL2 support.
Based on changes by aquadran.
2015-02-16 02:13:11 +01:00
Johannes Schickel
3f22c12c56 SDL: Handle icon setup in SdlWindow. 2015-02-16 01:25:22 +01:00
Johannes Schickel
627d766325 SDL: Add basic abstraction class for the SDL window. 2015-02-16 01:03:29 +01:00
Johannes Schickel
8d57b766a9 SDL: Fix typo. 2015-01-25 21:11:18 +01:00
Johannes Schickel
8530997fff SDL: Add experimental support for SDL2.
This is based upon skristiansson's change set to make ScummVM work with SDL2.
2015-01-25 20:23:25 +01:00
Johannes Schickel
d97889cea7 SDL: Cleanup graphics manager switching a bit. 2015-01-25 19:26:15 +01:00
Johannes Schickel
3a2db0135d SDL: Refactor WM specific functionality into SdlGraphicsManager. 2015-01-25 18:57:38 +01:00
Filippos Karapetis
d2c69a79fe BACKENDS: Remove trailing whitespace 2014-10-28 15:38:51 +02:00
raziel-
01dc551e87 AMIGAOS: Make use of the new drawer icon
On AmigaOS the user can customize every icon including drawers.

This is a customized drawer icon for ScummVM with the original "S"
scaled on top of it.

This icon may change with further revisions of AmigaOS4 (if the
default icon images change).
2014-09-07 10:09:05 +01:00
raziel-
cbae401a79 AMIGAOS: Add a stack cookie
Setting up a static stack to avoid crashes from a stack set too low.
2014-08-08 13:43:59 +01:00
raziel-
38f7a9bc70 AMIGAOS: Cleanup of the AmigaOS version number 2014-08-08 14:05:23 +03:00
D G Turner
469eecb9ee BUILD: Add port specific makefile for AmigaOS4.
This moves the AmigaOS4 specific packaging rules from the global
ports.mk to a port specific makefile in the AmigaOS subdirectory of
the SDL backend (used for AmigaOS).

Previously, port specific makefiles were only used for cross compiling
builds and thus had a single entry in the cross compiling section of
the configure. Since AmigaOS4 is a desktop system supporting native
build, this required a second entry for when the host system is detected
as ppc-amigaos to support native builds.

However, currently this does break packaging of cross compiled builds
for Win32, OSX and Unix when done on AmigaOS4... but this is not likely
and has limited impact. To fix this, default _port_mk lines would need
to be added to the sections of the cross compiling switch for mingw32
etc. to override the AmigaOS4 OS setting of _port_mk.
2014-07-20 04:18:46 +01:00
Bastien Bouclet
bf90ad0467 BUILD: Move the PS3 make targets to a separate file 2014-06-28 17:12:43 +02:00
Matthew Hoops
7af36e9724 BACKENDS: Fix invalid buffer size in CFStringGetCString call 2014-06-01 17:02:18 -04:00
Thierry Crozat
6d7fcdd2b5 OSX: Implement TaskbarManager for Mac OS X
This implements count badge, progress bar, and icon overlay.
It uses the NSDockTile API which is available since OS X 10.5.
The code compiles and run on older system but without doing
anything.
2014-02-23 21:54:47 +00:00
Johannes Schickel
63304ee9ec SDL: Make GPL headers consistent in themselves. 2014-02-18 02:39:38 +01:00
D G Turner
fc80f5a346 SDL: Move debugging code to output SDL video driver name to initBackend.
The initBackend() function is called later after the command line is
parsed and thus debug() prints can be used, which are much less noisy.
2014-02-16 16:33:35 +00:00
D G Turner
2589228329 SDL: Add debugging code to output SDL video driver name being used. 2014-02-12 12:11:53 +00:00
Johannes Schickel
2fe303ce3f Merge pull request #409 from lordhoto/rtti
Enable RTTI and clean up the code by exploiting the availability of dynamic_cast.
2014-01-23 15:23:12 -08:00
Johannes Schickel
4412e12deb BUILD: Rename libunity support variable to "USE_UNITY" instead of "USE_TASKBAR_UNITY".
This makes it consistent with other library support variables.
2014-01-21 19:01:28 +01:00
D G Turner
8b9d4348f8 SDL: Fix bug where config file path could exceed maximum path length.
The fix is the change in the MAXPATHLEN check, but have also migrated
this to Common::String to make the fix easier.

Thanks to klusark for pointing out this problem.
2013-11-14 18:35:03 +00:00
Kirben
3950dad947 SDL: Remove misleading comments, based on incomplete information at MSDN. GetLocalInfo is supported on Windows 95 onwards, but MSDN fails to mention older Windows versions. 2013-11-11 23:53:53 +11:00
Johannes Schickel
919e577ba6 SDL: Fix invalid memory access in getSystemLanguage.
A call to setlocale can invalidate the string a previous setlocale call
returned. Instead of saving a pointer we copy the returned string now. This,
for example, fixes invalid memory access on my system.

See de8da01b0e for the commit introducing the
invalid memory access.
2013-11-03 18:47:03 +01:00
D G Turner
de8da01b0e SDL: Remove side effect of setlocale() call to get Language.
This is to fix bug #3615148 -  "ALL: sscanf("%f"), atof() etc. not
portable due to Locale"

The side effect of setlocale("") is to change the active locale
from the default of "C" to the detected system locale, but this
changes the behaviour of sscanf() and several other functions
in a system dependent and non-portable way. This has caused
bugs in the ZVISION engine when running Zork Nemesis.

The solution is to restore the default "C" locale after the call
to get the language.

Thanks to criezy for working out this fix.
2013-11-03 17:10:18 +00:00
Johannes Schickel
ea6d38d5f3 SDL: Make activateManager/deactivateManager SdlGraphicsManager specific.
We can do this now that we can use virtual inheritance and dynamic_cast
because we enabled RTTI.
2013-10-24 00:06:32 +02:00
Johannes Schickel
092d36f392 SDL: Reduce code duplication a bit.
Now instead of initializing this in OSystem_SDL::initSDL (and in subclasses
overwriting this) we simply initialize it in OSystem_SDL::init.
2013-10-23 22:59:13 +02:00
Johannes Schickel
c323dedf3c SDL: Fix default graphics mode for switchable case.
The former code (incorrectly) assumed that the getDefaultGraphicsMode returns
the index in the table returned by getSupportedGraphicsModes. Now the correct
ID is searched and then used.
2013-10-23 22:59:09 +02:00
Johannes Schickel
d34c9d5bcb SDL: Do not require a static graphics mode list in OpenGL and SurfaceSDL. 2013-10-23 22:59:06 +02:00
Johannes Schickel
a9cb67df08 SDL: Only allow switching of SurfaceSDL <-> OpenGL when no custom manager is used. 2013-10-23 22:59:02 +02:00
Johannes Schickel
38543f772c SDL: Make setupGraphicsModes non-virtual.
The logic of switching the managers is pretty much fixed at the same level
and cannot be easily overwritten.
2013-10-23 22:58:57 +02:00
Johannes Schickel
17cb26b93c SDL: Simplify initial graphics manager selection for OpenGL. 2013-10-23 22:58:53 +02:00
Johannes Schickel
4080a7a3f6 SDL: Get rid of _glModesCount. 2013-10-23 22:58:50 +02:00
Johannes Schickel
c5e2b5158c SDL: Get rid of loop in OSystem_SDL::setGraphicsMode. 2013-10-23 22:58:46 +02:00
Johannes Schickel
e91300f70c SDL: Clean up graphics mode handling for OpenGL backend.
Instead of custom memory management Common::Array is used now.
2013-10-23 22:58:42 +02:00
Johannes Schickel
1a56b521b5 SDL: Always initialize video subsystem in initSDL. 2013-10-23 22:58:38 +02:00
Johannes Schickel
6e46e9dfaf SDL: Clean up graphics manager switching slighty.
Sadly this also requires us to extend GraphicsManager for this SDL specific
feature. However, since that's only used in the SDL backend and Tizen it
should be fine for now...
2013-10-23 22:58:34 +02:00
Johannes Schickel
5ce830b976 SDL: Add a OpenGL SDL backend and hook it into the SDL backend.
The hooking code is nearly exactly the old hooking code. Only the OpenGL SDL
creation has been adapted since it uses a different constructor now.
2013-10-19 22:14:24 +02:00
Johannes Schickel
8a6e57cba1 BACKENDS: Remove OpenGL and OpenGL SDL backend.
This breaks our Tizen port.
2013-10-05 00:20:02 +02:00
Matthew Hoops
4a7e4e5b22 ALL: Don't use EventRecorder at all when not compiled in 2013-07-06 23:54:45 -04:00
Eugene Sandulenko
49210a803a Merge pull request #331 from sev-/gsoc2012-eventsrecorder
GSoC2012: Event Recorder (reworked)
2013-07-04 04:58:54 -07:00
Johannes Schickel
93fc260885 SDL: Fix compilation by moving getMixerManager out of USE_OPENGL guard. 2013-07-04 14:47:25 +03:00
Johannes Schickel
86c656a75b SDL: Fix compilation on Solaris 10.
This replaces a dummy FILE definition before including the SDL headers with
simply using the toolchain's definition on Solaris. This is pretty harmless
because we only allow FILE to be used in the SDL headers by this.

Fixes bug #3614514 "#define FILE FAKE_FILE doesn't work on Solaris (w/ patch)".

Thanks to lblume for his patch!
2013-07-04 01:25:46 +02:00
Eugene Sandulenko
f59512c47e RECORDER: Implement Events Recorder 2013-05-17 00:18:09 +03:00
Thierry Crozat
67493394b3 OSX: Remove use of deprecated methods
FSRef and FSPathMakeRef have been deprecated in OS X 10.8. So we
use CFURLRef instead.
2012-11-18 01:29:09 +00:00
Max Horn
a49f55878a OSX: Improve native OS X browser dialog
Signed-off-by: Thierry Crozat <criezy@scummvm.org>
2012-11-18 01:29:08 +00:00
Johannes Schickel
89abab97e3 JANITORIAL: Remove trailing whitespaces.
Powered by:
git ls-files "*.cpp" "*.h" "*.m" "*.mm" | xargs sed -i -e 's/[ \t]*$//'
2012-09-26 04:17:55 +02:00