Commit Graph
12 Commits
Author SHA1 Message Date
Bastien Bouclet 42e4283b4b MORTEVIELLE: Push down the AD includes 2018-05-01 12:48:05 +02:00
Adrian Frühwirth 00e59a3122 ALL: Load savegame thumbnail only when necessary
This commit introduces the following changes:

1. Graphics::loadThumbnail()

   Now returns a boolean and takes a new argument skipThumbnail which
   defaults to false. In case of true, loadThumbnail() reads past the
   thumbnail data in the input stream instead of actually loading the
   thumbnail. This simplifies savegame handling where, up until now,
   many engines always read the whole savegame metadata (including
   the thumbnail) and then threw away the thumbnail when not needed
   (which is in almost all cases, the most common exception being
   MetaEngine::querySaveMetaInfos() which is responsible for loading
   savegame metadata for displaying it in the GUI launcher.

2. readSavegameHeader()

   Engines which already implement such a method (name varies) now take
   a new argument skipThumbnail (default: true) which is passed
   through to loadThumbnail(). This means that the default case for
   readSavegameHeader() is now _not_ loading the thumbnail from a
   savegame and just reading past it. In those cases, e.g.
   querySaveMetaInfos(), where we actually are interested in loading
   the thumbnail readSavegameHeader() needs to explicitely be called
   with skipThumbnail == false.

   Engines whose readSavegameHeader() (name varies) already takes an
   argument loadThumbnail have been adapted to have a similar
   prototype and semantics.
   I.e. readSaveHeader(in, loadThumbnail, header) now is
   readSaveHeader(in, header, skipThumbnail).

3. Error handling

   Engines which previously did not check the return value of
   readSavegameHeader() (name varies) now do so ensuring that possibly
   broken savegames (be it a broken thumbnail or something else) don't
   make it into the GUI launcher list in the first place.
2018-04-07 09:26:20 +02:00
Johannes Schickel 9da7d86952 MORTEVIELLE: Make GPL headers consistent in themselves. 2014-02-18 02:39:36 +01:00
Strangerke b3c377aacd MORTEVIELLE: Get rid of setParent() 2014-01-10 01:46:38 +01:00
Strangerke 972cdf0e12 MORTEVIELLE: Avoid erroring out when the user tries to load a missing save game 2013-08-21 08:37:55 +02:00
Strangerke ee6bb6719c MORTEVIELLE: Janitorial: Misc cosmetic changes 2013-07-23 09:13:32 +02:00
Paul Gilbert e14278eb58 MORTEVIELLE: Changed savegames to use the game target to generate filenames 2013-07-13 19:10:03 -04:00
Strangerke 10a23f4d92 MORTEVIELLE: Remove useless static 2013-06-26 23:16:49 +02:00
Strangerke b27b77b354 MORTEVIELLE: Modify copyright string to include 1987. 2012-04-06 08:24:07 +02:00
Strangerke 09e8c82e8f MORTEVIELLE: More renaming 2012-04-06 08:23:42 +02:00
Strangerke fc14ffbcb5 MORTEVIELLE: Some more renaming 2012-04-06 08:23:28 +02:00
Paul Gilbert bae25fc2aa MORTEVIELLE: Implemented ScummVM savegame functionality with metadata 2012-04-06 08:20:55 +02:00