2014-09-08 21:46:02 -07:00
|
|
|
// Copyright 2014 Citra Emulator Project
|
2014-12-16 21:38:14 -08:00
|
|
|
// Licensed under GPLv2 or any later version
|
2014-09-08 21:46:02 -07:00
|
|
|
// Refer to the license.txt file included.
|
|
|
|
|
|
|
|
#include "emu_window.h"
|
|
|
|
|
|
|
|
void EmuWindow::KeyPressed(KeyMap::HostDeviceKey key) {
|
2015-01-18 15:07:48 -08:00
|
|
|
Service::HID::PadState mapped_key = KeyMap::GetPadKey(key);
|
2014-09-08 21:46:02 -07:00
|
|
|
|
2015-01-18 15:07:48 -08:00
|
|
|
Service::HID::PadButtonPress(mapped_key);
|
2014-09-08 21:46:02 -07:00
|
|
|
}
|
|
|
|
|
|
|
|
void EmuWindow::KeyReleased(KeyMap::HostDeviceKey key) {
|
2015-01-18 15:07:48 -08:00
|
|
|
Service::HID::PadState mapped_key = KeyMap::GetPadKey(key);
|
2014-09-08 21:46:02 -07:00
|
|
|
|
2015-01-18 15:07:48 -08:00
|
|
|
Service::HID::PadButtonRelease(mapped_key);
|
2014-09-08 21:46:02 -07:00
|
|
|
}
|