summaryrefslogtreecommitdiff
path: root/src/gui/popupmanager.cpp
diff options
context:
space:
mode:
authorAndrei Karas <akaras@inbox.ru>2014-08-17 13:47:55 +0300
committerAndrei Karas <akaras@inbox.ru>2014-08-17 13:47:55 +0300
commitd0d0ddfeb0bd6cb199e3ac571c876d6bbaaf4b42 (patch)
tree578d99ea41b1eeea6068500fe0bea485bbcbccb5 /src/gui/popupmanager.cpp
parent2cb9f5c3d47077a459fabf15800b1c45cfdacb3a (diff)
downloadManaVerse-d0d0ddfeb0bd6cb199e3ac571c876d6bbaaf4b42.tar.gz
ManaVerse-d0d0ddfeb0bd6cb199e3ac571c876d6bbaaf4b42.tar.bz2
ManaVerse-d0d0ddfeb0bd6cb199e3ac571c876d6bbaaf4b42.tar.xz
ManaVerse-d0d0ddfeb0bd6cb199e3ac571c876d6bbaaf4b42.zip
Create public variable for beingpopup.
Diffstat (limited to 'src/gui/popupmanager.cpp')
-rw-r--r--src/gui/popupmanager.cpp13
1 files changed, 5 insertions, 8 deletions
diff --git a/src/gui/popupmanager.cpp b/src/gui/popupmanager.cpp
index dc9bdc32f..429958e5c 100644
--- a/src/gui/popupmanager.cpp
+++ b/src/gui/popupmanager.cpp
@@ -37,16 +37,13 @@
PopupManager *popupManager = nullptr;
PopupManager::PopupManager() :
- mBeingPopup(new BeingPopup),
mTextPopup(new TextPopup)
{
- mBeingPopup->postInit();
mTextPopup->postInit();
}
PopupManager::~PopupManager()
{
- delete2(mBeingPopup);
delete2(mTextPopup);
}
@@ -58,8 +55,8 @@ void PopupManager::closePopupMenu()
void PopupManager::hideBeingPopup()
{
- if (mBeingPopup)
- mBeingPopup->setVisible(false);
+ if (beingPopup)
+ beingPopup->setVisible(false);
}
void PopupManager::hideTextPopup()
@@ -88,8 +85,8 @@ void PopupManager::clearPopup()
void PopupManager::showBeingPopup(const int x, const int y,
Being *const b)
{
- if (mBeingPopup)
- mBeingPopup->show(x, y, b);
+ if (beingPopup)
+ beingPopup->show(x, y, b);
}
void PopupManager::showTextPopup(const int x, const int y,
@@ -106,5 +103,5 @@ bool PopupManager::isTextPopupVisible() const
bool PopupManager::isBeingPopupVisible() const
{
- return mBeingPopup ? mBeingPopup->isPopupVisible() : false;
+ return beingPopup ? beingPopup->isPopupVisible() : false;
}