Kaynağa Gözat

Some Win32 and Win64 compilation fixes.

legacy
Sam Hocevar 6 yıl önce
ebeveyn
işleme
3d83307dfa
3 değiştirilmiş dosya ile 28 ekleme ve 21 silme
  1. +5
    -0
      src/image/codec/gdiplus-image.cpp
  2. +2
    -0
      src/lol/sys/thread.h
  3. +21
    -21
      src/platform/d3d9/d3d9input.cpp

+ 5
- 0
src/image/codec/gdiplus-image.cpp Dosyayı Görüntüle

@@ -17,7 +17,12 @@
# include <algorithm>
using std::min;
using std::max;
# define WIN32_LEAN_AND_MEAN 1
# include <windows.h>
# undef NEAR // avoids errors in <objidl.h>
# undef FAR
# define NEAR
# define FAR
# include <objidl.h> // for DEFINE_GUID
# include <gdiplus.h>



+ 2
- 0
src/lol/sys/thread.h Dosyayı Görüntüle

@@ -31,7 +31,9 @@
* https://connect.microsoft.com/VisualStudio/feedback/details/747145 */
#if defined(_MSC_VER) && (_MSC_VER < 1900)
# define LOL_VISUAL_STUDIO_BUG_747145_WORKAROUND 1
# define WIN32_LEAN_AND_MEAN 1
# include <windows.h>
# undef WIN32_LEAN_AND_MEAN
# undef near /* Fuck Microsoft */
# undef far /* Fuck Microsoft again */
#endif


+ 21
- 21
src/platform/d3d9/d3d9input.cpp Dosyayı Görüntüle

@@ -57,27 +57,27 @@ D3d9Input::D3d9Input()
// TODO: we can put more friendly name here, such as LeftAxisX, ButtonX...
InputDeviceInternal* stick = new InputDeviceInternal(g_name_joystick(i + 1));

stick->AddAxis(g_name_xbox_axis_left_x.C());
stick->AddAxis(g_name_xbox_axis_left_y.C());
stick->AddAxis(g_name_xbox_axis_right_x.C());
stick->AddAxis(g_name_xbox_axis_right_y.C());
stick->AddAxis(g_name_xbox_axis_left_trigger.C());
stick->AddAxis(g_name_xbox_axis_right_trigger.C());
stick->AddKey(g_name_xbox_key_dpad_up.C());
stick->AddKey(g_name_xbox_key_dpad_down.C());
stick->AddKey(g_name_xbox_key_dpad_left.C());
stick->AddKey(g_name_xbox_key_dpad_right.C());
stick->AddKey(g_name_xbox_key_start.C());
stick->AddKey(g_name_xbox_key_back.C());
stick->AddKey(g_name_xbox_key_left_thumb.C());
stick->AddKey(g_name_xbox_key_right_thumb.C());
stick->AddKey(g_name_xbox_key_left_shoulder.C());
stick->AddKey(g_name_xbox_key_right_shoulder.C());
stick->AddKey(g_name_xbox_key_a.C());
stick->AddKey(g_name_xbox_key_b.C());
stick->AddKey(g_name_xbox_key_x.C());
stick->AddKey(g_name_xbox_key_y.C());
stick->AddAxis(g_name_xbox_axis_left_x.c_str());
stick->AddAxis(g_name_xbox_axis_left_y.c_str());
stick->AddAxis(g_name_xbox_axis_right_x.c_str());
stick->AddAxis(g_name_xbox_axis_right_y.c_str());
stick->AddAxis(g_name_xbox_axis_left_trigger.c_str());
stick->AddAxis(g_name_xbox_axis_right_trigger.c_str());
stick->AddKey(g_name_xbox_key_dpad_up.c_str());
stick->AddKey(g_name_xbox_key_dpad_down.c_str());
stick->AddKey(g_name_xbox_key_dpad_left.c_str());
stick->AddKey(g_name_xbox_key_dpad_right.c_str());
stick->AddKey(g_name_xbox_key_start.c_str());
stick->AddKey(g_name_xbox_key_back.c_str());
stick->AddKey(g_name_xbox_key_left_thumb.c_str());
stick->AddKey(g_name_xbox_key_right_thumb.c_str());
stick->AddKey(g_name_xbox_key_left_shoulder.c_str());
stick->AddKey(g_name_xbox_key_right_shoulder.c_str());
stick->AddKey(g_name_xbox_key_a.c_str());
stick->AddKey(g_name_xbox_key_b.c_str());
stick->AddKey(g_name_xbox_key_x.c_str());
stick->AddKey(g_name_xbox_key_y.c_str());

m_data->m_joysticks.push(i, stick);
}


Yükleniyor…
İptal
Kaydet