feat: add runtime play tick and play-mode scene editing semantics
This commit is contained in:
@@ -511,27 +511,27 @@ bool DrawCompactCheckedMenuItem(const char* label, bool checked) {
|
||||
return false;
|
||||
}
|
||||
|
||||
const bool clicked = ImGui::Selectable(label, false, ImGuiSelectableFlags_SpanAvailWidth);
|
||||
const bool clicked = ImGui::MenuItem(label, nullptr, false, true);
|
||||
const ImRect rect(ImGui::GetItemRectMin(), ImGui::GetItemRectMax());
|
||||
if (checked) {
|
||||
const ImRect rect(ImGui::GetItemRectMin(), ImGui::GetItemRectMax());
|
||||
ImDrawList* drawList = ImGui::GetWindowDrawList();
|
||||
const ImU32 color = ImGui::GetColorU32(ImGuiCol_CheckMark);
|
||||
const float height = rect.Max.y - rect.Min.y;
|
||||
const float checkWidth = height * 0.28f;
|
||||
const float checkHeight = height * 0.18f;
|
||||
const float x = rect.Max.x - 12.0f;
|
||||
const float checkWidth = height * 0.24f;
|
||||
const float checkHeight = height * 0.16f;
|
||||
const float x = rect.Max.x - 10.0f;
|
||||
const float y = rect.Min.y + height * 0.52f;
|
||||
|
||||
drawList->AddLine(
|
||||
ImVec2(x - checkWidth, y - checkHeight * 0.15f),
|
||||
ImVec2(x - checkWidth * 0.42f, y + checkHeight),
|
||||
color,
|
||||
1.4f);
|
||||
1.8f);
|
||||
drawList->AddLine(
|
||||
ImVec2(x - checkWidth * 0.42f, y + checkHeight),
|
||||
ImVec2(x + checkWidth, y - checkHeight),
|
||||
color,
|
||||
1.4f);
|
||||
1.8f);
|
||||
}
|
||||
|
||||
return clicked;
|
||||
@@ -973,7 +973,7 @@ void ConsolePanel::Render() {
|
||||
}
|
||||
|
||||
if (shouldPause) {
|
||||
m_context->GetEventBus().Publish(PlayModePausedEvent{});
|
||||
m_context->GetEventBus().Publish(PlayModePauseRequestedEvent{});
|
||||
m_playModePaused = true;
|
||||
}
|
||||
m_lastErrorPauseScanSerial = latestSerial;
|
||||
|
||||
Reference in New Issue
Block a user