Remove deletes for images from scroll list GUI Elements
Resources are deleted by ~PageSet and do not need to be deleted by the the scrollable list elements. This fixes a crash when reloading the theme. Also remove some deletes for items that should not be deleted in button and input GUI elements. Change-Id: Ie1c1b85c81c10f648d085746a5fdba6220468a5f
This commit is contained in:
@@ -130,7 +130,6 @@ GUIButton::~GUIButton()
|
||||
if (mButtonImg) delete mButtonImg;
|
||||
if (mButtonLabel) delete mButtonLabel;
|
||||
if (mAction) delete mAction;
|
||||
if (mButtonIcon) delete mButtonIcon;
|
||||
}
|
||||
|
||||
int GUIButton::Render(void)
|
||||
|
||||
@@ -141,8 +141,6 @@ GUIFileSelector::GUIFileSelector(xml_node<>* node) : GUIScrollList(node)
|
||||
|
||||
GUIFileSelector::~GUIFileSelector()
|
||||
{
|
||||
delete mFileIcon;
|
||||
delete mFolderIcon;
|
||||
}
|
||||
|
||||
int GUIFileSelector::Update(void)
|
||||
|
||||
@@ -214,8 +214,6 @@ GUIInput::GUIInput(xml_node<>* node)
|
||||
GUIInput::~GUIInput()
|
||||
{
|
||||
if (mInputText) delete mInputText;
|
||||
if (mBackground) delete mBackground;
|
||||
if (mCursor) delete mCursor;
|
||||
if (mAction) delete mAction;
|
||||
}
|
||||
|
||||
|
||||
@@ -103,8 +103,6 @@ GUIListBox::GUIListBox(xml_node<>* node) : GUIScrollList(node)
|
||||
|
||||
GUIListBox::~GUIListBox()
|
||||
{
|
||||
delete mIconSelected;
|
||||
delete mIconUnselected;
|
||||
}
|
||||
|
||||
int GUIListBox::Update(void)
|
||||
|
||||
@@ -96,8 +96,6 @@ GUIPartitionList::GUIPartitionList(xml_node<>* node) : GUIScrollList(node)
|
||||
|
||||
GUIPartitionList::~GUIPartitionList()
|
||||
{
|
||||
delete mIconSelected;
|
||||
delete mIconUnselected;
|
||||
}
|
||||
|
||||
int GUIPartitionList::Update(void)
|
||||
|
||||
@@ -259,9 +259,6 @@ GUIScrollList::GUIScrollList(xml_node<>* node) : GUIObject(node)
|
||||
|
||||
GUIScrollList::~GUIScrollList()
|
||||
{
|
||||
delete mHeaderIcon;
|
||||
delete mBackground;
|
||||
delete mFont;
|
||||
}
|
||||
|
||||
void GUIScrollList::SetMaxIconSize(int w, int h)
|
||||
|
||||
Reference in New Issue
Block a user