2023-01-25 09:47:19 -06:00
|
|
|
#pragma once
|
|
|
|
#include "common/String.h"
|
|
|
|
#include "graphics/Pixel.h"
|
2023-10-04 08:51:39 -05:00
|
|
|
#include "gui/WindowFrameOps.h"
|
2023-02-12 06:58:54 -06:00
|
|
|
#include "FpsLimit.h"
|
2023-01-25 09:47:19 -06:00
|
|
|
#include <cstdint>
|
|
|
|
#include <SDL.h>
|
2023-02-12 06:58:54 -06:00
|
|
|
#include <variant>
|
2023-01-25 09:47:19 -06:00
|
|
|
|
|
|
|
extern int desktopWidth;
|
|
|
|
extern int desktopHeight;
|
|
|
|
extern SDL_Window *sdl_window;
|
|
|
|
extern SDL_Renderer *sdl_renderer;
|
|
|
|
extern SDL_Texture *sdl_texture;
|
|
|
|
extern bool momentumScroll;
|
|
|
|
extern bool showAvatars;
|
|
|
|
extern uint64_t lastTick;
|
|
|
|
extern uint64_t lastFpsUpdate;
|
|
|
|
extern bool showLargeScreenDialog;
|
|
|
|
extern int mousex;
|
|
|
|
extern int mousey;
|
|
|
|
extern int mouseButton;
|
|
|
|
extern bool mouseDown;
|
|
|
|
extern bool calculatedInitialMouse;
|
|
|
|
extern bool hasMouseMoved;
|
|
|
|
|
2023-02-12 06:32:05 -06:00
|
|
|
void MainLoop();
|
2023-01-25 09:47:19 -06:00
|
|
|
void EngineProcess();
|
|
|
|
void StartTextInput();
|
|
|
|
void StopTextInput();
|
|
|
|
void SetTextInputRect(int x, int y, int w, int h);
|
|
|
|
void ClipboardPush(ByteString text);
|
|
|
|
ByteString ClipboardPull();
|
|
|
|
int GetModifiers();
|
|
|
|
unsigned int GetTicks();
|
|
|
|
void blit(pixel *vid);
|
|
|
|
void SDLOpen();
|
2023-01-26 04:38:17 -06:00
|
|
|
void SDLClose();
|
2023-10-05 12:42:20 -05:00
|
|
|
void SDLSetScreen();
|
2023-02-12 06:58:54 -06:00
|
|
|
void SetFpsLimit(FpsLimit newFpsLimit);
|
2023-01-25 09:47:19 -06:00
|
|
|
void LoadWindowPosition();
|
|
|
|
void SaveWindowPosition();
|
|
|
|
void LargeScreenDialog();
|
|
|
|
void TickClient();
|
2023-06-27 03:56:16 -05:00
|
|
|
void UpdateFpsLimit();
|