scummvm/common
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
..
algorithm.h JANITORIAL: Remove more trailing spaces 2016-10-09 15:02:02 +02:00
archive.cpp Revert "COMMON: Change way the Singleton instances are instantiated" 2017-07-10 21:17:41 +02:00
archive.h COMMON: Add comparator for sorting ArchiveMemberList 2017-09-08 16:02:32 -05:00
array.h COMMON: Allow construction of Arrays of non-copyable members 2017-10-06 22:10:50 -05:00
bitstream.h COMMON: Optimize BitStream::getBits 2017-08-24 19:46:59 +02:00
bufferedstream.h COMMON: Make GPL headers consistent in themselves. 2014-02-18 02:39:33 +01:00
c++11-compat.h COMMON: Add reference links for the enabled C++11 features in MSVC 2014-10-28 14:26:19 +02:00
callback.h Fix comment formatting 2016-08-24 16:07:55 +06:00
config-manager.cpp Revert "COMMON: Change way the Singleton instances are instantiated" 2017-07-10 21:17:41 +02:00
config-manager.h CLOUD: Add Dropbox into CloudManager's configs 2016-08-24 16:07:55 +06:00
coroutines.cpp Revert "COMMON: Change way the Singleton instances are instantiated" 2017-07-10 21:17:41 +02:00
coroutines.h COMMON: Make GPL headers consistent in themselves. 2014-02-18 02:39:33 +01:00
cosinetables.cpp COMMON: Make GPL headers consistent in themselves. 2014-02-18 02:39:33 +01:00
cosinetables.h COMMON: Make GPL headers consistent in themselves. 2014-02-18 02:39:33 +01:00
dcl.cpp COMMON: Fix UB, left shift of negative value 2018-03-22 22:16:24 +01:00
dcl.h COMMON: The DCL decompressor is also used in neverhood 2015-11-19 02:05:12 +02:00
dct.cpp COMMON: Use float constants in DCT code. 2014-06-02 01:00:15 +02:00
dct.h COMMON: Make GPL headers consistent in themselves. 2014-02-18 02:39:33 +01:00
debug-channels.h COMMON: Enhanced debug channel checks. 2017-01-09 09:22:35 +01:00
debug.cpp Revert "COMMON: Change way the Singleton instances are instantiated" 2017-07-10 21:17:41 +02:00
debug.h COMMON: Enhanced debug channel checks. 2017-01-09 09:22:35 +01:00
endian.h COMMON: Unconditionally enable 64 bit integer features 2017-09-30 21:35:16 +02:00
error.cpp ALL: game state => saved game 2016-11-29 20:15:20 +01:00
error.h COMMON: Make GPL headers consistent in themselves. 2014-02-18 02:39:33 +01:00
EventDispatcher.cpp COMMON: Only clear events from the EventSources in clearEvents() 2017-07-27 21:05:43 +01:00
EventMapper.cpp VKEYBD: Remove Unused Variable. 2017-01-12 09:59:27 +00:00
events.h COMMON: Improve spacing between members in the event structs 2017-11-19 20:16:10 +01:00
fft.cpp COMMON: Plug a memory leak in the FFT class 2015-07-13 18:45:31 +02:00
fft.h COMMON: Add getRevTab to FFT 2015-02-01 10:35:23 +01:00
file.cpp JANITORIAL: Remove spaces at the end of the line 2016-08-24 16:07:55 +06:00
file.h CLOUD: Make download() create necessary directories 2016-08-24 16:07:55 +06:00
forbidden.h BUILD: Fixed mingw-w64 32 bits build 2017-03-10 00:07:09 +01:00
frac.h COMMON: Fix UB shifting negative integers 2017-12-01 19:22:24 -06:00
fs.cpp COMMON: Make GPL headers consistent in themselves. 2014-02-18 02:39:33 +01:00
fs.h COMMON: Make FSNode(AbstractFSNode *) private again. 2016-01-07 11:25:02 +01:00
func.h COMMON: Make GPL headers consistent in themselves. 2014-02-18 02:39:33 +01:00
gui_options.cpp SCI32: Toggle Phant2 content censoring from game options 2017-09-08 16:03:24 -05:00
gui_options.h SCI32: Toggle Phant2 content censoring from game options 2017-09-08 16:03:24 -05:00
hash-ptr.h COMMON: Introduce a shared hash function for pointer types 2017-09-30 21:35:16 +02:00
hash-str.h COMMON: Make GPL headers consistent in themselves. 2014-02-18 02:39:33 +01:00
hashmap.cpp COMMON: Make GPL headers consistent in themselves. 2014-02-18 02:39:33 +01:00
hashmap.h COMMON: Make GPL headers consistent in themselves. 2014-02-18 02:39:33 +01:00
huffman.cpp COMMON: Remove BitStream base class to allow inlining calls 2017-08-24 19:46:59 +02:00
huffman.h COMMON: Remove BitStream base class to allow inlining calls 2017-08-24 19:46:59 +02:00
iff_container.cpp COMMON: Make GPL headers consistent in themselves. 2014-02-18 02:39:33 +01:00
iff_container.h COMMON: Make GPL headers consistent in themselves. 2014-02-18 02:39:33 +01:00
ini-file.cpp COMMON: Make GPL headers consistent in themselves. 2014-02-18 02:39:33 +01:00
ini-file.h COMMON: Make GPL headers consistent in themselves. 2014-02-18 02:39:33 +01:00
installshield_cab.cpp COMMON: Make GPL headers consistent in themselves. 2014-02-18 02:39:33 +01:00
installshield_cab.h COMMON: Make GPL headers consistent in themselves. 2014-02-18 02:39:33 +01:00
json.cpp COMMON: Replace sprintf() with safer String::format() in JSON module. 2017-01-12 04:50:45 +00:00
json.h JANITORIAL: Make GPL headers uniform 2016-09-03 12:46:38 +02:00
keyboard.h COMMON: Make GPL headers consistent in themselves. 2014-02-18 02:39:33 +01:00
language.cpp COMMON: Verify nb_NO locale 2018-04-04 22:48:28 +02:00
language.h COMMON: Added Estonian language 2016-12-04 15:21:37 +01:00
list_intern.h COMMON: Make GPL headers consistent in themselves. 2014-02-18 02:39:33 +01:00
list.h COMMON: Make GPL headers consistent in themselves. 2014-02-18 02:39:33 +01:00
localization.cpp COMMON: Make GPL headers consistent in themselves. 2014-02-18 02:39:33 +01:00
localization.h COMMON: Fix some Doxygen comments that seem wrong. 2014-08-29 03:28:00 +02:00
macresman.cpp COMMON: Cleanup: Use StringArray instead of custom type. 2016-03-01 19:18:23 +01:00
macresman.h GRAPHICS: Rename MacFont to MacFONTFont to avoid clashed 2017-01-17 20:30:32 +01:00
math.h ALL: Remove obsolete register keyword 2017-12-03 20:27:42 -06:00
md5.cpp COMMON: Make GPL headers consistent in themselves. 2014-02-18 02:39:33 +01:00
md5.h COMMON: Make GPL headers consistent in themselves. 2014-02-18 02:39:33 +01:00
memory.h COMMON: Add standard count & count+copy array constructors 2017-09-30 11:17:53 +02:00
memorypool.cpp COMMON: Make GPL headers consistent in themselves. 2014-02-18 02:39:33 +01:00
memorypool.h COMMON: Make GPL headers consistent in themselves. 2014-02-18 02:39:33 +01:00
memstream.h COMMON: Remove DisposeAfterUse default value from dynamic write memory streams 2017-09-22 07:06:21 +02:00
module.mk COMMON: Add OSDMessageQueue singleton 2016-10-29 15:13:32 +01:00
mutex.cpp COMMON: Make GPL headers consistent in themselves. 2014-02-18 02:39:33 +01:00
mutex.h COMMON: Make GPL headers consistent in themselves. 2014-02-18 02:39:33 +01:00
noncopyable.h COMMON: Make GPL headers consistent in themselves. 2014-02-18 02:39:33 +01:00
osd_message_queue.cpp Revert "COMMON: Change way the Singleton instances are instantiated" 2017-07-10 21:17:41 +02:00
osd_message_queue.h COMMON: Add referencing and destruction of the OSDMessageQueue instance 2016-10-29 15:13:32 +01:00
pack-end.h COMMON: Make GPL headers consistent in themselves. 2014-02-18 02:39:33 +01:00
pack-start.h COMMON: Make GPL headers consistent in themselves. 2014-02-18 02:39:33 +01:00
platform.cpp COMMON: Add Atari 8-bit platform 2016-08-29 17:52:36 +02:00
platform.h COMMON: Add Atari 8-bit platform 2016-08-29 17:52:36 +02:00
ptr.h COMMON: Add a reset method to DisposablePtr 2017-12-28 21:18:51 +01:00
queue.h COMMON: Make GPL headers consistent in themselves. 2014-02-18 02:39:33 +01:00
quicktime.cpp VIDEO: Change QT edit list to a Common::Array 2017-09-21 13:06:18 +02:00
quicktime.h VIDEO: Change QT edit list to a Common::Array 2017-09-21 13:06:18 +02:00
random.cpp COMMON: Make GPL headers consistent in themselves. 2014-02-18 02:39:33 +01:00
random.h COMMON: Make GPL headers consistent in themselves. 2014-02-18 02:39:33 +01:00
rational.cpp COMMON: Make GPL headers consistent in themselves. 2014-02-18 02:39:33 +01:00
rational.h COMMON: Add convenience method to Common::Rational for 1:1 ratios 2016-02-18 13:18:02 -06:00
rdft.cpp COMMON: Some formatting fixes in RDFT code. 2014-06-02 01:00:15 +02:00
rdft.h COMMON: Make GPL headers consistent in themselves. 2014-02-18 02:39:33 +01:00
recorderfile.cpp ALL: Load savegame thumbnail only when necessary 2018-04-07 09:26:20 +02:00
recorderfile.h COMMON: Make GPL headers consistent in themselves. 2014-02-18 02:39:33 +01:00
rect.h COMMON: Add helper macro for printing rects 2017-09-04 23:57:19 +02:00
rendermode.cpp COMMON: Add render mode for Macintosh. 2016-02-05 12:38:28 +01:00
rendermode.h COMMON: Add render mode for Macintosh. 2016-02-05 12:38:28 +01:00
safe-bool.h COMMON: Add Span to common library 2017-01-08 13:20:23 -06:00
savefile.h COMMON: Fix WriteStream::pos() once again 2016-08-24 16:24:16 +06:00
scummsys.h COMMON: Add WARN_UNUSED_RESULT to scummsys.h 2018-04-04 20:56:41 +00:00
serializer.h COMMON: Move VER macro for serializer into common code 2018-01-31 17:58:01 +01:00
sinetables.cpp COMMON: Make GPL headers consistent in themselves. 2014-02-18 02:39:33 +01:00
sinetables.h COMMON: Make GPL headers consistent in themselves. 2014-02-18 02:39:33 +01:00
singleton.h Revert "COMMON: Change way the Singleton instances are instantiated" 2017-07-10 21:17:41 +02:00
span.h COMMON: Take immutable reference in SpanOwner copy assignment 2017-06-08 20:04:37 -05:00
stack.h COMMON: Make GPL headers consistent in themselves. 2014-02-18 02:39:33 +01:00
str-array.h COMMON: Make GPL headers consistent in themselves. 2014-02-18 02:39:33 +01:00
str.cpp COMMON: Add basic fixed-width word wrap to Common::String 2017-11-10 09:57:41 -06:00
str.h COMMON: Add basic fixed-width word wrap to Common::String 2017-11-10 09:57:41 -06:00
stream.cpp COMMON: Add ReadStream::readPascalString() 2017-01-14 12:45:58 +01:00
stream.h COMMON: Unconditionally enable 64 bit integer features 2017-09-30 21:35:16 +02:00
substream.h COMMON: Make GPL headers consistent in themselves. 2014-02-18 02:39:33 +01:00
system.cpp COMMON: Remove the EventRecorder dependency from OSystem 2016-07-28 18:23:46 +02:00
system.h BACKENDS: Make initSizeHint an optional extension point 2017-10-07 12:30:29 -05:00
taskbar.h JANITORIAL: Typos detected with lintian & grep 2016-02-15 18:27:02 +01:00
textconsole.cpp COMMON: Make GPL headers consistent in themselves. 2014-02-18 02:39:33 +01:00
textconsole.h COMMON: Make GPL headers consistent in themselves. 2014-02-18 02:39:33 +01:00
timer.h COMMON: Make GPL headers consistent in themselves. 2014-02-18 02:39:33 +01:00
tokenizer.cpp COMMON: Make GPL headers consistent in themselves. 2014-02-18 02:39:33 +01:00
tokenizer.h COMMON: Make GPL headers consistent in themselves. 2014-02-18 02:39:33 +01:00
translation.cpp Revert "COMMON: Change way the Singleton instances are instantiated" 2017-07-10 21:17:41 +02:00
translation.h COMMON: Make GPL headers consistent in themselves. 2014-02-18 02:39:33 +01:00
type-traits.h COMMON: Add type traits to common library 2017-01-08 13:20:23 -06:00
types.h COMMON: Make GPL headers consistent in themselves. 2014-02-18 02:39:33 +01:00
unarj.cpp COMMON: Fix missing arjDecoder class variable init. CID 1002929 2013-10-05 07:02:18 +01:00
unarj.h
unzip.cpp COMMON: Disable unused string 2014-12-07 17:49:55 +02:00
unzip.h COMMON: Make GPL headers consistent in themselves. 2014-02-18 02:39:33 +01:00
updates.cpp UPDATES: Fix interval normalization 2016-04-09 21:47:20 +01:00
updates.h UPDATES: Implemented method getLastUpdateCheckTimeAndDate() 2016-04-09 17:04:04 +02:00
ustr.cpp COMMON: Make GPL headers consistent in themselves. 2014-02-18 02:39:33 +01:00
ustr.h COMMON: Make GPL headers consistent in themselves. 2014-02-18 02:39:33 +01:00
util.cpp TITANIC: Implement TTparser normalize 2016-07-10 16:39:35 -04:00
util.h COMMON: Fix Doxygen comment 2018-03-29 00:19:33 +02:00
winexe_ne.cpp COMMON: Make GPL headers consistent in themselves. 2014-02-18 02:39:33 +01:00
winexe_ne.h COMMON: Make GPL headers consistent in themselves. 2014-02-18 02:39:33 +01:00
winexe_pe.cpp COMMON: Make GPL headers consistent in themselves. 2014-02-18 02:39:33 +01:00
winexe_pe.h COMMON: Make GPL headers consistent in themselves. 2014-02-18 02:39:33 +01:00
winexe.cpp COMMON: Make GPL headers consistent in themselves. 2014-02-18 02:39:33 +01:00
winexe.h COMMON: Make GPL headers consistent in themselves. 2014-02-18 02:39:33 +01:00
xmlparser.cpp JANITORIAL: Remove spaces at the end of the line 2016-08-24 16:07:55 +06:00
xmlparser.h
zlib.cpp COMMON: Update GZipWriteStream::pos() 2016-08-04 15:14:06 +06:00
zlib.h COMMON: Added freeing notes to zlib wrapper methods 2017-08-12 20:17:56 -04:00