We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 404ae17 commit 416224fCopy full SHA for 416224f
src/mvThemes.cpp
@@ -98,17 +98,18 @@ void mvTheme::pop_theme_components()
98
}
99
else
100
{
101
+ // Below, we move from comp->_oldComponent to avoid mvThemeComponent
102
+ // hanging around even after being deleted from the widget tree.
103
if (_specificEnabled == comp->_specificEnabled)
104
- // Nullifying comp->_oldComponent to avoid mvThemeComponent
- // hanging around even after being deleted from the widget tree.
105
*comp->_specificComponentPtr = std::move(comp->_oldComponent);
106
107
108
109
*comp->_specificDisabledComponentPtr = std::move(comp->_oldComponent);
110
111
-
+ // Just in case anyone wants to reuse it
112
+ comp->_oldComponent = nullptr;
113
114
115
0 commit comments