[Scummvm-git-logs] scummvm master -> 3739ed3423f27f2aa1b2800e173d340951e3bfc9
sev-
noreply at scummvm.org
Fri Sep 26 22:15:29 UTC 2025
This automated email contains information about 3 new commits which have been
pushed to the 'scummvm' repo located at https://api.github.com/repos/scummvm/scummvm .
Summary:
856f935006 DIRECTOR: Clarified 'on stepFrame' handler invocation
187b93aca1 DIRECTOR: LINGO: Beginning of window events addition
3739ed3423 DIRECTOR: Implement 'on rightMouseUp/Down' handlers properly
Commit: 856f9350068606bbfdbf20b9057076dc46aa57a3
https://github.com/scummvm/scummvm/commit/856f9350068606bbfdbf20b9057076dc46aa57a3
Author: Eugene Sandulenko (sev at scummvm.org)
Date: 2025-09-27T00:15:20+02:00
Commit Message:
DIRECTOR: Clarified 'on stepFrame' handler invocation
Changed paths:
engines/director/score.cpp
diff --git a/engines/director/score.cpp b/engines/director/score.cpp
index 47e4509425e..0ef3529e30e 100644
--- a/engines/director/score.cpp
+++ b/engines/director/score.cpp
@@ -687,6 +687,8 @@ void Score::update() {
// Call the perFrameHook as soon as a frame switch is done.
// If there is a transition, the perFrameHook is called
// after each transition subframe instead of here.
+ //
+ // This also sends stepFrame message to actorList
if (_currentFrame->_mainChannels.transType == 0 && _currentFrame->_mainChannels.trans.isNull()) {
_lingo->executePerFrameHook(_curFrameNumber, 0);
}
Commit: 187b93aca1197e63dfa516c09c81b21c47525c06
https://github.com/scummvm/scummvm/commit/187b93aca1197e63dfa516c09c81b21c47525c06
Author: Eugene Sandulenko (sev at scummvm.org)
Date: 2025-09-27T00:15:20+02:00
Commit Message:
DIRECTOR: LINGO: Beginning of window events addition
Changed paths:
engines/director/lingo/lingo-events.cpp
diff --git a/engines/director/lingo/lingo-events.cpp b/engines/director/lingo/lingo-events.cpp
index fc61a55629d..7a91d4c8bba 100644
--- a/engines/director/lingo/lingo-events.cpp
+++ b/engines/director/lingo/lingo-events.cpp
@@ -569,7 +569,16 @@ void Movie::queueEvent(Common::Queue<LingoEvent> &queue, LEvent event, int targe
case kEventStartMovie:
case kEventStepMovie:
case kEventStopMovie:
- case kEventPrepareMovie: // D6+
+
+ case kEventPrepareMovie: // D6
+
+ case kEventActivateWindow: // D5
+ case kEventDeactivateWindow: // D5
+ case kEventMoveWindow: // D5
+ case kEventResizeWindow: // D5
+ case kEventOpenWindow: // D5
+ case kEventCloseWindow: // D5
+ case kEventZoomWindow: // D5
queue.push(LingoEvent(event, eventId, kMovieHandler, false, pos, channelId));
break;
Commit: 3739ed3423f27f2aa1b2800e173d340951e3bfc9
https://github.com/scummvm/scummvm/commit/3739ed3423f27f2aa1b2800e173d340951e3bfc9
Author: Eugene Sandulenko (sev at scummvm.org)
Date: 2025-09-27T00:15:20+02:00
Commit Message:
DIRECTOR: Implement 'on rightMouseUp/Down' handlers properly
Now they are generated also on Macintosh, taking into account
the emulateMultiButtonMouse system property
Changed paths:
engines/director/director.cpp
engines/director/director.h
engines/director/events.cpp
engines/director/lingo/lingo-the.cpp
diff --git a/engines/director/director.cpp b/engines/director/director.cpp
index 0d4e2796c5d..42432aca776 100644
--- a/engines/director/director.cpp
+++ b/engines/director/director.cpp
@@ -162,6 +162,8 @@ DirectorEngine::DirectorEngine(OSystem *syst, const DirectorGameDescription *gam
_surface = nullptr;
_tickBaseline = 0;
+
+ _emulateMultiButtonMouse = false;
}
DirectorEngine::~DirectorEngine() {
diff --git a/engines/director/director.h b/engines/director/director.h
index 26a6ac5ee04..b3091d5ba97 100644
--- a/engines/director/director.h
+++ b/engines/director/director.h
@@ -273,6 +273,7 @@ public:
Archive *_mainArchive;
Common::Rect _fixStageRect;
Common::List<Common::String> _extraSearchPath;
+ bool _emulateMultiButtonMouse;
// Owner of all Archive objects.
Common::HashMap<Common::Path, Archive *, Common::Path::IgnoreCaseAndMac_Hash, Common::Path::IgnoreCaseAndMac_EqualTo> _allSeenResFiles;
diff --git a/engines/director/events.cpp b/engines/director/events.cpp
index 0a569733053..9bd521c8960 100644
--- a/engines/director/events.cpp
+++ b/engines/director/events.cpp
@@ -212,6 +212,16 @@ bool Movie::processEvent(Common::Event &event) {
if ((g_director->getVersion() >= 500) && event.type == Common::EVENT_RBUTTONDOWN)
ev = kEventRightMouseDown;
+ if (g_director->getVersion() >= 500 && event.type == Common::EVENT_LBUTTONDOWN && _vm->_emulateMultiButtonMouse) {
+ if (g_director->getPlatform() == Common::kPlatformMacintosh) {
+ // On Mac, when the mouse button and Control key are pressed
+ // at the same time, this simulates right button click
+ if (_keyFlags & Common::KBD_CTRL) {
+ ev = kEventRightMouseDown;
+ }
+ }
+ }
+
debugC(3, kDebugEvents, "Movie::processEvent(): Button Down @(%d, %d), movie '%s'", pos.x, pos.y, _macName.c_str());
queueInputEvent(ev, 0, pos);
}
@@ -231,6 +241,16 @@ bool Movie::processEvent(Common::Event &event) {
if ((g_director->getVersion() >= 500) && event.type == Common::EVENT_RBUTTONUP)
ev = kEventRightMouseUp;
+ if (g_director->getVersion() >= 500 && event.type == Common::EVENT_LBUTTONUP && _vm->_emulateMultiButtonMouse) {
+ if (g_director->getPlatform() == Common::kPlatformMacintosh) {
+ // On Mac, when the mouse button and Control key are pressed
+ // at the same time, this simulates right button click
+ if (_keyFlags & Common::KBD_CTRL) {
+ ev = kEventRightMouseUp;
+ }
+ }
+ }
+
queueInputEvent(ev, 0, pos);
sc->renderCursor(pos);
}
diff --git a/engines/director/lingo/lingo-the.cpp b/engines/director/lingo/lingo-the.cpp
index 667ab89472c..401cc09dcfb 100644
--- a/engines/director/lingo/lingo-the.cpp
+++ b/engines/director/lingo/lingo-the.cpp
@@ -566,6 +566,9 @@ Datum Lingo::getTheEntity(int entity, Datum &id, int field) {
// 25 ticks seems to be the threshold for a double click.
d = (movie->_lastClickTime - movie->_lastClickTime2) <= 25 ? 1 : 0;
break;
+ case kTheEmulateMultiButtonMouse:
+ d = g_director->_emulateMultiButtonMouse ? 1 : 0;
+ break;
case kTheExitLock:
d = g_lingo->_exitLock;
break;
@@ -1157,6 +1160,9 @@ void Lingo::setTheEntity(int entity, Datum &id, int field, Datum &d) {
case kTheExitLock:
g_lingo->_exitLock = bool(d.asInt());
break;
+ case kTheEmulateMultiButtonMouse:
+ g_director->_emulateMultiButtonMouse = (bool)d.asInt();
+ break;
case kTheFixStageSize:
g_director->_fixStageSize = (bool)d.u.i;
if (d.u.i) {
More information about the Scummvm-git-logs
mailing list