diff options
Diffstat (limited to 'src/gui/viewport.cpp')
-rw-r--r-- | src/gui/viewport.cpp | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/src/gui/viewport.cpp b/src/gui/viewport.cpp index 3fc5f2d4..9ce537fc 100644 --- a/src/gui/viewport.cpp +++ b/src/gui/viewport.cpp @@ -313,8 +313,8 @@ void Viewport::mousePressed(gcn::MouseEvent &event) if ((being = beingManager->findBeingByPixel(pixelx, pixely)) && being != player_node) { - mPopupMenu->showPopup(event.getX(), event.getY(), being); - return; + mPopupMenu->showPopup(event.getX(), event.getY(), being); + return; } else if ((floorItem = floorItemManager->findByCoordinates(tilex, tiley))) @@ -446,6 +446,11 @@ void Viewport::showPopup(int x, int y, Item *item) mPopupMenu->showPopup(x, y, item); } +void Viewport::closePopupMenu() +{ + mPopupMenu->handleLink("cancel"); +} + void Viewport::optionChanged(const std::string &name) { mScrollLaziness = (int) config.getValue("ScrollLaziness", 32); |