Ver Fonte

Revert "UI: Remove unnecessary IS_WIN32 macro"

This reverts commit 113b6317e78cf988e70b5e8c6e03ccbc800ac5d0.
Matt Gajownik há 4 anos atrás
pai
commit
baf980f7a6
1 ficheiros alterados com 7 adições e 1 exclusões
  1. 7 1
      UI/window-basic-main.cpp

+ 7 - 1
UI/window-basic-main.cpp

@@ -4050,6 +4050,12 @@ bool OBSBasic::Active() const
 	return outputHandler->Active();
 }
 
+#ifdef _WIN32
+#define IS_WIN32 1
+#else
+#define IS_WIN32 0
+#endif
+
 static inline int AttemptToResetVideo(struct obs_video_info *ovi)
 {
 	return obs_reset_video(ovi);
@@ -4168,7 +4174,7 @@ int OBSBasic::ResetVideo()
 	}
 
 	ret = AttemptToResetVideo(&ovi);
-	if (_WIN32 && ret != OBS_VIDEO_SUCCESS) {
+	if (IS_WIN32 && ret != OBS_VIDEO_SUCCESS) {
 		if (ret == OBS_VIDEO_CURRENTLY_ACTIVE) {
 			blog(LOG_WARNING, "Tried to reset when "
 					  "already active");