summaryrefslogtreecommitdiff
path: root/src/gui/widgets/dropshortcutcontainer.cpp
diff options
context:
space:
mode:
authorAndrei Karas <akaras@inbox.ru>2012-07-23 00:10:43 +0300
committerAndrei Karas <akaras@inbox.ru>2012-07-23 00:10:43 +0300
commitd97189f055798b5b2051c1c5770a3def62747461 (patch)
treed66a891dba33d2ce1c882e0de7d6145bb2e0326b /src/gui/widgets/dropshortcutcontainer.cpp
parent25dce1399e40f24809842303d48ef090439de1e5 (diff)
downloadManaVerse-d97189f055798b5b2051c1c5770a3def62747461.tar.gz
ManaVerse-d97189f055798b5b2051c1c5770a3def62747461.tar.bz2
ManaVerse-d97189f055798b5b2051c1c5770a3def62747461.tar.xz
ManaVerse-d97189f055798b5b2051c1c5770a3def62747461.zip
Improve perfomance in some object constructors.
Diffstat (limited to 'src/gui/widgets/dropshortcutcontainer.cpp')
-rw-r--r--src/gui/widgets/dropshortcutcontainer.cpp9
1 files changed, 4 insertions, 5 deletions
diff --git a/src/gui/widgets/dropshortcutcontainer.cpp b/src/gui/widgets/dropshortcutcontainer.cpp
index fca1af17f..d70f153d7 100644
--- a/src/gui/widgets/dropshortcutcontainer.cpp
+++ b/src/gui/widgets/dropshortcutcontainer.cpp
@@ -48,13 +48,14 @@
DropShortcutContainer::DropShortcutContainer():
ShortcutContainer(),
mItemClicked(false),
- mItemMoved(nullptr)
+ mItemMoved(nullptr),
+ mItemPopup(new ItemPopup),
+ mEquipedColor(Theme::getThemeColor(Theme::ITEM_EQUIPPED)),
+ mUnEquipedColor(Theme::getThemeColor(Theme::ITEM_NOT_EQUIPPED))
{
addMouseListener(this);
addWidgetListener(this);
- mItemPopup = new ItemPopup;
-
mBackgroundImg = Theme::getImageFromThemeXml(
"item_shortcut_background.xml");
if (dropShortcut)
@@ -73,8 +74,6 @@ DropShortcutContainer::DropShortcutContainer():
mBoxHeight = 1;
mBoxWidth = 1;
}
- mEquipedColor = Theme::getThemeColor(Theme::ITEM_EQUIPPED);
- mUnEquipedColor = Theme::getThemeColor(Theme::ITEM_NOT_EQUIPPED);
}
DropShortcutContainer::~DropShortcutContainer()