Cleaning and small tweaks
This commit is contained in:
parent
19cdcbe7a0
commit
7aa333583d
|
|
@ -3,18 +3,6 @@
|
|||
|
||||
#include "raylib.h"
|
||||
|
||||
using namespace Windows::ApplicationModel::Core;
|
||||
using namespace Windows::ApplicationModel::Activation;
|
||||
using namespace Windows::UI::Core;
|
||||
using namespace Windows::UI::Input;
|
||||
using namespace Windows::Devices::Input;
|
||||
using namespace Windows::Foundation;
|
||||
using namespace Windows::Foundation::Collections;
|
||||
using namespace Windows::Gaming::Input;
|
||||
using namespace Windows::Graphics::Display;
|
||||
using namespace Microsoft::WRL;
|
||||
using namespace Platform;
|
||||
|
||||
using namespace raylibUWP;
|
||||
|
||||
/* OTHER CODE */
|
||||
|
|
|
|||
|
|
@ -66,10 +66,6 @@ TODO list:
|
|||
#define MAX_GAMEPADS 4 // Max number of gamepads supported
|
||||
#define MAX_GAMEPAD_BUTTONS 32 // Max bumber of buttons supported (per gamepad)
|
||||
#define MAX_GAMEPAD_AXIS 8 // Max number of axis supported (per gamepad)
|
||||
//static bool gamepadReady[MAX_GAMEPADS] = { false }; // Flag to know if gamepad is ready
|
||||
//static float gamepadAxisState[MAX_GAMEPADS][MAX_GAMEPAD_AXIS]; // Gamepad axis state
|
||||
//static char previousGamepadState[MAX_GAMEPADS][MAX_GAMEPAD_BUTTONS]; // Previous gamepad buttons state
|
||||
//static char currentGamepadState[MAX_GAMEPADS][MAX_GAMEPAD_BUTTONS]; // Current gamepad buttons state
|
||||
|
||||
//Mouse cursor locking
|
||||
bool cursorLocked = false;
|
||||
|
|
@ -119,11 +115,10 @@ void DisableCursor()
|
|||
cursorLocked = true;
|
||||
}
|
||||
|
||||
namespace raylibUWP
|
||||
//Base app implementation
|
||||
ref class BaseApp : public Windows::ApplicationModel::Core::IFrameworkView
|
||||
{
|
||||
ref class BaseApp : public Windows::ApplicationModel::Core::IFrameworkView
|
||||
{
|
||||
public:
|
||||
public:
|
||||
|
||||
// IFrameworkView Methods.
|
||||
virtual void Initialize(Windows::ApplicationModel::Core::CoreApplicationView^ applicationView)
|
||||
|
|
@ -193,7 +188,7 @@ namespace raylibUWP
|
|||
|
||||
virtual void Uninitialize() {}
|
||||
|
||||
protected:
|
||||
protected:
|
||||
|
||||
// Input polling
|
||||
void PollInput()
|
||||
|
|
@ -359,23 +354,22 @@ namespace raylibUWP
|
|||
UWPRegisterKey((int)args->VirtualKey, 0);
|
||||
}
|
||||
|
||||
private:
|
||||
private:
|
||||
|
||||
bool mWindowClosed = false;
|
||||
bool mWindowVisible = true;
|
||||
|
||||
int width = 800;
|
||||
int height = 450;
|
||||
};
|
||||
};
|
||||
|
||||
|
||||
template<typename AppType>
|
||||
ref class ApplicationSource sealed : Windows::ApplicationModel::Core::IFrameworkViewSource
|
||||
{
|
||||
public:
|
||||
//Application source for creating the program
|
||||
template<typename AppType>
|
||||
ref class ApplicationSource sealed : Windows::ApplicationModel::Core::IFrameworkViewSource
|
||||
{
|
||||
public:
|
||||
virtual Windows::ApplicationModel::Core::IFrameworkView^ CreateView()
|
||||
{
|
||||
return ref new AppType();
|
||||
}
|
||||
};
|
||||
}
|
||||
};
|
||||
Loading…
Reference in New Issue
Block a user