Changeset 3669 in vbox for trunk/src/VBox/Frontends
- Timestamp:
- Jul 17, 2007 9:12:18 AM (17 years ago)
- Location:
- trunk/src/VBox/Frontends
- Files:
-
- 15 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Frontends/VBoxBFE/COMDefs.h
r3534 r3669 23 23 #define COMDefs_H 24 24 25 #ifdef __WIN__25 #ifdef RT_OS_WINDOWS 26 26 # include <Windows.h> 27 27 #endif … … 43 43 #define ATL_NO_VTABLE 44 44 45 #ifndef __WIN__45 #ifndef RT_OS_WINDOWS 46 46 typedef unsigned long HRESULT; 47 47 typedef unsigned long ULONG; /// @todo 64-bit: ULONG is 32-bit. … … 72 72 # define SUCCEEDED NS_SUCCEEDED 73 73 # define FAILED NS_FAILED 74 #endif /* ! __WIN__*/74 #endif /* !RT_OS_WINDOWS */ 75 75 76 76 #endif -
trunk/src/VBox/Frontends/VBoxBFE/NetworkAdapterImpl.cpp
r2981 r3669 137 137 NetworkAdapter::COMSETTER(HostInterface)(INPTR BSTR hostInterface) 138 138 { 139 #ifdef __LINUX__139 #ifdef RT_OS_LINUX 140 140 // empty strings are not allowed as path names 141 141 if (hostInterface && !(*hostInterface)) -
trunk/src/VBox/Frontends/VBoxBFE/NetworkAdapterImpl.h
r2981 r3669 50 50 : mSlot (0), mEnabled (FALSE) 51 51 , mCableConnected (TRUE), mTraceEnabled (FALSE) 52 #ifdef __LINUX__52 #ifdef RT_OS_LINUX 53 53 , mTAPFD (NIL_RTFILE) 54 54 #endif … … 62 62 BOOL mTraceEnabled; 63 63 Bstr mHostInterface; 64 #ifdef __LINUX__64 #ifdef RT_OS_LINUX 65 65 Bstr mTAPSetupApplication; 66 66 Bstr mTAPTerminateApplication; … … 90 90 STDMETHOD(COMGETTER(HostInterface))(BSTR *hostInterface); 91 91 STDMETHOD(COMSETTER(HostInterface))(INPTR BSTR hostInterface); 92 #ifdef __LINUX__92 #ifdef RT_OS_LINUX 93 93 STDMETHOD(COMGETTER(TAPFileDescriptor))(LONG *tapFileDescriptor); 94 94 STDMETHOD(COMSETTER(TAPFileDescriptor))(LONG tapFileDescriptor); -
trunk/src/VBox/Frontends/VBoxBFE/SDLConsole.cpp
r2980 r3669 25 25 *******************************************************************************/ 26 26 #define LOG_GROUP LOG_GROUP_GUI 27 #ifdef __DARWIN__27 #ifdef RT_OS_DARWIN 28 28 # include <Carbon/Carbon.h> 29 29 # define OSType VBoxOSType … … 414 414 } 415 415 416 #if defined( __DARWIN__)416 #if defined(RT_OS_DARWIN) 417 417 /** 418 418 * Fallback keycode conversion using SDL symbols. … … 574 574 } 575 575 } 576 #endif /* __DARWIN__*/576 #endif /* RT_OS_DARWIN */ 577 577 578 578 /** … … 675 675 } 676 676 677 #elif defined( __DARWIN__)677 #elif defined(RT_OS_DARWIN) 678 678 /* This is derived partially from SDL_QuartzKeys.h and partially from testing. */ 679 679 static const uint8_t s_aMacToSet1[] = … … 1033 1033 } 1034 1034 1035 #ifdef __DARWIN__1035 #ifdef RT_OS_DARWIN 1036 1036 1037 1037 __BEGIN_DECLS … … 1093 1093 g_fHotKeysDisabled = enmMode == kCGSGlobalHotKeyDisable; 1094 1094 } 1095 #endif /* __DARWIN__*/1095 #endif /* RT_OS_DARWIN */ 1096 1096 1097 1097 /** … … 1100 1100 void SDLConsole::inputGrabStart() 1101 1101 { 1102 #ifdef __DARWIN__1102 #ifdef RT_OS_DARWIN 1103 1103 DisableGlobalHotKeys(true); 1104 1104 #endif … … 1120 1120 if (!gMouse->getNeedsHostCursor()) 1121 1121 SDL_ShowCursor(SDL_ENABLE); 1122 #ifdef __DARWIN__1122 #ifdef RT_OS_DARWIN 1123 1123 DisableGlobalHotKeys(false); 1124 1124 #endif … … 1288 1288 const uint8_t *srcShapePtr = data->shape + ((andMaskSize + 3) & ~3); 1289 1289 1290 #if defined ( __WIN__)1290 #if defined (RT_OS_WINDOWS) 1291 1291 1292 1292 BITMAPV5HEADER bi; -
trunk/src/VBox/Frontends/VBoxBFE/SDLConsole.h
r2981 r3669 26 26 /* include this first so Windows.h get's in before our stuff. */ 27 27 #include <SDL.h> 28 #ifndef __DARWIN__28 #ifndef RT_OS_DARWIN 29 29 # include <SDL_syswm.h> 30 30 #endif 31 #if defined( __WIN__) /// @todo someone please explain why this is necessary. This breaks darwin solid.31 #if defined(RT_OS_WINDOWS) /// @todo someone please explain why this is necessary. This breaks darwin solid. 32 32 // damn SDL redefines main! 33 33 #undef main -
trunk/src/VBox/Frontends/VBoxBFE/SDLFramebuffer.cpp
r3576 r3669 51 51 LogFlow(("SDLFramebuffer::SDLFramebuffer\n")); 52 52 53 #if defined ( __WIN__)53 #if defined (RT_OS_WINDOWS) 54 54 refcnt = 0; 55 55 #endif … … 70 70 #endif 71 71 72 #ifdef __LINUX__72 #ifdef RT_OS_LINUX 73 73 /* NOTE: we still want Ctrl-C to work, so we undo the SDL redirections */ 74 74 signal(SIGINT, SIG_DFL); … … 233 233 x, y, w, h)); 234 234 235 #ifdef __LINUX__235 #ifdef RT_OS_LINUX 236 236 /* 237 237 * SDL does not allow us to make this call from any other … … 254 254 /* in order to not flood the SDL event queue, yield the CPU */ 255 255 RTThreadYield(); 256 #else /* ! __LINUX__*/256 #else /* !RT_OS_LINUX */ 257 257 update(x, y + mTopOffset, w, h); 258 #endif /* ! __LINUX__*/258 #endif /* !RT_OS_LINUX */ 259 259 260 260 /* … … 373 373 { 374 374 sdlFlags |= SDL_FULLSCREEN; 375 #ifdef __WIN__375 #ifdef RT_OS_WINDOWS 376 376 /* this flag causes a crash on Windows, mScreen->pixels is NULL */ 377 377 sdlFlags &= ~SDL_HWSURFACE; … … 419 419 void SDLFramebuffer::update(int x, int y, int w, int h) 420 420 { 421 #ifdef __LINUX__421 #ifdef RT_OS_LINUX 422 422 AssertMsg(mSdlNativeThread == RTThreadNativeSelf(), ("Wrong thread! SDL is not threadsafe!\n")); 423 423 #endif -
trunk/src/VBox/Frontends/VBoxBFE/SDLFramebuffer.h
r3576 r3669 100 100 uint32_t mLabelHeight; 101 101 #endif 102 #ifdef __WIN__102 #ifdef RT_OS_WINDOWS 103 103 long refcnt; 104 104 #endif -
trunk/src/VBox/Frontends/VBoxBFE/USBProxyService.h
r2981 r3669 178 178 179 179 180 #if defined( __LINUX__) || defined(__L4__)180 #if defined(RT_OS_LINUX) || defined(__L4__) 181 181 #include <stdio.h> 182 182 … … 212 212 std::string mUsbfsRoot; 213 213 }; 214 #endif /* __LINUX__*/215 216 217 #ifdef __WIN__214 #endif /* RT_OS_LINUX */ 215 216 217 #ifdef RT_OS_WINDOWS 218 218 /** 219 219 * The Win32/Win64 hosted USB Proxy Service. -
trunk/src/VBox/Frontends/VBoxBFE/VBoxBFE.cpp
r3580 r3669 65 65 #include <errno.h> 66 66 67 #if defined( __LINUX__) || defined(__L4__)67 #if defined(RT_OS_LINUX) || defined(__L4__) 68 68 #include <fcntl.h> 69 69 #include <net/if.h> … … 200 200 PDMMAC Mac; /**< The mac address for the device. */ 201 201 const char *pszName; /**< The device name of a HIF device. The name of the internal network. */ 202 #if 1//defined( __LINUX__)202 #if 1//defined(RT_OS_LINUX) 203 203 bool fHaveFd; /**< Set if fd is valid. */ 204 204 int32_t fd; /**< The file descriptor of a HIF device.*/ … … 303 303 " -netsniff<1-N> Enable packet sniffer\n" 304 304 #endif 305 #ifdef __LINUX__305 #ifdef RT_OS_LINUX 306 306 " -tapfd<1-N> <fd> Use existing TAP device, don't allocate\n" 307 307 #endif … … 562 562 /** @todo filename */ 563 563 } 564 #ifdef __LINUX__564 #ifdef RT_OS_LINUX 565 565 else if (strncmp(pszArg, "-tapfd", 6) == 0) 566 566 { … … 573 573 g_aNetDevs[i].fHaveFd = true; 574 574 } 575 #endif /* __LINUX__*/575 #endif /* RT_OS_LINUX */ 576 576 #ifdef VBOX_VRDP 577 577 else if (strcmp(pszArg, "-vrdp") == 0) … … 686 686 do 687 687 { 688 #if defined( __LINUX__) && defined(USE_SDL)688 #if defined(RT_OS_LINUX) && defined(USE_SDL) 689 689 if ( machineState == VMSTATE_CREATING 690 690 || machineState == VMSTATE_LOADING) … … 1479 1479 rc = CFGMR3InsertNode(pLunL0, "Config", &pCfg); UPDATE_RC(); 1480 1480 1481 #if defined( __LINUX__)1481 #if defined(RT_OS_LINUX) 1482 1482 if (g_aNetDevs[ulInstance].fHaveFd) 1483 1483 { … … 1490 1490 #endif 1491 1491 { 1492 #if defined ( __LINUX__) || defined (__L4__)1492 #if defined (RT_OS_LINUX) || defined (__L4__) 1493 1493 /* 1494 1494 * Create/Open the TAP the device. … … 1541 1541 rc = CFGMR3InsertInteger(pCfg, "FileHandle", (RTFILE)tapFD); UPDATE_RC(); 1542 1542 1543 #elif defined( __WIN__)1543 #elif defined(RT_OS_WINDOWS) 1544 1544 /* 1545 1545 * We need the GUID too here... … … 1550 1550 1551 1551 1552 #else /* ! __LINUX__&& !__L4__ */1552 #else /* !RT_OS_LINUX && !__L4__ */ 1553 1553 FatalError("Name based HIF devices not implemented yet for this host platform\n"); 1554 1554 return VERR_NOT_IMPLEMENTED; … … 1598 1598 rc = CFGMR3InsertString(pLunL0, "Driver", "AUDIO"); UPDATE_RC(); 1599 1599 rc = CFGMR3InsertNode(pLunL0, "Config", &pCfg); UPDATE_RC(); 1600 #ifdef __WIN__1600 #ifdef RT_OS_WINDOWS 1601 1601 rc = CFGMR3InsertString(pCfg, "AudioDriver", "winmm"); UPDATE_RC(); 1602 #elif defined( __DARWIN__)1602 #elif defined(RT_OS_DARWIN) 1603 1603 rc = CFGMR3InsertString(pCfg, "AudioDriver", "coreaudio"); UPDATE_RC(); 1604 #elif defined( __LINUX__)1604 #elif defined(RT_OS_LINUX) 1605 1605 rc = CFGMR3InsertString(pCfg, "AudioDriver", "oss"); UPDATE_RC(); 1606 1606 #elif defined(__L4ENV__) … … 1608 1608 #else /* portme */ 1609 1609 rc = CFGMR3InsertString(pCfg, "AudioDriver", "none"); UPDATE_RC(); 1610 #endif /* ! __WIN__*/1610 #endif /* !RT_OS_WINDOWS */ 1611 1611 } 1612 1612 -
trunk/src/VBox/Frontends/VBoxSDL/Framebuffer.cpp
r3614 r3669 30 30 #include <iprt/stream.h> 31 31 32 #ifdef __OS2__32 #ifdef RT_OS_OS2 33 33 # undef RT_MAX 34 34 // from <iprt/cdefs.h> … … 87 87 LogFlow(("VBoxSDLFB::VBoxSDLFB\n")); 88 88 89 #if defined ( __WIN__)89 #if defined (RT_OS_WINDOWS) 90 90 refcnt = 0; 91 91 #endif … … 122 122 AssertMsg(rc == VINF_SUCCESS, ("Error from RTCritSectInit!\n")); 123 123 124 #ifdef __WIN__124 #ifdef RT_OS_WINDOWS 125 125 /* default to DirectX if nothing else set */ 126 126 if (!getenv("SDL_VIDEODRIVER")) … … 130 130 } 131 131 #endif 132 #ifdef __LINUX__132 #ifdef RT_OS_LINUX 133 133 /* On some X servers the mouse is stuck inside the bottom right corner. 134 134 * See http://wiki.clug.org.za/wiki/QEMU_mouse_not_working */ … … 142 142 } 143 143 144 #ifdef __LINUX__144 #ifdef RT_OS_LINUX 145 145 /* NOTE: we still want Ctrl-C to work, so we undo the SDL redirections */ 146 146 signal(SIGINT, SIG_DFL); … … 392 392 x, y, w, h)); 393 393 394 #ifdef __LINUX__394 #ifdef RT_OS_LINUX 395 395 /* 396 396 * SDL does not allow us to make this call from any other thread than … … 406 406 event.user.data2 = (void*)(w << 16 | h); 407 407 PushNotifyUpdateEvent(&event); 408 #else /* ! __LINUX__*/408 #else /* !RT_OS_LINUX */ 409 409 update(x, y, w, h, true /* fGuestRelative */); 410 #endif /* ! __LINUX__*/410 #endif /* !RT_OS_LINUX */ 411 411 412 412 /* … … 796 796 void VBoxSDLFB::update(int x, int y, int w, int h, bool fGuestRelative) 797 797 { 798 #ifdef __LINUX__798 #ifdef RT_OS_LINUX 799 799 AssertMsg(mSdlNativeThread == RTThreadNativeSelf(), ("Wrong thread! SDL is not threadsafe!\n")); 800 800 #endif … … 995 995 void VBoxSDLFB::paintSecureLabel(int x, int y, int w, int h, bool fForce) 996 996 { 997 #ifdef __LINUX__997 #ifdef RT_OS_LINUX 998 998 AssertMsg(mSdlNativeThread == RTThreadNativeSelf(), ("Wrong thread! SDL is not threadsafe!\n")); 999 999 #endif -
trunk/src/VBox/Frontends/VBoxSDL/Framebuffer.h
r3578 r3669 52 52 virtual ~VBoxSDLFB(); 53 53 54 #ifdef __WIN__54 #ifdef RT_OS_WINDOWS 55 55 STDMETHOD_(ULONG, AddRef)() 56 56 { … … 179 179 uint32_t mLabelHeight; 180 180 #endif 181 #ifdef __WIN__181 #ifdef RT_OS_WINDOWS 182 182 long refcnt; 183 183 #endif … … 200 200 virtual ~VBoxSDLFBOverlay(); 201 201 202 #ifdef __WIN__202 #ifdef RT_OS_WINDOWS 203 203 STDMETHOD_(ULONG, AddRef)() 204 204 { … … 285 285 /** Additional SDL surface used for combining the framebuffer and the overlay */ 286 286 SDL_Surface *mBlendedBits; 287 #ifdef __WIN__287 #ifdef RT_OS_WINDOWS 288 288 long refcnt; 289 289 #endif -
trunk/src/VBox/Frontends/VBoxSDL/Helper.h
r3289 r3669 24 24 #define __H_HELPER 25 25 26 #if defined(VBOX_WITH_XPCOM) && !defined( __DARWIN__) && !defined(__OS2__)26 #if defined(VBOX_WITH_XPCOM) && !defined(RT_OS_DARWIN) && !defined(RT_OS_OS2) 27 27 28 28 /** Indicates that the XPCOM queue thread is needed for this platform. */ … … 52 52 void terminateXPCOMQueueThread(void); 53 53 54 #endif /* defined(VBOX_WITH_XPCOM) && !defined( __DARWIN__) && !defined(__OS2__) */54 #endif /* defined(VBOX_WITH_XPCOM) && !defined(RT_OS_DARWIN) && !defined(RT_OS_OS2) */ 55 55 56 56 #endif // __H_HELPER -
trunk/src/VBox/Frontends/VBoxSDL/VBoxSDL.cpp
r3667 r3669 34 34 using namespace com; 35 35 36 #if defined ( __LINUX__)36 #if defined (RT_OS_LINUX) 37 37 #include <X11/Xlib.h> 38 38 #include <X11/cursorfont.h> /* for XC_left_ptr */ … … 185 185 static VBoxSDLFB *gpFrameBuffer = NULL; 186 186 static SDL_Cursor *gpDefaultCursor = NULL; 187 #ifdef __LINUX__187 #ifdef RT_OS_LINUX 188 188 static Cursor gpDefaultOrigX11Cursor; 189 189 #endif … … 193 193 static SDL_TimerID gSdlResizeTimer = NULL; 194 194 195 #ifdef __LINUX__195 #ifdef RT_OS_LINUX 196 196 static SDL_SysWMinfo gSdlInfo; 197 197 #endif 198 198 199 199 #ifdef VBOX_SECURELABEL 200 #ifdef __WIN__200 #ifdef RT_OS_WINDOWS 201 201 #define LIBSDL_TTF_NAME "SDL_ttf" 202 202 #else … … 218 218 VBoxSDLCallback() 219 219 { 220 #if defined ( __WIN__)220 #if defined (RT_OS_WINDOWS) 221 221 refcnt = 0; 222 222 #endif … … 227 227 } 228 228 229 #ifdef __WIN__229 #ifdef RT_OS_WINDOWS 230 230 STDMETHOD_(ULONG, AddRef)() 231 231 { … … 346 346 347 347 private: 348 #ifdef __WIN__348 #ifdef RT_OS_WINDOWS 349 349 long refcnt; 350 350 #endif … … 361 361 VBoxSDLConsoleCallback() : m_fIgnorePowerOffEvents(false) 362 362 { 363 #if defined ( __WIN__)363 #if defined (RT_OS_WINDOWS) 364 364 refcnt = 0; 365 365 #endif … … 370 370 } 371 371 372 #ifdef __WIN__372 #ifdef RT_OS_WINDOWS 373 373 STDMETHOD_(ULONG, AddRef)() 374 374 { … … 570 570 571 571 private: 572 #ifdef __WIN__572 #ifdef RT_OS_WINDOWS 573 573 long refcnt; 574 574 #endif … … 601 601 " -detecthostkey Get the hostkey identifier and modifier state\n" 602 602 " -hostkey <key> {<key2>} <mod> Set the host key to the values obtained using -detecthostkey\n" 603 #if defined( __LINUX__) || defined(__DARWIN__) /** @todo UNIXISH_TAP stuff out of main and up to Config.kmk! */603 #if defined(RT_OS_LINUX) || defined(RT_OS_DARWIN) /** @todo UNIXISH_TAP stuff out of main and up to Config.kmk! */ 604 604 " -tapdev<1-N> <dev> Use existing persistent TAP device with the given name\n" 605 605 " -tapfd<1-N> <fd> Use existing TAP device, don't allocate\n" … … 652 652 } 653 653 654 #ifdef __LINUX__654 #ifdef RT_OS_LINUX 655 655 /** 656 656 * Custom signal handler. Currently it is only used to release modifier … … 669 669 } 670 670 } 671 #endif /* __LINUX__*/671 #endif /* RT_OS_LINUX */ 672 672 673 673 /** entry point */ … … 684 684 } 685 685 686 #ifdef __LINUX__686 #ifdef RT_OS_LINUX 687 687 /* 688 688 * Lock keys on SDL behave different from normal keys: A KeyPress event is generated … … 927 927 sysInfo->COMGETTER (NetworkAdapterCount) (&NetworkAdapterCount); 928 928 929 #if defined( __LINUX__) || defined(__DARWIN__)929 #if defined(RT_OS_LINUX) || defined(RT_OS_DARWIN) 930 930 std::vector <Bstr> tapdev (NetworkAdapterCount); 931 931 std::vector <int> tapfd (NetworkAdapterCount, 0); … … 1097 1097 } 1098 1098 } 1099 #if defined( __LINUX__) || defined(__DARWIN__)1099 #if defined(RT_OS_LINUX) || defined(RT_OS_DARWIN) 1100 1100 else if (strncmp(argv[curArg], "-tapdev", 7) == 0) 1101 1101 { … … 1124 1124 curArg++; 1125 1125 } 1126 #endif /* __LINUX__ || __DARWIN__*/1126 #endif /* RT_OS_LINUX || RT_OS_DARWIN */ 1127 1127 #ifdef VBOX_VRDP 1128 1128 else if (strcmp(argv[curArg], "-vrdp") == 0) … … 1654 1654 consoleCallback->ignorePowerOffEvents(true); 1655 1655 1656 #if defined( __LINUX__) || defined(__DARWIN__)1656 #if defined(RT_OS_LINUX) || defined(RT_OS_DARWIN) 1657 1657 /* 1658 1658 * Do we have a TAP device name or file descriptor? If so, communicate … … 1691 1691 } 1692 1692 } 1693 #endif /* __LINUX__ || __DARWIN__*/1693 #endif /* RT_OS_LINUX || RT_OS_DARWIN */ 1694 1694 1695 1695 #ifdef VBOX_VRDP … … 1780 1780 gpDefaultCursor = SDL_GetCursor(); 1781 1781 1782 #ifdef __LINUX__1782 #ifdef RT_OS_LINUX 1783 1783 /* Get Window Manager info. We only need the X11 display. */ 1784 1784 SDL_VERSION(&gSdlInfo.version); … … 1794 1794 *(Cursor*)gpDefaultCursor->wm_cursor = XCreateFontCursor(gSdlInfo.info.x11.display, XC_left_ptr); 1795 1795 SDL_SetCursor(gpDefaultCursor); 1796 #endif /* __LINUX__*/1796 #endif /* RT_OS_LINUX */ 1797 1797 1798 1798 /* create a fake empty cursor */ … … 1807 1807 * Register our user signal handler. 1808 1808 */ 1809 #ifdef __LINUX__1809 #ifdef RT_OS_LINUX 1810 1810 struct sigaction sa; 1811 1811 sa.sa_sigaction = signal_handler; … … 1813 1813 sa.sa_flags = SA_RESTART | SA_SIGINFO; 1814 1814 sigaction (SIGUSR1, &sa, NULL); 1815 #endif /* __LINUX__*/1815 #endif /* RT_OS_LINUX */ 1816 1816 1817 1817 /* … … 2394 2394 leave: 2395 2395 LogFlow(("leaving...\n")); 2396 #if defined(VBOX_WITH_XPCOM) && !defined( __DARWIN__) && !defined(__OS2__)2396 #if defined(VBOX_WITH_XPCOM) && !defined(RT_OS_DARWIN) && !defined(RT_OS_OS2) 2397 2397 /* make sure the XPCOM event queue thread doesn't do anything harmful */ 2398 2398 terminateXPCOMQueueThread(); … … 2453 2453 if (gpDefaultCursor) 2454 2454 { 2455 #ifdef __LINUX__2455 #ifdef RT_OS_LINUX 2456 2456 Cursor pDefaultTempX11Cursor = *(Cursor*)gpDefaultCursor->wm_cursor; 2457 2457 *(Cursor*)gpDefaultCursor->wm_cursor = gpDefaultOrigX11Cursor; 2458 #endif /* __LNUX__*/2458 #endif /* RT_OS_LINUX */ 2459 2459 SDL_SetCursor(gpDefaultCursor); 2460 #ifdef __LINUX__2460 #ifdef RT_OS_LINUX 2461 2461 XFreeCursor(gSdlInfo.info.x11.display, pDefaultTempX11Cursor); 2462 #endif /* __LINUX__*/2462 #endif /* RT_OS_LINUX */ 2463 2463 } 2464 2464 … … 2470 2470 if (pCustomTempWMCursor) 2471 2471 { 2472 #if defined ( __WIN__)2472 #if defined (RT_OS_WINDOWS) 2473 2473 ::DestroyCursor(*(HCURSOR *) pCustomTempWMCursor); 2474 #elif defined ( __LINUX__)2474 #elif defined (RT_OS_LINUX) 2475 2475 XFreeCursor(gSdlInfo.info.x11.display, *(Cursor *) pCustomTempWMCursor); 2476 2476 #endif … … 2537 2537 } 2538 2538 2539 #if defined( __DARWIN__)2539 #if defined(RT_OS_DARWIN) 2540 2540 /** 2541 2541 * Fallback keycode conversion using SDL symbols. … … 2697 2697 } 2698 2698 } 2699 #endif /* __DARWIN__*/2699 #endif /* RT_OS_DARWIN */ 2700 2700 2701 2701 /** … … 2710 2710 int keycode = ev->keysym.scancode; 2711 2711 2712 #ifdef __LINUX__2712 #ifdef RT_OS_LINUX 2713 2713 // workaround for SDL keyboard translation issues on Linux 2714 2714 // keycodes > 0x100 are sent as 0xe0 keycode … … 2807 2807 } 2808 2808 2809 #elif defined( __DARWIN__)2809 #elif defined(RT_OS_DARWIN) 2810 2810 /* This is derived partially from SDL_QuartzKeys.h and partially from testing. */ 2811 2811 static const uint16_t s_aMacToSet1[] = … … 2980 2980 #endif 2981 2981 2982 #endif /* __DARWIN__*/2982 #endif /* RT_OS_DARWIN */ 2983 2983 return keycode; 2984 2984 } … … 3205 3205 } 3206 3206 3207 #ifdef __DARWIN__3207 #ifdef RT_OS_DARWIN 3208 3208 #include <Carbon/Carbon.h> 3209 3209 __BEGIN_DECLS … … 3265 3265 g_fHotKeysDisabled = enmMode == kCGSGlobalHotKeyDisable; 3266 3266 } 3267 #endif /* __DARWIN__*/3267 #endif /* RT_OS_DARWIN */ 3268 3268 3269 3269 /** … … 3272 3272 static void InputGrabStart(void) 3273 3273 { 3274 #ifdef __DARWIN__3274 #ifdef RT_OS_DARWIN 3275 3275 DisableGlobalHotKeys(true); 3276 3276 #endif … … 3292 3292 if (!gfGuestNeedsHostCursor) 3293 3293 SDL_ShowCursor(SDL_ENABLE); 3294 #ifdef __DARWIN__3294 #ifdef RT_OS_DARWIN 3295 3295 DisableGlobalHotKeys(false); 3296 3296 #endif … … 3488 3488 */ 3489 3489 LONG cPercent = 0; 3490 #ifndef __DARWIN__/* don't break the other guys yet. */3490 #ifndef RT_OS_DARWIN /* don't break the other guys yet. */ 3491 3491 for (;;) 3492 3492 { … … 3582 3582 sdlTimer = 0; 3583 3583 3584 #endif /* __DARWIN__*/3584 #endif /* RT_OS_DARWIN */ 3585 3585 3586 3586 /* … … 3817 3817 #endif 3818 3818 3819 #if defined ( __WIN__)3819 #if defined (RT_OS_WINDOWS) 3820 3820 3821 3821 BITMAPV5HEADER bi; … … 3961 3961 ::DeleteObject (hBitmap); 3962 3962 3963 #elif defined ( __LINUX__)3963 #elif defined (RT_OS_LINUX) 3964 3964 3965 3965 XcursorImage *img = XcursorImageCreate (data->width, data->height); … … 4339 4339 } 4340 4340 4341 #ifdef __LINUX__4341 #ifdef RT_OS_LINUX 4342 4342 /** 4343 4343 * Special SDL_PushEvent function for NotifyUpdate events. These events may occur in bursts … … 4364 4364 RTThreadYield(); 4365 4365 } 4366 #endif /* __LINUX__*/4366 #endif /* RT_OS_LINUX */ -
trunk/src/VBox/Frontends/VBoxSDL/VBoxSDL.h
r3289 r3669 24 24 #define __H_VBOXSDL 25 25 26 #ifdef __WIN__/** @todo check why we need to do this on windows. */26 #ifdef RT_OS_WINDOWS /** @todo check why we need to do this on windows. */ 27 27 /* convince SDL to not overload main() */ 28 28 #define _SDL_main_h … … 72 72 #endif /* VBOX_WIN32_UI */ 73 73 74 #ifdef __LINUX__74 #ifdef RT_OS_LINUX 75 75 void PushNotifyUpdateEvent(SDL_Event *event); 76 76 #endif -
trunk/src/VBox/Frontends/VBoxSDL/VBoxSDLTest.cpp
r2981 r3669 21 21 */ 22 22 23 #if defined( __WIN__) ///@todo someone please explain why we don't follow the book!23 #if defined(RT_OS_WINDOWS) ///@todo someone please explain why we don't follow the book! 24 24 # define _SDL_main_h 25 25 #endif … … 38 38 #endif 39 39 40 #ifdef __WIN__40 #ifdef RT_OS_WINDOWS 41 41 #define ESC_NORM 42 42 #define ESC_BOLD … … 92 92 } 93 93 94 #ifdef __WIN__94 #ifdef RT_OS_WINDOWS 95 95 /* Default to DirectX if nothing else set. "windib" would be possible. */ 96 96 if (!getenv("SDL_VIDEODRIVER")) … … 100 100 #endif 101 101 102 #ifdef __WIN__102 #ifdef RT_OS_WINDOWS 103 103 _putenv("SDL_VIDEO_WINDOW_POS=0,0"); 104 104 #else
Note:
See TracChangeset
for help on using the changeset viewer.