[Scummvm-git-logs] scummvm master -> 2265fd19bc45ac49429b8d86473cbc61f40204cc
sev-
noreply at scummvm.org
Fri Sep 5 22:56:06 UTC 2025
This automated email contains information about 6 new commits which have been
pushed to the 'scummvm' repo located at https://api.github.com/repos/scummvm/scummvm .
Summary:
ddc117e629 DIRECTOR: DT: Always properly highlight the current frame in Sore
10a5dcf828 DIRECTOR: DT: Boilerplate code for enabling/disabling channels
3debf3c1b2 DIRECTOR: Do not draw channels set to invisible
12e51c2813 DIRECTOR: DT: Implement channel toggle in Score window
c2da831729 DIRECTOR: DT: Implement channel toogle in the Channels window
2265fd19bc DIRECTOR: DT: Do not dock other dialogs to the Control Panel
Commit: ddc117e629ec881941f1a3bf06263b8e60b6acf8
https://github.com/scummvm/scummvm/commit/ddc117e629ec881941f1a3bf06263b8e60b6acf8
Author: Eugene Sandulenko (sev at scummvm.org)
Date: 2025-09-06T00:55:53+02:00
Commit Message:
DIRECTOR: DT: Always properly highlight the current frame in Sore
Changed paths:
engines/director/debugger/dt-score.cpp
diff --git a/engines/director/debugger/dt-score.cpp b/engines/director/debugger/dt-score.cpp
index 11c7cc04f58..76d420b889a 100644
--- a/engines/director/debugger/dt-score.cpp
+++ b/engines/director/debugger/dt-score.cpp
@@ -188,13 +188,6 @@ static void displayScoreChannel(int ch, int mode, int modeSel) {
int startCont = _state->_continuationData[ch][rf].first;
int endCont = _state->_continuationData[ch][rf].second;
- if (rf + 1 == (int)currentFrameNum)
- ImGui::TableSetBgColor(ImGuiTableBgTarget_CellBg, cell_bg_color);
-
- if (f == _state->_selectedScoreCast.frame + _state->_scoreFrameOffset - 1 &&
- ch == _state->_selectedScoreCast.channel && mode <= kModeExtended)
- ImGui::TableSetBgColor(ImGuiTableBgTarget_CellBg, ImGui::GetColorU32(ImVec4(1.0f, 0.3f, 0.3f, 0.6f)));
-
if (!(startCont == endCont) && (sprite._castId.member || sprite.isQDShape())) {
if (_state->_selectedScoreCast.frame + _state->_scoreFrameOffset - 1 >= startCont &&
_state->_selectedScoreCast.frame + _state->_scoreFrameOffset - 1 <= endCont &&
@@ -213,6 +206,13 @@ static void displayScoreChannel(int ch, int mode, int modeSel) {
}
}
+ if (rf + 1 == (int)currentFrameNum)
+ ImGui::TableSetBgColor(ImGuiTableBgTarget_CellBg, cell_bg_color);
+
+ if (f == _state->_selectedScoreCast.frame + _state->_scoreFrameOffset - 1 &&
+ ch == _state->_selectedScoreCast.channel && mode <= kModeExtended)
+ ImGui::TableSetBgColor(ImGuiTableBgTarget_CellBg, ImGui::GetColorU32(ImVec4(1.0f, 0.3f, 0.3f, 0.6f)));
+
int mode1 = mode;
ImGui::PushID((ch + 10 - mode) * 10000 + f);
Commit: 10a5dcf828af2e57de664a39f7b6ebb1eb1ff393
https://github.com/scummvm/scummvm/commit/10a5dcf828af2e57de664a39f7b6ebb1eb1ff393
Author: Eugene Sandulenko (sev at scummvm.org)
Date: 2025-09-06T00:55:53+02:00
Commit Message:
DIRECTOR: DT: Boilerplate code for enabling/disabling channels
Changed paths:
engines/director/debugger/dt-score.cpp
diff --git a/engines/director/debugger/dt-score.cpp b/engines/director/debugger/dt-score.cpp
index 76d420b889a..828eff7610b 100644
--- a/engines/director/debugger/dt-score.cpp
+++ b/engines/director/debugger/dt-score.cpp
@@ -137,7 +137,24 @@ static void displayScoreChannel(int ch, int mode, int modeSel) {
if (modeSel == kModeExtended && mode == kModeExtended)
ImGui::TableSetBgColor(ImGuiTableBgTarget_RowBg0, ImGui::GetColorU32(ImGuiCol_TableRowBgAlt));
- {
+ { // Playback toggle
+ ImGui::TableNextColumn();
+
+ ImGui::PushID(ch + 20000 - mode);
+ ImDrawList *dl = ImGui::GetWindowDrawList();
+ const ImVec2 pos = ImGui::GetCursorScreenPos();
+ const ImVec2 mid(pos.x + 7, pos.y + 7);
+
+ ImGui::InvisibleButton("Line", ImVec2(16, ImGui::GetFontSize()));
+ ImGui::SetItemTooltip("Playback toggle");
+
+ dl->AddCircleFilled(mid, 4.0f, ImColor(_state->_colors._bp_color_enabled));
+// dl->AddCircle(mid, 4.0f, ImColor(_state->_colors._bp_color_enabled));
+
+ ImGui::PopID();
+ }
+
+ { // Channel name / number
ImGui::TableNextColumn();
float indentSize = 17.0f;
@@ -547,16 +564,18 @@ void showScore() {
ImGui::BeginChild("Score table", ImVec2(0, -20));
- if (ImGui::BeginTable("Score", tableColumns + 1,
+ if (ImGui::BeginTable("Score", tableColumns + 2,
ImGuiTableFlags_Borders | ImGuiTableFlags_ScrollX | ImGuiTableFlags_ScrollY |
ImGuiTableFlags_SizingStretchProp | addonFlags)) {
ImGuiTableFlags flags = ImGuiTableColumnFlags_WidthFixed;
- ImGui::TableSetupScrollFreeze(1, 2);
+ ImGui::TableSetupScrollFreeze(2, 2);
ImGui::PushFont(_state->_tinyFont);
- ImGui::TableSetupColumn("##", flags);
+ ImGui::TableSetupColumn("##disable", flags); // disable button
+
+ ImGui::TableSetupColumn("##", flags); // Number
for (uint i = 0; i < tableColumns; i++) {
Common::String label = Common::String::format("%-2d", i + _state->_scoreFrameOffset);
label += Common::String::format("##l%d", i);
@@ -568,6 +587,9 @@ void showScore() {
ImGui::TableNextRow(0);
ImGui::TableSetColumnIndex(0);
+ ImGui::SetNextItemWidth(20);
+
+ ImGui::TableSetColumnIndex(1);
ImGui::PushID(0);
ImGui::SetNextItemWidth(50);
@@ -590,8 +612,8 @@ void showScore() {
ImGui::PopID();
for (uint i = 0; i < tableColumns; i++) {
- ImGui::TableSetColumnIndex(i + 1);
- const char *column_name = ImGui::TableGetColumnName(i + 1);
+ ImGui::TableSetColumnIndex(i + 2);
+ const char *column_name = ImGui::TableGetColumnName(i + 2);
ImGui::SetNextItemWidth(20);
ImGui::TableHeader(column_name);
@@ -599,7 +621,9 @@ void showScore() {
ImGui::TableNextRow();
- ImGui::TableNextColumn();
+ ImGui::TableNextColumn(); // Enable/Disable switch
+
+ ImGui::TableNextColumn(); // Label column
float indentSize = 10.0;
ImGui::Indent(indentSize);
Commit: 3debf3c1b23c387fec8af3d88feaa3af75920070
https://github.com/scummvm/scummvm/commit/3debf3c1b23c387fec8af3d88feaa3af75920070
Author: Eugene Sandulenko (sev at scummvm.org)
Date: 2025-09-06T00:55:53+02:00
Commit Message:
DIRECTOR: Do not draw channels set to invisible
Changed paths:
engines/director/score.cpp
diff --git a/engines/director/score.cpp b/engines/director/score.cpp
index bbe400befd8..d6bf0e0f996 100644
--- a/engines/director/score.cpp
+++ b/engines/director/score.cpp
@@ -849,6 +849,9 @@ void Score::updateSprites(RenderMode mode, bool withClean) {
Sprite *currentSprite = channel->_sprite;
Sprite *nextSprite = _currentFrame->_sprites[i];
+ if (!channel->_visible)
+ continue;
+
// widget content has changed and needs a redraw.
// this doesn't include changes in dimension or position!
bool widgetRedrawn = channel->updateWidget();
Commit: 12e51c281322fbf1b06c5d80efd4d086435bc850
https://github.com/scummvm/scummvm/commit/12e51c281322fbf1b06c5d80efd4d086435bc850
Author: Eugene Sandulenko (sev at scummvm.org)
Date: 2025-09-06T00:55:53+02:00
Commit Message:
DIRECTOR: DT: Implement channel toggle in Score window
Changed paths:
engines/director/debugger/debugtools.cpp
engines/director/debugger/dt-internal.h
engines/director/debugger/dt-score.cpp
diff --git a/engines/director/debugger/debugtools.cpp b/engines/director/debugger/debugtools.cpp
index 23b66f720af..af2d7595912 100644
--- a/engines/director/debugger/debugtools.cpp
+++ b/engines/director/debugger/debugtools.cpp
@@ -421,6 +421,8 @@ static void showSettings() {
ImGui::ColorEdit4("Breakpoint enabled", &_state->_colors._bp_color_enabled.x);
ImGui::ColorEdit4("Breakpoint hover", &_state->_colors._bp_color_hover.x);
+ ImGui::ColorEdit4("Channel toggle", &_state->_colors._channel_toggle.x);
+
ImGui::SeparatorText("Lingo syntax");
ImGui::ColorEdit4("Line", &_state->_colors._line_color.x);
ImGui::ColorEdit4("Call", &_state->_colors._call_color.x);
diff --git a/engines/director/debugger/dt-internal.h b/engines/director/debugger/dt-internal.h
index d59f8b2fd8d..1533263ddff 100644
--- a/engines/director/debugger/dt-internal.h
+++ b/engines/director/debugger/dt-internal.h
@@ -137,6 +137,8 @@ typedef struct ImGuiState {
ImVec4 _bp_color_enabled = ImVec4(0.9f, 0.08f, 0.0f, 1.0f);
ImVec4 _bp_color_hover = ImVec4(0.42f, 0.17f, 0.13f, 1.0f);
+ ImVec4 _channel_toggle = ImColor(IM_COL32(0x30, 0x30, 0xFF, 0xFF));
+
ImVec4 _current_statement = ImColor(IM_COL32(0xFF, 0xFF, 0x00, 0xFF));
ImVec4 _line_color = ImVec4(0.44f, 0.44f, 0.44f, 1.0f);
ImVec4 _call_color = ImColor(IM_COL32(0xFF, 0xC5, 0x5C, 0xFF));
diff --git a/engines/director/debugger/dt-score.cpp b/engines/director/debugger/dt-score.cpp
index 828eff7610b..c481f45734a 100644
--- a/engines/director/debugger/dt-score.cpp
+++ b/engines/director/debugger/dt-score.cpp
@@ -148,8 +148,18 @@ static void displayScoreChannel(int ch, int mode, int modeSel) {
ImGui::InvisibleButton("Line", ImVec2(16, ImGui::GetFontSize()));
ImGui::SetItemTooltip("Playback toggle");
- dl->AddCircleFilled(mid, 4.0f, ImColor(_state->_colors._bp_color_enabled));
-// dl->AddCircle(mid, 4.0f, ImColor(_state->_colors._bp_color_enabled));
+ if (ImGui::IsItemClicked(0)) {
+ if (mode == kModeMember) {
+ score->_channels[ch]->_visible = !score->_channels[ch]->_visible;
+
+ g_director->getCurrentWindow()->render(true);
+ }
+ }
+
+ if (mode != kModeMember || score->_channels[ch]->_visible)
+ dl->AddCircleFilled(mid, 4.0f, ImColor(_state->_colors._channel_toggle));
+ else
+ dl->AddCircle(mid, 4.0f, ImColor(_state->_colors._channel_toggle));
ImGui::PopID();
}
Commit: c2da831729b869d524fc2949804b8ca54c2d05b9
https://github.com/scummvm/scummvm/commit/c2da831729b869d524fc2949804b8ca54c2d05b9
Author: Eugene Sandulenko (sev at scummvm.org)
Date: 2025-09-06T00:55:53+02:00
Commit Message:
DIRECTOR: DT: Implement channel toogle in the Channels window
Changed paths:
engines/director/debugger/dt-score.cpp
diff --git a/engines/director/debugger/dt-score.cpp b/engines/director/debugger/dt-score.cpp
index c481f45734a..a643d26beb5 100644
--- a/engines/director/debugger/dt-score.cpp
+++ b/engines/director/debugger/dt-score.cpp
@@ -746,8 +746,9 @@ void showChannels() {
ImGui::Text("SND: 2 sound2: %d, soundType2: %d", frame._mainChannels.sound2.member, frame._mainChannels.soundType2);
ImGui::Text("LSCR: actionId: %s", frame._mainChannels.actionId.asString().c_str());
- if (ImGui::BeginTable("Channels", 21, ImGuiTableFlags_Borders)) {
+ if (ImGui::BeginTable("Channels", 22, ImGuiTableFlags_Borders)) {
ImGuiTableFlags flags = ImGuiTableColumnFlags_WidthFixed | ImGuiTableColumnFlags_AngledHeader;
+ ImGui::TableSetupColumn("##toggle", flags);
ImGui::TableSetupColumn("CH", flags);
ImGui::TableSetupColumn("castId", flags);
ImGui::TableSetupColumn("vis", flags);
@@ -777,6 +778,31 @@ void showChannels() {
ImGui::TableNextRow();
+ { // Playback toggle
+ ImGui::TableNextColumn();
+
+ ImGui::PushID(i + 20000);
+ ImDrawList *dl = ImGui::GetWindowDrawList();
+ const ImVec2 pos1 = ImGui::GetCursorScreenPos();
+ const ImVec2 mid(pos1.x + 7, pos1.y + 7);
+
+ ImGui::InvisibleButton("Line", ImVec2(16, ImGui::GetFontSize()));
+ ImGui::SetItemTooltip("Playback toggle");
+
+ if (ImGui::IsItemClicked(0)) {
+ score->_channels[i]->_visible = !score->_channels[i]->_visible;
+
+ g_director->getCurrentWindow()->render(true);
+ }
+
+ if (score->_channels[i]->_visible)
+ dl->AddCircleFilled(mid, 4.0f, ImColor(_state->_colors._channel_toggle));
+ else
+ dl->AddCircle(mid, 4.0f, ImColor(_state->_colors._channel_toggle));
+
+ ImGui::PopID();
+ }
+
ImGui::TableNextColumn();
bool isSelected = (_state->_selectedChannel == i + 1);
Commit: 2265fd19bc45ac49429b8d86473cbc61f40204cc
https://github.com/scummvm/scummvm/commit/2265fd19bc45ac49429b8d86473cbc61f40204cc
Author: Eugene Sandulenko (sev at scummvm.org)
Date: 2025-09-06T00:55:53+02:00
Commit Message:
DIRECTOR: DT: Do not dock other dialogs to the Control Panel
Changed paths:
engines/director/debugger/dt-controlpanel.cpp
diff --git a/engines/director/debugger/dt-controlpanel.cpp b/engines/director/debugger/dt-controlpanel.cpp
index 9e28ebf5ffe..0f62f8c48fc 100644
--- a/engines/director/debugger/dt-controlpanel.cpp
+++ b/engines/director/debugger/dt-controlpanel.cpp
@@ -127,7 +127,7 @@ void showControlPanel() {
ImGui::SetNextWindowPos(ImVec2(vp.x - 220.0f, 20.0f), ImGuiCond_FirstUseEver);
ImGui::SetNextWindowSize(ImVec2(200, 103), ImGuiCond_FirstUseEver);
- if (ImGui::Begin("Control Panel", &_state->_w.controlPanel)) {
+ if (ImGui::Begin("Control Panel", &_state->_w.controlPanel, ImGuiWindowFlags_NoDocking)) {
Movie *movie = g_director->getCurrentMovie();
Score *score = movie->getScore();
ImDrawList *dl = ImGui::GetWindowDrawList();
More information about the Scummvm-git-logs
mailing list