OSDN Git Service

[WIN32] Windows: Revert before commits.
authorKyuma Ohta <whatisthis.sowhat@gmail.com>
Sun, 31 May 2015 14:55:56 +0000 (23:55 +0900)
committerKyuma Ohta <whatisthis.sowhat@gmail.com>
Sun, 31 May 2015 14:55:56 +0000 (23:55 +0900)
source/src/win32_input.cpp
source/src/winmain.cpp

index 1f3c6c4..38a2e59 100644 (file)
@@ -91,7 +91,7 @@ void EMU::initialize_input()
        
        // XXX: no gui to change config.use_direct_inpu, so we need to modify *.ini file manually
        if(config.use_direct_input) {
-               if(SUCCEEDED(DirectInputCreate(instance_handle, DIRECTINPUT_VERSION, &lpdi, NULL))) {
+               if (SUCCEEDED(DirectInput8Create(instance_handle, DIRECTINPUT_VERSION, IID_IDirectInput8, (LPVOID *)&lpdi, NULL))) {
                        if(SUCCEEDED(lpdi->CreateDevice(GUID_SysKeyboard, &lpdikey, NULL))) {
                                if(SUCCEEDED(lpdikey->SetDataFormat(&c_dfDIKeyboard))) {
                                        if(SUCCEEDED(lpdikey->SetCooperativeLevel(main_window_handle, DISCL_FOREGROUND | DISCL_NONEXCLUSIVE))) {
index f74c2e4..e87a125 100644 (file)
@@ -99,7 +99,7 @@ _TCHAR* get_parent_dir(_TCHAR* file)
        _TCHAR *ptr;
        
        GetFullPathName(file, _MAX_PATH, path, &ptr);
-       *ptr = _T('\0');
+       //*ptr = _T('\0');
        return path;
 }