Hajime Hoshi
4580f9fa16
internal/uidriver/glfw: Refactring: Rename InDP -> InDIP
...
This change also renames some functions and variables.
2021-10-10 15:47:15 +09:00
Hajime Hoshi
fcd8a6c653
internal/uidriver/glfw: Bug fix: Get the correct initial monitor and its scale
...
Before this fix, Win32API is used to get the current monitor. This
might not work and return an unexpected monitor on some machines after
the runloop starts.
Instead, use the current window to get the current monitor correctly
instead of the Win32APIs. To get the initial monitor, the API
ForegroundWindow is still used.
Updates #1584
Updates #1844
2021-10-09 18:18:22 +09:00
Hajime Hoshi
77664ff057
internal/uidriver/glfw: Use the correct initial monitor on Linux/UNIX
...
Closes #1827
2021-09-25 02:48:13 +09:00
Hajime Hoshi
188e80d2f7
internal/uidriver/glfw: Bug fix: FPS is dropped when pressing the green button
...
Updates #1745
2021-09-18 22:16:21 +09:00
Hajime Hoshi
428c079e52
internal/uidriver/glfw: Make a 'native' fullscreen on macOS
...
This is a breaking change. On macOS, `SetFullscreen` creates a new
independent space and maximize the size of the window there.
Updates #1506
Closes #1579
2021-09-18 16:31:22 +09:00
divVerent
5bc7b93e6f
Move VideoModeScaleAt into internal/uidriver/glfw. ( #1812 )
...
It's only used by GLFW, and has been in devicescale only to ease migration
to separate video mode vs content scaling.
Updates #1774
2021-09-15 12:47:04 +09:00
divVerent
923c84a3d6
Split the concept of device scale and screen scale ( #1811 )
...
We now set deviceScale to always the mapping from logical window system pixels
to device independent pixels (which is what Ebiten API users expect), and
introduce a new concept of videoModeScale that maps from video mode to logical
window system pixels.
videoModeScale is now only used for computing full-screen resolutions, while
deviceScale is used for any other conversion.
Fixes window sizes on X11, should be a NOP otherwise.
Closes #1774 .
2021-09-15 01:03:04 +09:00
Hajime Hoshi
106ff7a84b
internal/ui: Reduce calls of glfw.GetMonitors
...
Updates #1803
2021-09-09 11:14:08 +09:00
Tom Lister
bea5ab3335
internal/uidriver/glfw: Native macOS implementation for setting cursor shape ( #1624 )
...
Updates #1624
2021-05-02 14:50:50 +09:00
Hajime Hoshi
26432dfc9e
Revert "internal/uidriver/glfw: Refactoring: use glfw.Window when possible"
...
This reverts commit 475453d5d2
.
Reason: #1584 : A wrong active monitor was detected at the initial phase?
Closes #1584
2021-04-18 20:05:37 +09:00
Hajime Hoshi
78732d93f6
internal/uidriver/glfw: Bug fix: Crash on some operations on native fullscreen mode (macOS)
...
This change forbids some operations when the wiindow is natively
fullscreened on macOS in order to avoid crashes.
Closes #1578
2021-04-18 18:11:33 +09:00
Hajime Hoshi
475453d5d2
internal/uidriver/glfw: Refactoring: use glfw.Window when possible
...
Updates #1122
2021-04-03 17:29:38 +09:00
Hajime Hoshi
ec912e5cad
internal/uidriver/glfw: Remove the dirty hack creating a temporary UI instance
...
Updates #1122
2021-02-11 03:45:39 +09:00
Hajime Hoshi
7a0e31a23a
Clean up the 'js' build tags
...
Updates #1129
2020-10-07 01:33:10 +09:00
Hajime Hoshi
bf515bb594
Update version to v2.0.0-alpha
2020-10-04 04:30:40 +09:00
Hajime Hoshi
28ce1fc3fb
uidriver/glfw: Bug fix: Compile failure
2020-09-19 01:32:33 +09:00
Hajime Hoshi
40e35fa047
uidriver/glfw: Bug fix: Unscale the size for framebuffers on Linux/UNIX
...
Fixes #1307
2020-09-19 01:04:18 +09:00
Hajime Hoshi
97607f5779
graphicsdriver/glfw: Bug fix: Convert window size unit correctly on Linux/UNIX
...
Updates #1307
2020-09-19 00:31:34 +09:00
Hajime Hoshi
5278a7c6d6
uidriver/glfw: Bug fix: Use the correct scale for GLFW APIs on Linux/UNIX
...
Updates #1307
2020-09-19 00:21:10 +09:00
Hajime Hoshi
a3b41515a9
ui: Replace the native window's type (unsafe.Pointer) with uintptr
...
Updates #1306
2020-09-04 00:51:48 +09:00
Hajime Hoshi
12e5617396
uidriver/glfw: Update comments
2020-08-24 04:07:08 +09:00
Hajime Hoshi
932d599c98
uidriver/glfw: Bug fix compilation failure on macOS and Windows
2020-08-24 03:31:46 +09:00
Hajime Hoshi
a7d234e3c8
uidriver/glfw: Refactoring: make currentMonitorByOS more explicit
2020-08-24 03:27:38 +09:00
Hajime Hoshi
9bff1c79be
uidriver/glfw: Refactoring
2020-08-24 03:05:38 +09:00
Hajime Hoshi
ed3a4a734e
uidriver/glfw: Refactoring
2020-08-24 00:34:57 +09:00
Hajime Hoshi
07480ed66d
uidriver/glfw: Add better fallbacks for currentMonitorFromPosition
...
Updates #1119
2020-08-23 23:38:03 +09:00
Hajime Hoshi
10d6a3ad67
uidriver/glfw: Bug fix: Crash on Wine when getting a monitor
2020-08-23 02:31:52 +09:00
Hajime Hoshi
b7ab3d2df4
uidriver/glfw: Avoid using the window position before initializing
...
Especially in the initial phase before calling Run/RunGame, the
window position is not reliable and then getting the device scale
factor does not make sense based on the window position. Avoid
using the window position, and instead use the glfw.Monitor in
this situation.
2020-03-29 00:09:08 +09:00
Hajime Hoshi
8cca713d74
uidriver/glfw: Bug fix: adjustWindowPosition should consider the monitor position
2020-03-28 21:26:57 +09:00
Hajime Hoshi
7d403930af
uidriver/glfw: Bug fix: Compile errors on Windows and Linux
2019-12-08 23:20:09 +09:00
Hajime Hoshi
a0cf8bac21
uidriver/glfw: Refactoring: Limit the calls of devicescale.GetAt
2019-12-08 20:55:40 +09:00
Hajime Hoshi
a040aae83b
glfw: Update to GLFW 3.3
...
Fixes #1000
2019-11-26 01:19:20 +09:00
Hajime Hoshi
7e5085f15b
Add uidriver package and move UI implementation to this packaage
2019-04-07 18:21:16 +09:00