summaryrefslogtreecommitdiff
path: root/src/gui/popupmenu.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/gui/popupmenu.cpp')
-rw-r--r--src/gui/popupmenu.cpp10
1 files changed, 5 insertions, 5 deletions
diff --git a/src/gui/popupmenu.cpp b/src/gui/popupmenu.cpp
index 4577baee..7627c1ad 100644
--- a/src/gui/popupmenu.cpp
+++ b/src/gui/popupmenu.cpp
@@ -26,11 +26,11 @@
#include "inventorywindow.h"
#include "item_amount.h"
#include "popupmenu.h"
-#include "windowcontainer.h"
#include "../being.h"
#include "../beingmanager.h"
#include "../floor_item.h"
+#include "../graphics.h"
#include "../item.h"
#include "../localplayer.h"
#include "../npc.h"
@@ -305,10 +305,10 @@ void PopupMenu::showPopup(int x, int y, Item *item)
void PopupMenu::showPopup(int x, int y)
{
setContentSize(mBrowserBox->getWidth() + 8, mBrowserBox->getHeight() + 8);
- if (windowContainer->getWidth() < (x + getWidth() + 5))
- x = windowContainer->getWidth() - getWidth();
- if (windowContainer->getHeight() < (y + getHeight() + 5))
- y = windowContainer->getHeight() - getHeight();
+ if (graphics->getWidth() < (x + getWidth() + 5))
+ x = graphics->getWidth() - getWidth();
+ if (graphics->getHeight() < (y + getHeight() + 5))
+ y = graphics->getHeight() - getHeight();
setPosition(x, y);
setVisible(true);
requestMoveToTop();