diff options
author | Andrei Karas <akaras@inbox.ru> | 2014-08-21 13:03:09 +0300 |
---|---|---|
committer | Andrei Karas <akaras@inbox.ru> | 2014-08-21 13:03:09 +0300 |
commit | eb5133f5bd812df62597d71bdd7d81fa8c0e9d71 (patch) | |
tree | 5c0cde1b7b58715358171d7436f09e928dac6076 /src/gui/popups/popupmenu.cpp | |
parent | 3e9f4cee927cd1e6d49d769883b0d42f91c1e5ad (diff) | |
download | manaverse-eb5133f5bd812df62597d71bdd7d81fa8c0e9d71.tar.gz manaverse-eb5133f5bd812df62597d71bdd7d81fa8c0e9d71.tar.bz2 manaverse-eb5133f5bd812df62597d71bdd7d81fa8c0e9d71.tar.xz manaverse-eb5133f5bd812df62597d71bdd7d81fa8c0e9d71.zip |
Show in outfits context menu, options from normal windows.
Diffstat (limited to 'src/gui/popups/popupmenu.cpp')
-rw-r--r-- | src/gui/popups/popupmenu.cpp | 22 |
1 files changed, 16 insertions, 6 deletions
diff --git a/src/gui/popups/popupmenu.cpp b/src/gui/popups/popupmenu.cpp index 00256fcbe..cf853966d 100644 --- a/src/gui/popups/popupmenu.cpp +++ b/src/gui/popups/popupmenu.cpp @@ -569,6 +569,7 @@ void PopupMenu::showOutfitsWindowPopup(const int x, const int y) { mX = x; mY = y; + mWindow = outfitWindow; mBrowserBox->clearRows(); @@ -578,6 +579,10 @@ void PopupMenu::showOutfitsWindowPopup(const int x, const int y) // TRANSLATORS: clear selected outfit mBrowserBox->addRow("clear outfit", _("Clear outfit")); mBrowserBox->addRow("##3---"); + + addWindowMenu(outfitWindow); + mBrowserBox->addRow("##3---"); + // TRANSLATORS: popup menu item // TRANSLATORS: close menu mBrowserBox->addRow("cancel", _("Cancel")); @@ -860,6 +865,17 @@ void PopupMenu::showWindowPopup(Window *const window, // TRANSLATORS: popup menu header mBrowserBox->addRow(_("window")); + addWindowMenu(window); + + // TRANSLATORS: popup menu item + // TRANSLATORS: close menu + mBrowserBox->addRow("cancel", _("Cancel")); + + showPopup(x, y); +} + +void PopupMenu::addWindowMenu(Window *const window) +{ if (window->getCloseButton()) { // TRANSLATORS: popup menu item @@ -882,12 +898,6 @@ void PopupMenu::showWindowPopup(Window *const window, mBrowserBox->addRow("window lock", _("Lock")); } } - - // TRANSLATORS: popup menu item - // TRANSLATORS: close menu - mBrowserBox->addRow("cancel", _("Cancel")); - - showPopup(x, y); } void PopupMenu::handleLink(const std::string &link, |