mirror of
https://github.com/TorqueGameEngines/Torque3D.git
synced 2026-03-09 07:20:40 +00:00
Changes to have Linux dedicated compiling again
This commit is contained in:
parent
517b93866a
commit
c5c08e72d2
7 changed files with 25 additions and 25 deletions
|
|
@ -40,7 +40,7 @@
|
|||
#include "platformX86UNIX/x86UNIXOGLVideo.h"
|
||||
#include "platformX86UNIX/x86UNIXState.h"
|
||||
|
||||
#ifndef DEDICATED
|
||||
#ifndef TORQUE_DEDICATED
|
||||
#include "platformX86UNIX/x86UNIXMessageBox.h"
|
||||
#include "platformX86UNIX/x86UNIXInputManager.h"
|
||||
#endif
|
||||
|
|
@ -51,7 +51,7 @@
|
|||
#include <unistd.h> // fork, execvp, chdir
|
||||
#include <time.h> // nanosleep
|
||||
|
||||
#ifndef DEDICATED
|
||||
#ifndef TORQUE_DEDICATED
|
||||
#include <X11/Xlib.h>
|
||||
#include <X11/Xos.h>
|
||||
|
||||
|
|
@ -69,7 +69,7 @@ LockFunc_t DisplayPtrManager::sgUnlockFunc = NULL;
|
|||
static U32 lastTimeTick;
|
||||
static MRandomLCG sgPlatRandom;
|
||||
|
||||
#ifndef DEDICATED
|
||||
#ifndef TORQUE_DEDICATED
|
||||
extern void InstallRedBookDevices();
|
||||
extern void PollRedbookDevices();
|
||||
extern bool InitOpenGL();
|
||||
|
|
@ -149,7 +149,7 @@ static S32 ParseCommandLine(S32 argc, const char **argv,
|
|||
|
||||
static void DetectWindowingSystem()
|
||||
{
|
||||
#ifndef DEDICATED
|
||||
#ifndef TORQUE_DEDICATED
|
||||
Display* dpy = XOpenDisplay(NULL);
|
||||
if (dpy != NULL)
|
||||
{
|
||||
|
|
@ -166,7 +166,7 @@ static void InitWindow(const Point2I &initialSize, const char *name)
|
|||
x86UNIXState->setWindowName(name);
|
||||
}
|
||||
|
||||
#ifndef DEDICATED
|
||||
#ifndef TORQUE_DEDICATED
|
||||
//------------------------------------------------------------------------------
|
||||
static bool InitSDL()
|
||||
{
|
||||
|
|
@ -376,7 +376,7 @@ static inline void Sleep(int secs, int nanoSecs)
|
|||
nanosleep(&sleeptime, NULL);
|
||||
}
|
||||
|
||||
#ifndef DEDICATED
|
||||
#ifndef TORQUE_DEDICATED
|
||||
struct AlertWinState
|
||||
{
|
||||
bool fullScreen;
|
||||
|
|
@ -436,7 +436,7 @@ static inline void AlertEnableVideo(AlertWinState& state)
|
|||
//------------------------------------------------------------------------------
|
||||
void Platform::AlertOK(const char *windowTitle, const char *message)
|
||||
{
|
||||
#ifndef DEDICATED
|
||||
#ifndef TORQUE_DEDICATED
|
||||
if (x86UNIXState->isXWindowsRunning())
|
||||
{
|
||||
AlertWinState state;
|
||||
|
|
@ -461,7 +461,7 @@ void Platform::AlertOK(const char *windowTitle, const char *message)
|
|||
//------------------------------------------------------------------------------
|
||||
bool Platform::AlertOKCancel(const char *windowTitle, const char *message)
|
||||
{
|
||||
#ifndef DEDICATED
|
||||
#ifndef TORQUE_DEDICATED
|
||||
if (x86UNIXState->isXWindowsRunning())
|
||||
{
|
||||
AlertWinState state;
|
||||
|
|
@ -489,7 +489,7 @@ bool Platform::AlertOKCancel(const char *windowTitle, const char *message)
|
|||
//------------------------------------------------------------------------------
|
||||
bool Platform::AlertRetry(const char *windowTitle, const char *message)
|
||||
{
|
||||
#ifndef DEDICATED
|
||||
#ifndef TORQUE_DEDICATED
|
||||
if (x86UNIXState->isXWindowsRunning())
|
||||
{
|
||||
AlertWinState state;
|
||||
|
|
@ -524,7 +524,7 @@ bool Platform::excludeOtherInstances(const char *mutexName)
|
|||
//------------------------------------------------------------------------------
|
||||
void Platform::enableKeyboardTranslation(void)
|
||||
{
|
||||
#ifndef DEDICATED
|
||||
#ifndef TORQUE_DEDICATED
|
||||
// JMQ: not sure if this is needed for i18n keyboards
|
||||
//SDL_EnableUNICODE( 1 );
|
||||
// SDL_EnableKeyRepeat(
|
||||
|
|
@ -536,7 +536,7 @@ void Platform::enableKeyboardTranslation(void)
|
|||
//------------------------------------------------------------------------------
|
||||
void Platform::disableKeyboardTranslation(void)
|
||||
{
|
||||
#ifndef DEDICATED
|
||||
#ifndef TORQUE_DEDICATED
|
||||
//SDL_EnableUNICODE( 0 );
|
||||
// SDL_EnableKeyRepeat(0, 0);
|
||||
#endif
|
||||
|
|
@ -545,7 +545,7 @@ void Platform::disableKeyboardTranslation(void)
|
|||
//------------------------------------------------------------------------------
|
||||
void Platform::setWindowLocked(bool locked)
|
||||
{
|
||||
#ifndef DEDICATED
|
||||
#ifndef TORQUE_DEDICATED
|
||||
x86UNIXState->setWindowLocked(locked);
|
||||
|
||||
UInputManager* uInputManager =
|
||||
|
|
@ -560,7 +560,7 @@ void Platform::setWindowLocked(bool locked)
|
|||
//------------------------------------------------------------------------------
|
||||
void Platform::minimizeWindow()
|
||||
{
|
||||
#ifndef DEDICATED
|
||||
#ifndef TORQUE_DEDICATED
|
||||
if (x86UNIXState->windowCreated())
|
||||
SDL_WM_IconifyWindow();
|
||||
#endif
|
||||
|
|
@ -574,7 +574,7 @@ void Platform::process()
|
|||
|
||||
if (x86UNIXState->windowCreated())
|
||||
{
|
||||
#ifndef DEDICATED
|
||||
#ifndef TORQUE_DEDICATED
|
||||
// process window events
|
||||
PROFILE_START(XUX_ProcessMessages);
|
||||
bool quit = !ProcessMessages();
|
||||
|
|
@ -622,7 +622,7 @@ void Platform::process()
|
|||
}
|
||||
}
|
||||
|
||||
#ifndef DEDICATED
|
||||
#ifndef TORQUE_DEDICATED
|
||||
#if 0
|
||||
// JMQ: disabled this because it may fire mistakenly in some configurations.
|
||||
// sdl's default event handling scheme should be enough.
|
||||
|
|
@ -665,7 +665,7 @@ void Platform::setWindowSize( U32 newWidth, U32 newHeight )
|
|||
//------------------------------------------------------------------------------
|
||||
void Platform::initWindow(const Point2I &initialSize, const char *name)
|
||||
{
|
||||
#ifndef DEDICATED
|
||||
#ifndef TORQUE_DEDICATED
|
||||
// initialize window
|
||||
InitWindow(initialSize, name);
|
||||
if (!InitOpenGL())
|
||||
|
|
@ -825,7 +825,7 @@ int main(S32 argc, const char **argv)
|
|||
|
||||
void Platform::setWindowTitle( const char* title )
|
||||
{
|
||||
#ifndef DEDICATED
|
||||
#ifndef TORQUE_DEDICATED
|
||||
x86UNIXState->setWindowName(title);
|
||||
SDL_WM_SetCaption(x86UNIXState->getWindowName(), NULL);
|
||||
#endif
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue