[Scummvm-git-logs] scummvm master -> a6110de8a8bca975615e0c7a14f8ccde733d3701

sev- noreply at scummvm.org
Fri Sep 12 09:39:43 UTC 2025


This automated email contains information about 4 new commits which have been
pushed to the 'scummvm' repo located at https://api.github.com/repos/scummvm/scummvm .

Summary:
ed6c4afdcc DIRECTOR: Add girltechhomepage to detection tables
fc56e78b51 DIRECTOR: Add D6 equality table
2292c41abd DIRECTOR: Implement MoaSoundFormat
a6110de8a8 VIDEO: QTVR: Remove dependency on timer thread


Commit: ed6c4afdcc17d76a23ff904d00ba6d7fc5620d63
    https://github.com/scummvm/scummvm/commit/ed6c4afdcc17d76a23ff904d00ba6d7fc5620d63
Author: Scott Percival (code at moral.net.au)
Date: 2025-09-12T11:39:37+02:00

Commit Message:
DIRECTOR: Add girltechhomepage to detection tables

Changed paths:
    engines/director/detection_tables.h


diff --git a/engines/director/detection_tables.h b/engines/director/detection_tables.h
index f70f3add4fb..e175fd5b158 100644
--- a/engines/director/detection_tables.h
+++ b/engines/director/detection_tables.h
@@ -657,6 +657,7 @@ static const PlainGameDescriptor directorGames[] = {
 	{ "fusion",				"Harnessing the Energy of the Stars" },
 	{ "futureview",			"FutureView: The 1990s and Beyond" },
 	{ "ghetto",				"Stories from the Warsaw Ghetto" },
+	{ "girltechhomepage",	"Girl Tech's Home Page Builder" },
 	{ "golfcd",				"The Great Golf CD: Links, Legends & Lore" },
 	{ "gondwana",			"We're Not On The Internet - So What!" }, // Gondwana Project 1996 disc
 	{ "gp2006",				"Grand Prix 2006 & Auto Directory" },
@@ -5989,6 +5990,11 @@ static const DirectorGameDescription gameDescriptions[] = {
 	MACGAME1("teamxtreme2", "", "Copy to HD/TX2", "r:f47c738636947451579473d9fe36041c", 507980, 404),
 	WINGAME1("teamxtreme2", "", "COPY2HD/TX2.EXE", "50c80bd2add25e574494838772973beb", 2585471, 404),
 
+	MACGAME1("tenchijukebox", "8-bit",	"Tenchi Muyo Jukebox 8 bit", "r:0c7bbb4b24823e5ab871cb4c1d6f3710", 482610, 404),
+	MACGAME1("tenchijukebox", "16-bit", "Tenchi Muyo Jukebox 16 bit", "r:0c7bbb4b24823e5ab871cb4c1d6f3710", 482610, 404),
+	WINGAME1("tenchijukebox", "8-bit",	"TEN8.EXE",	 "t:e5dc70d28dc9e67f60670a20f2f5319e", 4356061, 404),
+	WINGAME1("tenchijukebox", "16-bit", "TEN16.EXE", "t:c852d86aff7011765be102ce5dad95c8", 5323255, 404),
+
 	// Found on World of Whales
 	MACGAME1("terapreviews", "", "TeraMedia Previews", 	 "rt:9e4c0af102f40d2ae8ec4a131b5d9c3a",  483490, 404),
 	WINGAME2("terapreviews", "", "PREVIEWS.EXE",	  	 "t:9289cacef6dcea38e69554ac27ff59f1",   866108,
@@ -7916,10 +7922,8 @@ static const DirectorGameDescription gameDescriptions[] = {
 	WINGAME1("teazle", "",		"TEAZLE.EXE",	"t:b6d3a1d0f44fa23f544569cf97d98126", 1420271, 500),
 	MACGAME1("teazle", "",		"TZPL01",		"tr:50b6f06b9dfad624252d34f5ee8cd877", 112402, 500),
 
-	MACGAME1("tenchijukebox", "8-bit",	"Tenchi Muyo Jukebox 8 bit", "r:0c7bbb4b24823e5ab871cb4c1d6f3710", 482610, 404),
-	MACGAME1("tenchijukebox", "16-bit", "Tenchi Muyo Jukebox 16 bit", "r:0c7bbb4b24823e5ab871cb4c1d6f3710", 482610, 404),
-	WINGAME1("tenchijukebox", "8-bit",	"TEN8.EXE",	 "t:e5dc70d28dc9e67f60670a20f2f5319e", 4356061, 404),
-	WINGAME1("tenchijukebox", "16-bit", "TEN16.EXE", "t:c852d86aff7011765be102ce5dad95c8", 5323255, 404),
+	WINGAME1("girltechhomepage", "",	"MYHOMEPG.EXE", "t:1d74092e20738ed5661ea5d68c0c0c36", 1410487, 501),
+	MACGAME1("girltechhomepage", "",	"My Home Page", "r:6b82167b30f99bdfa6ee64fbde0b83fd", 718097, 501),
 
 	// Original Mac filename is "天楼都市フォルダ/天楼都市 for Mac"
 	// "0_tenrou.exe" doesn't add "Opning" to the search path, Readme.txt says to use "tenrou.exe"


Commit: fc56e78b51066f34da0c21b43a7eb137d8ffda60
    https://github.com/scummvm/scummvm/commit/fc56e78b51066f34da0c21b43a7eb137d8ffda60
Author: Scott Percival (code at moral.net.au)
Date: 2025-09-12T11:39:37+02:00

Commit Message:
DIRECTOR: Add D6 equality table

Changed paths:
    engines/director/util.cpp


diff --git a/engines/director/util.cpp b/engines/director/util.cpp
index d6b553441c3..f58ce91cfdb 100644
--- a/engines/director/util.cpp
+++ b/engines/director/util.cpp
@@ -1659,6 +1659,30 @@ const byte equalityTableD5win[256] = {
 	0xd0, 0x98, 0x9c, 0x9e, 0x9d, 0xd5, 0xd6, 0xf7, 0xd8, 0xd9, 0xda, 0xdb, 0xdc, 0xdd, 0xde, 0x9f
 };
 
+
+//
+// Director 6 Win, cp1252 encoding
+//
+
+const byte equalityTableD6win[256] = {
+	0x0, 0x1, 0x2, 0x3, 0x4, 0x5, 0x6, 0x7, 0x8, 0x9, 0xa, 0xb, 0xc, 0xd, 0xe, 0xf,
+	0x10, 0x11, 0x12, 0x13, 0x14, 0x15, 0x16, 0x17, 0x18, 0x19, 0x1a, 0x1b, 0x1c, 0x1d, 0x1e, 0x1f,
+	0x20, 0x21, 0x22, 0x23, 0x24, 0x25, 0x26, 0x27, 0x28, 0x29, 0x2a, 0x2b, 0x2c, 0x2d, 0x2e, 0x2f,
+	0x30, 0x31, 0x32, 0x33, 0x34, 0x35, 0x36, 0x37, 0x38, 0x39, 0x3a, 0x3b, 0x3c, 0x3d, 0x3e, 0x3f,
+	0x40, 0x41, 0x42, 0x43, 0x44, 0x45, 0x46, 0x47, 0x48, 0x49, 0x4a, 0x4b, 0x4c, 0x4d, 0x4e, 0x4f,
+	0x50, 0x51, 0x52, 0x53, 0x54, 0x55, 0x56, 0x57, 0x58, 0x59, 0x5a, 0x5b, 0x5c, 0x5d, 0x5e, 0x5f,
+	0x60, 0x41, 0x42, 0x43, 0x44, 0x45, 0x46, 0x47, 0x48, 0x49, 0x4a, 0x4b, 0x4c, 0x4d, 0x4e, 0x4f,
+	0x50, 0x51, 0x52, 0x53, 0x54, 0x55, 0x56, 0x57, 0x58, 0x59, 0x5a, 0x7b, 0x7c, 0x7d, 0x7e, 0x7f,
+	0x80, 0x81, 0x82, 0x83, 0x84, 0x85, 0x86, 0x87, 0x88, 0x89, 0x8a, 0x8b, 0x8c, 0x8d, 0x8e, 0x8f,
+	0x90, 0x91, 0x92, 0x93, 0x94, 0x95, 0x96, 0x97, 0x98, 0x99, 0x8a, 0x9b, 0x8c, 0x9d, 0x9e, 0x9f,
+	0xa0, 0xa1, 0xa2, 0xa3, 0xa4, 0xa5, 0xa6, 0xa7, 0xa8, 0xa9, 0xaa, 0xab, 0xac, 0xad, 0xae, 0xaf,
+	0xb0, 0xb1, 0xb2, 0xb3, 0xb4, 0xb5, 0xb6, 0xb7, 0xb8, 0xb9, 0xba, 0xbb, 0xbc, 0xbd, 0xbe, 0xbf,
+	0xc0, 0xc1, 0xc2, 0xc3, 0xc4, 0xc5, 0xc6, 0xc7, 0xc8, 0xc9, 0xca, 0xcb, 0xcc, 0xcd, 0xce, 0xcf,
+	0xd0, 0xd1, 0xd2, 0xd3, 0xd4, 0xd5, 0xd6, 0xd7, 0xd8, 0xd9, 0xda, 0xdb, 0xdc, 0xdd, 0xde, 0xdf,
+	0xc0, 0xc1, 0xc2, 0xc3, 0xc4, 0xc5, 0xc6, 0xc7, 0xc8, 0xc9, 0xca, 0xcb, 0xcc, 0xcd, 0xce, 0xcf,
+	0xd0, 0x98, 0x8c, 0x9e, 0x9d, 0xd5, 0xd6, 0xf7, 0xd8, 0xd9, 0xda, 0xdb, 0xdc, 0xdd, 0xde, 0x9f
+};
+
 //
 // Director 3, 4, 5 Mac MacRoman
 //
@@ -1753,6 +1777,9 @@ static int getCharEquality(Common::u32char_type_t ch) {
 	if (pl == Common::kPlatformWindows && lang != Common::JA_JPN && version < 600)
 		return equalityTableD5win[num];
 
+	if (pl == Common::kPlatformWindows && lang != Common::JA_JPN && version < 700)
+		return equalityTableD6win[num];
+
 	warning("BUILDBOT: No equality table for Director version: %d", version);
 	return num;
 }


Commit: 2292c41abd2b0710fcd1bc338d4e9fce34c03c1d
    https://github.com/scummvm/scummvm/commit/2292c41abd2b0710fcd1bc338d4e9fce34c03c1d
Author: Scott Percival (code at moral.net.au)
Date: 2025-09-12T11:39:37+02:00

Commit Message:
DIRECTOR: Implement MoaSoundFormat

Changed paths:
    engines/director/cast.cpp
    engines/director/castmember/sound.cpp
    engines/director/sound.cpp
    engines/director/sound.h


diff --git a/engines/director/cast.cpp b/engines/director/cast.cpp
index fba044277b8..182440a129a 100644
--- a/engines/director/cast.cpp
+++ b/engines/director/cast.cpp
@@ -2091,9 +2091,9 @@ void Cast::loadCastInfo(Common::SeekableReadStreamEndian &stream, uint16 id) {
 	}
 
 	// For SoundCastMember, read the flags in the CastInfo
-	if (_version >= kFileVer400 && _version < kFileVer600 && member->_type == kCastSound) {
+	if (_version >= kFileVer400 && _version < kFileVer700 && member->_type == kCastSound) {
 		((SoundCastMember *)member)->_looping = castInfo.flags & 16 ? 0 : 1;
-	} else if (_version >= kFileVer600 && member->_type == kCastSound) {
+	} else if (_version >= kFileVer700 && member->_type == kCastSound) {
 		warning("STUB: Cast::loadCastInfo(): Sound cast member info not yet supported for version v%d (%d)", humanVersion(_version), _version);
 	}
 
diff --git a/engines/director/castmember/sound.cpp b/engines/director/castmember/sound.cpp
index f2bbbc3230e..0a9c648ff86 100644
--- a/engines/director/castmember/sound.cpp
+++ b/engines/director/castmember/sound.cpp
@@ -63,6 +63,8 @@ void SoundCastMember::load() {
 	uint32 tag = 0;
 	uint16 sndId = 0;
 
+	MoaSoundFormatDecoder *sndFormat = nullptr;
+
 	if (_cast->_version < kFileVer400) {
 		tag = MKTAG('S', 'N', 'D', ' ');
 		sndId = (uint16)(_castId + _cast->_castIDoffset);
@@ -79,10 +81,37 @@ void SoundCastMember::load() {
 			tag = MKTAG('S', 'N', 'D', ' ');
 			sndId = (uint16)(_castId + _cast->_castIDoffset);
 		}
+	} else if (_cast->_version >= kFileVer600 && _cast->_version < kFileVer700) {
+		for (auto &it : _children) {
+			if (it.tag == MKTAG('s', 'n', 'd', ' ')) {
+				sndId = it.index;
+				tag = it.tag;
+			} else if (it.tag == MKTAG('s', 'n', 'd', 'H')) {
+				Common::SeekableReadStreamEndian *sndData = _cast->getResource(it.tag, it.index);
+				if (!sndFormat)
+					sndFormat = new MoaSoundFormatDecoder();
+				sndFormat->loadHeaderStream(*sndData);
+				delete sndData;
+			} else if (it.tag == MKTAG('s', 'n', 'd', 'S')) {
+				Common::SeekableReadStreamEndian *sndData = _cast->getResource(it.tag, it.index);
+				if (!sndFormat)
+					sndFormat = new MoaSoundFormatDecoder();
+				sndFormat->loadSampleStream(*sndData);
+				delete sndData;
+			}
+		}
+
 	} else {
 		warning("STUB: SoundCastMember::SoundCastMember(): Sounds not yet supported for version v%d (%d)", humanVersion(_cast->_version), _cast->_version);
 	}
 
+
+	if (sndFormat) {
+		_audio = sndFormat;
+		_loaded = true;
+		return;
+	}
+
 	Common::SeekableReadStreamEndian *sndData = _cast->getResource(tag, sndId);
 	if (!sndData) {
 		tag = MKTAG('s', 'n', 'd', ' ');
diff --git a/engines/director/sound.cpp b/engines/director/sound.cpp
index df60ecf26f6..f41f5bca48c 100644
--- a/engines/director/sound.cpp
+++ b/engines/director/sound.cpp
@@ -976,4 +976,84 @@ Audio::AudioStream *AudioFileDecoder::getAudioStream(bool looping, bool forPuppe
 	return nullptr;
 }
 
+MoaSoundFormatDecoder::MoaSoundFormatDecoder() {
+
+}
+
+MoaSoundFormatDecoder::~MoaSoundFormatDecoder() {
+	if (_data) {
+		free(_data);
+		_data = nullptr;
+	}
+}
+
+bool MoaSoundFormatDecoder::loadHeaderStream(Common::SeekableReadStreamEndian &stream) {
+	_format.offset = stream.readSint32BE();
+	_format.size = stream.readSint32BE();
+	_format.playbackStart = stream.readSint32BE();
+	_format.playbackStartFrame = stream.readSint32BE();
+	_format.loopStart = stream.readSint32BE();
+	_format.loopStartFrame = stream.readSint32BE();
+	_format.loopEnd = stream.readSint32BE();
+	_format.loopEndFrame = stream.readSint32BE();
+	_format.playbackEnd = stream.readSint32BE();
+	_format.playbackEndFrame = stream.readSint32BE();
+	_format.numFrames = stream.readSint32BE();
+	_format.frameRate = stream.readSint32BE();
+	_format.byteRate = stream.readSint32BE();
+	stream.read(_format.compressionType, 16);
+	_format.bitsPerSample = stream.readSint32BE();
+	_format.bytesPerSample = stream.readSint32BE();
+	_format.numChannels = stream.readSint32BE();
+	_format.bytesPerFrame = stream.readSint32BE();
+	stream.read(_format.soundHeaderType, 16);
+	for (int i = 0; i < 63; i++) {
+		_format.platformData[i] = stream.readUint32BE();
+	}
+	_format.bytesPerBlock = stream.readSint32BE();
+
+	if (debugChannelSet(5, kDebugLoading)) {
+		debugC(5, kDebugLoading, "MoaSoundFormatDecoder: Loading header");
+		debugC(5, kDebugLoading, "offset: %d, size: %d, playbackStart: %d, playbackStartFrame: %d",
+		_format.offset, _format.size, _format.playbackStart, _format.playbackStartFrame);
+		debugC(5, kDebugLoading, "loopStart: %d, loopStartEndFrame: %d, loopEnd: %d, loopEndFrame: %d",
+		_format.loopStart, _format.loopStartFrame, _format.loopEnd, _format.loopEndFrame);
+		debugC(5, kDebugLoading, "playbackEnd: %d, playbackEndFrame: %d, numFrames: %d, frameRate: %d, byteRate: %d",
+		_format.playbackEnd, _format.playbackEndFrame, _format.numFrames, _format.frameRate, _format.byteRate);
+		debugC(5, kDebugLoading, "bitsPerSample: %d, bytesPerSample: %d, numChannels: %d, bytesPerFrame: %d, bytesPerBlock: %d",
+		_format.bitsPerSample, _format.bytesPerSample, _format.numChannels, _format.bytesPerFrame, _format.bytesPerBlock);
+
+	}
+	return false;
+}
+
+bool MoaSoundFormatDecoder::loadSampleStream(Common::SeekableReadStreamEndian &stream) {
+	_size = stream.size();
+	if (_data) {
+		free(_data);
+		_data = nullptr;
+	}
+	_data = (byte *)malloc(_size);
+	stream.read(_data, _size);
+	return false;
+}
+
+Audio::AudioStream *MoaSoundFormatDecoder::getAudioStream(bool looping, bool forPuppet, DisposeAfterUse::Flag disposeAfterUse) {
+	if (!_data)
+		return nullptr;
+	byte *buffer = (byte *)malloc(_size);
+	memcpy(buffer, _data, _size);
+
+	Audio::SeekableAudioStream *stream = Audio::makeRawStream(buffer, _size, _format.frameRate, ((_format.bitsPerSample == 16) ? Audio::RawFlags::FLAG_16BITS : 0) | ((_format.numChannels == 2) ? Audio::RawFlags::FLAG_STEREO : 0), disposeAfterUse);
+
+	if (looping) {
+		if (_format.loopEndFrame < _format.loopStartFrame) {
+			return new Audio::LoopingAudioStream(stream, 0);
+		} else {
+			return new Audio::SubLoopingAudioStream(stream, 0, Audio::Timestamp(0, _format.loopStartFrame, _format.frameRate), Audio::Timestamp(0, _format.loopEndFrame, _format.frameRate));
+		}
+	}
+	return stream;
+};
+
 } // End of namespace Director
diff --git a/engines/director/sound.h b/engines/director/sound.h
index 8dedb9673fa..03daf800d72 100644
--- a/engines/director/sound.h
+++ b/engines/director/sound.h
@@ -289,6 +289,46 @@ private:
 	Common::MacResManager *_macresman;
 };
 
+// Source: mixsnd.h in the Director 7 XDK
+struct MoaSoundFormat {
+	int32 offset;
+	int32 size;
+	int32 playbackStart;
+	int32 playbackStartFrame;
+	int32 loopStart;
+	int32 loopStartFrame;
+	int32 loopEnd;
+	int32 loopEndFrame;
+	int32 playbackEnd;
+	int32 playbackEndFrame;
+	int32 numFrames;
+	int32 frameRate;
+	int32 byteRate;
+	byte compressionType[16];
+	int32 bitsPerSample;
+	int32 bytesPerSample;
+	int32 numChannels;
+	int32 bytesPerFrame;
+	byte soundHeaderType[16];
+	uint32 platformData[63];
+	int32 bytesPerBlock;
+};
+
+class MoaSoundFormatDecoder : public AudioDecoder {
+public:
+	MoaSoundFormatDecoder();
+	~MoaSoundFormatDecoder();
+
+	bool loadHeaderStream(Common::SeekableReadStreamEndian &stream);
+	bool loadSampleStream(Common::SeekableReadStreamEndian &stream);
+
+	MoaSoundFormat _format;
+	byte *_data = nullptr;
+	uint32 _size = 0;
+
+	Audio::AudioStream *getAudioStream(bool looping = false, bool forPuppet = false, DisposeAfterUse::Flag disposeAfterUse = DisposeAfterUse::YES) override;
+};
+
 } // End of namespace Director
 
 #endif


Commit: a6110de8a8bca975615e0c7a14f8ccde733d3701
    https://github.com/scummvm/scummvm/commit/a6110de8a8bca975615e0c7a14f8ccde733d3701
Author: Scott Percival (code at moral.net.au)
Date: 2025-09-12T11:39:37+02:00

Commit Message:
VIDEO: QTVR: Remove dependency on timer thread

Fixes concurrency issues and crashes in Gothos, related to accessing
OpenGL state outside of the main thread.

Changed paths:
    video/qt_decoder.h
    video/qtvr_decoder.cpp


diff --git a/video/qt_decoder.h b/video/qt_decoder.h
index f3b3e1d667e..75926d15912 100644
--- a/video/qt_decoder.h
+++ b/video/qt_decoder.h
@@ -237,7 +237,6 @@ private:
 	float _fov = 56.0f;
 	float _hfov = 56.0f;
 	int _zoomState = kZoomNone;
-	bool _repeatTimerActive = false;
 
 	const PanoHotSpot *_rolloverHotspot = nullptr;
 	int _rolloverHotspotID = 0;
@@ -251,6 +250,9 @@ private:
 
 	bool _enableEditListBoundsCheckQuirk;
 
+	bool _cursorDirty;
+	Common::Point _cursorPos;
+
 	class VideoSampleDesc : public Common::QuickTimeParser::SampleDesc {
 	public:
 		VideoSampleDesc(Common::QuickTimeParser::Track *parentTrack, uint32 codecTag);
@@ -426,7 +428,7 @@ private:
 
 		// Current upscale level (0 or 1 or 2) of _upscaledConstructedPanorama compared to _constructedPano
 		// level 0 means that constructedPano was just contructed and hasn't been upscaled yet
-		// level 1 means only upscaled height (2x pixels) 
+		// level 1 means only upscaled height (2x pixels)
 		// level 2 means upscaled height and width (4x pixels)
 		uint8 _upscaleLevel = 0;
 
diff --git a/video/qtvr_decoder.cpp b/video/qtvr_decoder.cpp
index cccc28c0227..cdb56376362 100644
--- a/video/qtvr_decoder.cpp
+++ b/video/qtvr_decoder.cpp
@@ -57,8 +57,6 @@ namespace Video {
 
 static const char * const MACGUI_DATA_BUNDLE = "macgui.dat";
 
-static void repeatCallback(void *data);
-
 ////////////////////////////////////////////
 // QuickTimeDecoder methods related to QTVR
 ////////////////////////////////////////////
@@ -141,11 +139,6 @@ void QuickTimeDecoder::closeQTVR() {
 	delete _dataBundle;
 	_dataBundle = nullptr;
 	cleanupCursors();
-
-	if (_repeatTimerActive) {
-		_repeatTimerActive = false;
-		g_system->getTimerManager()->removeTimerProc(&repeatCallback);
-	}
 }
 
 void QuickTimeDecoder::renderHotspots(bool mode) {
@@ -663,6 +656,13 @@ const Graphics::Surface *QuickTimeDecoder::PanoTrackHandler::decodeNextFrame() {
 	if (!_isPanoConstructed)
 		return nullptr;
 
+	// inject fake key/mouse events if button is held down
+	if (_decoder->_isKeyDown)
+		_decoder->handleKey(_decoder->_lastKey, true, true);
+
+	if (_decoder->_isMouseButtonDown)
+		_decoder->handleMouseButton(true, _decoder->_prevMouse.x, _decoder->_prevMouse.y, true);
+
 	if (_dirty && _decoder->_transitionMode == kTransitionModeNormal) {
 		float quality = _decoder->getQuality();
 		float fov = _decoder->_fov;
@@ -699,6 +699,11 @@ const Graphics::Surface *QuickTimeDecoder::PanoTrackHandler::decodeNextFrame() {
 		swingTransitionHandler();
 	}
 
+	if (_decoder->_cursorDirty) {
+		_decoder->_cursorDirty = false;
+		_decoder->updateQTVRCursor(_decoder->_cursorPos.x, _decoder->_cursorPos.y);
+	}
+
 	return _projectedPano;
 }
 
@@ -1510,10 +1515,6 @@ void QuickTimeDecoder::setClickedHotSpot(int id) {
 //////////////////////////////
 
 void QuickTimeDecoder::handleQuit() {
-	if (_repeatTimerActive) {
-		_repeatTimerActive = false;
-		g_system->getTimerManager()->removeTimerProc(&repeatCallback);
-	}
 }
 
 void QuickTimeDecoder::handleMouseMove(int16 x, int16 y) {
@@ -1522,7 +1523,8 @@ void QuickTimeDecoder::handleMouseMove(int16 x, int16 y) {
 	else if (_qtvrType == QTVRType::PANORAMA)
 		handlePanoMouseMove(x, y);
 
-	updateQTVRCursor(x, y);
+	_cursorDirty = true;
+	_cursorPos = Common::Point(x, y);
 }
 
 void QuickTimeDecoder::handleObjectMouseMove(int16 x, int16 y) {
@@ -1577,36 +1579,14 @@ void QuickTimeDecoder::handlePanoMouseMove(int16 x, int16 y) {
 	lookupHotspot(x, y);
 }
 
-#define REPEAT_DELAY 30000
-
-static void repeatCallback(void *data) {
-	QuickTimeDecoder *decoder = (QuickTimeDecoder *)data;
-
-	if (decoder->_isKeyDown)
-		decoder->handleKey(decoder->_lastKey, true, true);
-
-	if (decoder->_isMouseButtonDown)
-		decoder->handleMouseButton(true, decoder->_prevMouse.x, decoder->_prevMouse.y, true);
-}
-
 void QuickTimeDecoder::handleMouseButton(bool isDown, int16 x, int16 y, bool repeat) {
 	if (_qtvrType == QTVRType::OBJECT)
 		handleObjectMouseButton(isDown, x, y, repeat);
 	else if (_qtvrType == QTVRType::PANORAMA)
 		handlePanoMouseButton(isDown, x, y, repeat);
 
-	if (isDown) {
-		if (!_repeatTimerActive)
-			g_system->getTimerManager()->installTimerProc(&repeatCallback, REPEAT_DELAY, this, "Mouse Repeat Handler");
-		_repeatTimerActive = true;
-	} else {
-		if (_repeatTimerActive) {
-			_repeatTimerActive = false;
-			g_system->getTimerManager()->removeTimerProc(&repeatCallback);
-		}
-	}
-
-	updateQTVRCursor(x, y);
+	_cursorDirty = true;
+	_cursorPos = Common::Point(x, y);
 }
 
 void QuickTimeDecoder::handleObjectMouseButton(bool isDown, int16 x, int16 y, bool repeat) {
@@ -1699,18 +1679,12 @@ void QuickTimeDecoder::handleKey(Common::KeyState &state, bool down, bool repeat
 	if (down) {
 		_lastKey = state;
 		_isKeyDown = true;
-		if (!_repeatTimerActive)
-			g_system->getTimerManager()->installTimerProc(&repeatCallback, REPEAT_DELAY, this, "Keyboard Repeat Handler");
-		_repeatTimerActive = true;
 	} else {
 		_isKeyDown = false;
-		if (_repeatTimerActive) {
-			_repeatTimerActive = false;
-			g_system->getTimerManager()->removeTimerProc(&repeatCallback);
-		}
 	}
 
-	updateQTVRCursor(_prevMouse.x, _prevMouse.y);
+	_cursorDirty = true;
+	_cursorPos = Common::Point(_prevMouse.x, _prevMouse.y);
 }
 
 void QuickTimeDecoder::handleObjectKey(Common::KeyState &state, bool down, bool repeat) {




More information about the Scummvm-git-logs mailing list