Skip to content

Commit 88c8cb9

Browse files
v-einhoffstadt
authored andcommitted
fix: Moved flags init in mvFontManager (found by PVS Studio).
1 parent 026ea3b commit 88c8cb9

2 files changed

Lines changed: 6 additions & 1 deletion

File tree

src/mvFontManager.cpp

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -39,6 +39,11 @@ if (ImGui::IsItemHovered())
3939
}
4040
}
4141

42+
mvFontManager::mvFontManager()
43+
{
44+
m_windowflags = ImGuiWindowFlags_NoSavedSettings | ImGuiWindowFlags_HorizontalScrollbar;
45+
}
46+
4247
// [Internal] Display details for a single font, called by ShowStyleEditor().
4348
void
4449
mvFontManager::drawFontNode(ImFont* font)

src/mvFontManager.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,7 @@ class mvFontManager : public mvToolWindow
1010
{
1111

1212
public:
13+
mvFontManager();
1314

1415
void updateAtlas();
1516
float& getGlobalFontScale() { return _globalFontScale; }
@@ -33,7 +34,6 @@ class mvFontManager : public mvToolWindow
3334
const char* getTitle() const override { return "Font Manager"; }
3435

3536
protected:
36-
ImGuiWindowFlags m_windowflags = ImGuiWindowFlags_NoSavedSettings | ImGuiWindowFlags_HorizontalScrollbar;
3737

3838
void drawWidgets() override;
3939
void drawFontNode(ImFont* font);

0 commit comments

Comments
 (0)