Files
XCEngine/engine/include/XCEngine/Platform/Window.h

40 lines
953 B
C++

#pragma once
#include "PlatformTypes.h"
namespace XCEngine {
namespace Input {
class InputModule;
}
namespace Platform {
class Window {
public:
virtual ~Window() = default;
virtual bool Create(const WindowDesc& desc) = 0;
virtual void Destroy() = 0;
virtual WindowHandle GetHandle() const = 0;
virtual void PumpEvents() = 0;
virtual void SetTitle(const Containers::String& title) = 0;
virtual void SetFullscreen(bool fullscreen) = 0;
virtual bool IsFullscreen() const = 0;
virtual void Minimize() = 0;
virtual void Maximize() = 0;
virtual void Restore() = 0;
virtual bool ShouldClose() const = 0;
virtual void* GetNativeHandle() = 0;
void SetInputModule(Input::InputModule* module);
Input::InputModule* GetInputModule() const { return m_inputModule; }
protected:
Input::InputModule* m_inputModule = nullptr;
};
} // namespace Platform
} // namespace XCEngine