8#include <imgui_internal.h>
20 ImGuiViewportP* viewport = (ImGuiViewportP*)(
void*)ImGui::GetMainViewport();
21 ImGuiWindowFlags window_flags = ImGuiWindowFlags_NoScrollbar | ImGuiWindowFlags_NoSavedSettings | ImGuiWindowFlags_MenuBar | ImGuiWindowFlags_NoDocking;
23 if (ImGui::BeginViewportSideBar(
"##MainStatusBar", viewport, ImGuiDir_Down, ImGui::GetFrameHeight(), window_flags))
25 if (ImGui::BeginMenuBar())
29 if (!frontMsg.
_text.empty()) {
31 ImGui::PushStyleColor(ImGuiCol_Text, IM_COL32(255, 50, 0, 255));
34 ImGui::Text(frontMsg.
_text.c_str());
37 ImGui::PopStyleColor();
48 if (_messages.empty()) {
52 Message& frontMsg = _messages.front();
62 _messages.push({message, durationMS, error});
#define PROFILE_SCOPE_AUTO(CATEGORY)
eastl::queue< Message > _messages
void update(U64 deltaTimeUS) noexcept
void showMessage(const string &message, F32 durationMS, bool error)
StatusBar(PlatformContext &context) noexcept
constexpr Optick::Category::Type GUI
constexpr T MicrosecondsToMilliseconds(U a) noexcept
Handle console commands that start with a forward slash.