mirror of
https://github.com/gnif/LookingGlass.git
synced 2025-08-06 10:44:01 +00:00
[client] imgui: update to cimgui 1.86
This commit is contained in:
@@ -228,7 +228,8 @@ void egl_desktopConfigUI(EGL_Desktop * desktop)
|
||||
for (int i = 0; i < EGL_SCALE_MAX; ++i)
|
||||
{
|
||||
bool selected = i == desktop->scaleAlgo;
|
||||
if (igSelectableBool(algorithmNames[i], selected, 0, (ImVec2) { 0.0f, 0.0f }))
|
||||
if (igSelectable_Bool(algorithmNames[i], selected, 0,
|
||||
(ImVec2) { 0.0f, 0.0f }))
|
||||
desktop->scaleAlgo = i;
|
||||
if (selected)
|
||||
igSetItemDefaultFocus();
|
||||
|
@@ -493,6 +493,7 @@ static void egl_onResize(LG_Renderer * renderer, const int width, const int heig
|
||||
|
||||
// this is needed to refresh the font atlas texture
|
||||
ImGui_ImplOpenGL3_Shutdown();
|
||||
ImGui_ImplOpenGL3_Init("#version 300 es");
|
||||
ImGui_ImplOpenGL3_NewFrame();
|
||||
|
||||
egl_damageResize(this->damage, this->translateX, this->translateY, this->scaleX, this->scaleY);
|
||||
|
@@ -268,7 +268,7 @@ static bool egl_filterDownscaleImguiConfig(EGL_Filter * filter)
|
||||
for (int i = 0; i < DOWNSCALE_COUNT; ++i)
|
||||
{
|
||||
bool selected = i == this->filter;
|
||||
if (igSelectableBool(filterNames[i], selected, 0, (ImVec2) { 0.0f, 0.0f }))
|
||||
if (igSelectable_Bool(filterNames[i], selected, 0, (ImVec2) { 0.0f, 0.0f }))
|
||||
{
|
||||
redraw = true;
|
||||
this->filter = i;
|
||||
|
@@ -334,7 +334,8 @@ static bool presetsUI(struct EGL_PostProcess * this)
|
||||
for (unsigned i = 0; i < stringlist_count(this->presets); ++i)
|
||||
{
|
||||
bool selected = i == this->activePreset;
|
||||
if (igSelectableBool(stringlist_at(this->presets, i), selected, 0, (ImVec2) { 0.0f, 0.0f }))
|
||||
if (igSelectable_Bool(stringlist_at(this->presets, i), selected, 0,
|
||||
(ImVec2) { 0.0f, 0.0f }))
|
||||
{
|
||||
this->activePreset = i;
|
||||
redraw = true;
|
||||
@@ -365,7 +366,7 @@ static bool presetsUI(struct EGL_PostProcess * this)
|
||||
if (igButton("Save preset as...", (ImVec2) { 0.0f, 0.0f }))
|
||||
{
|
||||
this->presetEdit[0] = '\0';
|
||||
igOpenPopup("Save preset as...", ImGuiPopupFlags_None);
|
||||
igOpenPopup_Str("Save preset as...", ImGuiPopupFlags_None);
|
||||
}
|
||||
|
||||
igSameLine(0.0f, -1.0f);
|
||||
@@ -401,7 +402,7 @@ static bool presetsUI(struct EGL_PostProcess * this)
|
||||
}
|
||||
|
||||
if (this->presetError)
|
||||
igOpenPopup("Preset error", ImGuiPopupFlags_None);
|
||||
igOpenPopup_Str("Preset error", ImGuiPopupFlags_None);
|
||||
|
||||
if (igBeginPopupModal("Preset error", NULL, ImGuiWindowFlags_AlwaysAutoResize))
|
||||
{
|
||||
@@ -425,7 +426,7 @@ static bool presetsUI(struct EGL_PostProcess * this)
|
||||
|
||||
static void drawDropTarget(void)
|
||||
{
|
||||
igPushStyleColorVec4(ImGuiCol_Separator, (ImVec4) { 1.0f, 1.0f, 0.0f, 1.0f });
|
||||
igPushStyleColor_Vec4(ImGuiCol_Separator, (ImVec4) { 1.0f, 1.0f, 0.0f, 1.0f });
|
||||
igSeparator();
|
||||
igPopStyleColor(1);
|
||||
}
|
||||
@@ -456,8 +457,8 @@ static void configUI(void * opaque, int * id)
|
||||
if (moving && mouseIdx < moveIdx && i == mouseIdx)
|
||||
drawDropTarget();
|
||||
|
||||
igPushIDPtr(filter);
|
||||
bool draw = igCollapsingHeaderBoolPtr(filter->ops.name, NULL, 0);
|
||||
igPushID_Ptr(filter);
|
||||
bool draw = igCollapsingHeader_BoolPtr(filter->ops.name, NULL, 0);
|
||||
if (igIsItemHovered(ImGuiHoveredFlags_AllowWhenBlockedByActiveItem))
|
||||
mouseIdx = i;
|
||||
|
||||
|
Reference in New Issue
Block a user