summaryrefslogtreecommitdiffstatshomepage
path: root/3rdparty/bgfx/examples/common/example-glue.cpp
diff options
context:
space:
mode:
Diffstat (limited to '3rdparty/bgfx/examples/common/example-glue.cpp')
-rw-r--r--3rdparty/bgfx/examples/common/example-glue.cpp20
1 files changed, 10 insertions, 10 deletions
diff --git a/3rdparty/bgfx/examples/common/example-glue.cpp b/3rdparty/bgfx/examples/common/example-glue.cpp
index ad4507c4f81..c4b309c3607 100644
--- a/3rdparty/bgfx/examples/common/example-glue.cpp
+++ b/3rdparty/bgfx/examples/common/example-glue.cpp
@@ -1,5 +1,5 @@
/*
- * Copyright 2011-2019 Branimir Karadzic. All rights reserved.
+ * Copyright 2011-2021 Branimir Karadzic. All rights reserved.
* License: https://github.com/bkaradzic/bgfx#license-bsd-2-clause
*/
@@ -150,9 +150,7 @@ void showExampleDialog(entry::AppI* _app, const char* _errorText)
}
else if (ImGui::IsItemHovered() )
{
- char tmp[1024];
- bx::snprintf(tmp, BX_COUNTOF(tmp), "Documentation: %.*s", url.getLength(), url.getPtr() );
- ImGui::SetTooltip(tmp);
+ ImGui::SetTooltip("Documentation: %.*s", url.getLength(), url.getPtr() );
}
}
@@ -393,9 +391,10 @@ void showExampleDialog(entry::AppI* _app, const char* _errorText)
const double toGpuMs = 1000.0/double(stats->gpuTimerFreq);
const float scale = 3.0f;
- if (ImGui::ListBoxHeader("Encoders", ImVec2(ImGui::GetWindowWidth(), stats->numEncoders*itemHeightWithSpacing) ) )
+ if (ImGui::BeginListBox("Encoders", ImVec2(ImGui::GetWindowWidth(), stats->numEncoders*itemHeightWithSpacing) ) )
{
- ImGuiListClipper clipper(stats->numEncoders, itemHeight);
+ ImGuiListClipper clipper;
+ clipper.Begin(stats->numEncoders, itemHeight);
while (clipper.Step() )
{
@@ -420,14 +419,15 @@ void showExampleDialog(entry::AppI* _app, const char* _errorText)
}
}
- ImGui::ListBoxFooter();
+ ImGui::EndListBox();
}
ImGui::Separator();
- if (ImGui::ListBoxHeader("Views", ImVec2(ImGui::GetWindowWidth(), stats->numViews*itemHeightWithSpacing) ) )
+ if (ImGui::BeginListBox("Views", ImVec2(ImGui::GetWindowWidth(), stats->numViews*itemHeightWithSpacing) ) )
{
- ImGuiListClipper clipper(stats->numViews, itemHeight);
+ ImGuiListClipper clipper;
+ clipper.Begin(stats->numViews, itemHeight);
while (clipper.Step() )
{
@@ -466,7 +466,7 @@ void showExampleDialog(entry::AppI* _app, const char* _errorText)
}
}
- ImGui::ListBoxFooter();
+ ImGui::EndListBox();
}
ImGui::PopFont();