mirror of
https://github.com/hrydgard/ppsspp.git
synced 2026-10-21 10:19:04 +02:00
Cleanup, confine g_controllerMap access to KeyMap.cpp
This commit is contained in:
1 parent
d523005c2b
commit
c1b5aed9b7
5 files changed
+46
-23
No files matched your search
@@ -222,8 +222,7 @@ UI::EventReturn SingleControlMapper::OnAddMouse(UI::EventParams ¶ms) {
|
||||
|
||||
UI::EventReturn SingleControlMapper::OnDelete(UI::EventParams ¶ms) {
|
||||
int index = atoi(params.v->Tag().c_str());
|
||||
KeyMap::g_controllerMap[pspKey_].erase(KeyMap::g_controllerMap[pspKey_].begin() + index);
|
||||
KeyMap::g_controllerMapGeneration++;
|
||||
KeyMap::DeleteNthMapping(pspKey_, index);
|
||||
|
||||
if (index + 1 < (int)rows_.size())
|
||||
rows_[index]->SetFocus();
|
||||
@@ -285,8 +284,7 @@ void ControlMappingScreen::update() {
|
||||
}
|
||||
|
||||
UI::EventReturn ControlMappingScreen::OnClearMapping(UI::EventParams ¶ms) {
|
||||
KeyMap::g_controllerMap.clear();
|
||||
KeyMap::g_controllerMapGeneration++;
|
||||
KeyMap::ClearAllMappings();
|
||||
return UI::EVENT_DONE;
|
||||
}
|
||||
|
||||
|
||||
Reference in new issue
Block a user