diff options
-rw-r--r-- | src/gui/popupmanager.cpp | 7 | ||||
-rw-r--r-- | src/gui/popupmanager.h | 3 | ||||
-rw-r--r-- | src/gui/viewport.cpp | 5 |
3 files changed, 3 insertions, 12 deletions
diff --git a/src/gui/popupmanager.cpp b/src/gui/popupmanager.cpp index 429958e5c..331b34dd9 100644 --- a/src/gui/popupmanager.cpp +++ b/src/gui/popupmanager.cpp @@ -82,13 +82,6 @@ void PopupManager::clearPopup() popupMenu->clear(); } -void PopupManager::showBeingPopup(const int x, const int y, - Being *const b) -{ - if (beingPopup) - beingPopup->show(x, y, b); -} - void PopupManager::showTextPopup(const int x, const int y, const std::string &text) { diff --git a/src/gui/popupmanager.h b/src/gui/popupmanager.h index ef82e1d8e..cdeebc63b 100644 --- a/src/gui/popupmanager.h +++ b/src/gui/popupmanager.h @@ -60,9 +60,6 @@ class PopupManager final */ ~PopupManager(); - void showBeingPopup(const int x, const int y, - Being *const b); - void showTextPopup(const int x, const int y, const std::string &text); diff --git a/src/gui/viewport.cpp b/src/gui/viewport.cpp index 761daf41f..9bacfeb94 100644 --- a/src/gui/viewport.cpp +++ b/src/gui/viewport.cpp @@ -45,6 +45,7 @@ #include "gui/fonts/font.h" +#include "gui/popups/beingpopup.h" #include "gui/popups/popupmenu.h" #include "gui/windows/ministatuswindow.h" @@ -763,8 +764,8 @@ void Viewport::mouseMoved(MouseEvent &event A_UNUSED) || type == ActorType::PET)) { popupManager->hideTextPopup(); - if (mShowBeingPopup) - popupManager->showBeingPopup(mMouseX, mMouseY, mHoverBeing); + if (mShowBeingPopup && beingPopup) + beingPopup->show(mMouseX, mMouseY, mHoverBeing); } else { |