From: <sba...@us...> - 2023-07-19 17:45:12
|
This is an automated email from the git hooks/post-receive-user script. sbaldovi pushed a commit to branch patches-142-currah-uspeech in repository libspectrum. View the commit online: https://sourceforge.net/p/fuse-emulator/libspectrum/ci/1ec4c7dab04bf9240e405258854bfec858be500f/ commit 1ec4c7dab04bf9240e405258854bfec858be500f Author: Sergio Baldoví <ser...@gm...> AuthorDate: Wed Jul 19 19:19:44 2023 +0200 Note info loss of uSpeech when writing dsnap, sna or z80 snapshots --- doc/libspectrum.txt | 3 +++ dsnap.c | 4 ++++ sna.c | 4 ++++ z80.c | 4 ++++ 4 files changed, 15 insertions(+) diff --git a/doc/libspectrum.txt b/doc/libspectrum.txt index adbe594..9c80a48 100644 --- a/doc/libspectrum.txt +++ b/doc/libspectrum.txt @@ -729,6 +729,9 @@ The available properties (along with their types) are: * libspectrum_byte* usource_rom[1] * size_t usource_rom_length[1] +* int uspeech_active +* int uspeech_paged + * int disciple_active * int disciple_paged * int disciple_inhibit_button diff --git a/dsnap.c b/dsnap.c index e7446bb..51f57eb 100644 --- a/dsnap.c +++ b/dsnap.c @@ -306,6 +306,10 @@ libspectrum_dsnap_write( libspectrum_buffer *buffer, int *out_flags, if( libspectrum_snap_usource_active( snap ) ) *out_flags |= LIBSPECTRUM_FLAG_SNAPSHOT_MAJOR_INFO_LOSS; + /* We don't save the uSpeech state at all */ + if( libspectrum_snap_uspeech_active( snap ) ) + *out_flags |= LIBSPECTRUM_FLAG_SNAPSHOT_MAJOR_INFO_LOSS; + /* We don't save the DISCiPLE state at all */ if( libspectrum_snap_disciple_active( snap ) ) *out_flags |= LIBSPECTRUM_FLAG_SNAPSHOT_MAJOR_INFO_LOSS; diff --git a/sna.c b/sna.c index 7a4b193..08b14cc 100644 --- a/sna.c +++ b/sna.c @@ -335,6 +335,10 @@ libspectrum_sna_write( libspectrum_buffer *buffer, int *out_flags, if( libspectrum_snap_usource_active( snap ) ) *out_flags |= LIBSPECTRUM_FLAG_SNAPSHOT_MAJOR_INFO_LOSS; + /* We don't save the uSpeech state at all */ + if( libspectrum_snap_uspeech_active( snap ) ) + *out_flags |= LIBSPECTRUM_FLAG_SNAPSHOT_MAJOR_INFO_LOSS; + /* We don't save the DISCiPLE state at all */ if( libspectrum_snap_disciple_active( snap ) ) *out_flags |= LIBSPECTRUM_FLAG_SNAPSHOT_MAJOR_INFO_LOSS; diff --git a/z80.c b/z80.c index f7985f1..5cce467 100644 --- a/z80.c +++ b/z80.c @@ -1179,6 +1179,10 @@ libspectrum_z80_write2( libspectrum_buffer *buffer, int *out_flags, if( libspectrum_snap_usource_active( snap ) ) *out_flags |= LIBSPECTRUM_FLAG_SNAPSHOT_MAJOR_INFO_LOSS; + /* .z80 format doesn't save the uSpeech state at all */ + if( libspectrum_snap_uspeech_active( snap ) ) + *out_flags |= LIBSPECTRUM_FLAG_SNAPSHOT_MAJOR_INFO_LOSS; + /* .z80 format doesn't save the DISCiPLE state well but we don't support what is there either */ if( libspectrum_snap_disciple_active( snap ) ) |