diff options
| author | Marco Lizza <marco.lizza@gmail.com> | 2019-01-10 14:55:19 +0100 |
|---|---|---|
| committer | Marco Lizza <marco.lizza@gmail.com> | 2019-01-10 14:55:19 +0100 |
| commit | a15251bcdbcf5f89af3a5b2189aafcc8444948ab (patch) | |
| tree | 96803613c382551976b73f41dea4195185c88a76 /src/core.c | |
| parent | 5adcc30a2e3984d2df59e228c9360edf47f63c7a (diff) | |
| download | raylib-a15251bcdbcf5f89af3a5b2189aafcc8444948ab.tar.gz raylib-a15251bcdbcf5f89af3a5b2189aafcc8444948ab.zip | |
Adding window visibility functions.
Diffstat (limited to 'src/core.c')
| -rw-r--r-- | src/core.c | 18 |
1 files changed, 18 insertions, 0 deletions
@@ -831,6 +831,24 @@ void SetWindowSize(int width, int height) #endif } +// Set window visibility +void SetWindowVisible(bool visible) +{ +#if defined(PLATFORM_DESKTOP) + if (visible) glfwShowWindow(window); + else glfwHideWindow(window); +#endif +} + +// Set window visibility +bool IsWindowVisible() +{ +#if defined(PLATFORM_DESKTOP) + return glfwGetWindowAttrib(window, GLFW_VISIBLE) != GL_FALSE; +#endif + return true; +} + // Get current screen width int GetScreenWidth(void) { |
