src/core/winrt/SDL_winrtapp_direct3d.cpp
changeset 9240 dc4ad21d8596
parent 8757 aeeeb47a5a77
child 9256 9c45fc8605d9
equal deleted inserted replaced
9239:4a4293b8a37f 9240:dc4ad21d8596
   363         ref new TypedEventHandler<CoreWindow^, KeyEventArgs^>(this, &SDL_WinRTApp::OnKeyDown);
   363         ref new TypedEventHandler<CoreWindow^, KeyEventArgs^>(this, &SDL_WinRTApp::OnKeyDown);
   364 
   364 
   365     window->KeyUp +=
   365     window->KeyUp +=
   366         ref new TypedEventHandler<CoreWindow^, KeyEventArgs^>(this, &SDL_WinRTApp::OnKeyUp);
   366         ref new TypedEventHandler<CoreWindow^, KeyEventArgs^>(this, &SDL_WinRTApp::OnKeyUp);
   367 
   367 
       
   368     window->CharacterReceived +=
       
   369         ref new TypedEventHandler<CoreWindow^, CharacterReceivedEventArgs^>(this, &SDL_WinRTApp::OnCharacterReceived);
       
   370 
   368 #if WINAPI_FAMILY == WINAPI_FAMILY_PHONE_APP
   371 #if WINAPI_FAMILY == WINAPI_FAMILY_PHONE_APP
   369     HardwareButtons::BackPressed +=
   372     HardwareButtons::BackPressed +=
   370         ref new EventHandler<BackPressedEventArgs^>(this, &SDL_WinRTApp::OnBackButtonPressed);
   373         ref new EventHandler<BackPressedEventArgs^>(this, &SDL_WinRTApp::OnBackButtonPressed);
   371 #endif
   374 #endif
   372 
   375 
   701 void SDL_WinRTApp::OnKeyUp(Windows::UI::Core::CoreWindow^ sender, Windows::UI::Core::KeyEventArgs^ args)
   704 void SDL_WinRTApp::OnKeyUp(Windows::UI::Core::CoreWindow^ sender, Windows::UI::Core::KeyEventArgs^ args)
   702 {
   705 {
   703     WINRT_ProcessKeyUpEvent(args);
   706     WINRT_ProcessKeyUpEvent(args);
   704 }
   707 }
   705 
   708 
       
   709 void SDL_WinRTApp::OnCharacterReceived(Windows::UI::Core::CoreWindow^ sender, Windows::UI::Core::CharacterReceivedEventArgs^ args)
       
   710 {
       
   711     WINRT_ProcessCharacterReceivedEvent(args);
       
   712 }
       
   713 
   706 #if WINAPI_FAMILY == WINAPI_FAMILY_PHONE_APP
   714 #if WINAPI_FAMILY == WINAPI_FAMILY_PHONE_APP
   707 void SDL_WinRTApp::OnBackButtonPressed(Platform::Object^ sender, Windows::Phone::UI::Input::BackPressedEventArgs^ args)
   715 void SDL_WinRTApp::OnBackButtonPressed(Platform::Object^ sender, Windows::Phone::UI::Input::BackPressedEventArgs^ args)
   708 {
   716 {
   709     SDL_SendKeyboardKey(SDL_PRESSED, SDL_SCANCODE_AC_BACK);
   717     SDL_SendKeyboardKey(SDL_PRESSED, SDL_SCANCODE_AC_BACK);
   710     SDL_SendKeyboardKey(SDL_RELEASED, SDL_SCANCODE_AC_BACK);
   718     SDL_SendKeyboardKey(SDL_RELEASED, SDL_SCANCODE_AC_BACK);