From ec5a06754164bb2f77d3627990f896c040fc1c76 Mon Sep 17 00:00:00 2001 From: Andrei Karas Date: Thu, 30 Jan 2014 22:10:01 +0300 Subject: Combine "Mod" and "Stop attack" keys. Remove old "Mod" key because it conflicting with "Stop attack" --- src/gui/setupactiondata.h | 8 +------- src/gui/windows/inventorywindow.cpp | 8 +++++--- 2 files changed, 6 insertions(+), 10 deletions(-) (limited to 'src/gui') diff --git a/src/gui/setupactiondata.h b/src/gui/setupactiondata.h index b80052b30..2b9d694a8 100644 --- a/src/gui/setupactiondata.h +++ b/src/gui/setupactiondata.h @@ -96,7 +96,7 @@ static SetupActionData setupActionData0[] = }, { // TRANSLATORS: input action name - N_("Stop Attack"), + N_("Stop Attack / Modifier key"), Input::KEY_STOP_ATTACK, "", }, @@ -1366,12 +1366,6 @@ static SetupActionData setupActionData6[] = Input::KEY_CAMERA, "", }, - { - // TRANSLATORS: input action name - N_("Modifier key"), - Input::KEY_MOD, - "", - }, { // TRANSLATORS: input action name N_("Show onscreen keyboard"), diff --git a/src/gui/windows/inventorywindow.cpp b/src/gui/windows/inventorywindow.cpp index da91b84be..02b30aed7 100644 --- a/src/gui/windows/inventorywindow.cpp +++ b/src/gui/windows/inventorywindow.cpp @@ -425,7 +425,8 @@ void InventoryWindow::action(const gcn::ActionEvent &event) if (PlayerInfo::isItemProtected(item->getId())) return; - if (inputManager.isActionActive(static_cast(Input::KEY_MOD))) + if (inputManager.isActionActive(static_cast( + Input::KEY_STOP_ATTACK))) { PlayerInfo::dropItem(item, item->getQuantity(), true); } @@ -474,10 +475,11 @@ void InventoryWindow::mouseClicked(gcn::MouseEvent &event) gui->resetClickCount(); const bool mod = (isStorageActive() && inputManager.isActionActive( - static_cast(Input::KEY_MOD))); + static_cast(Input::KEY_STOP_ATTACK))); const bool mod2 = (tradeWindow && tradeWindow->isWindowVisible() - && inputManager.isActionActive(static_cast(Input::KEY_MOD))); + && inputManager.isActionActive(static_cast( + Input::KEY_STOP_ATTACK))); if (!mod && !mod2 && event.getButton() == gcn::MouseEvent::RIGHT) { -- cgit v1.2.3-70-g09d2