Commit Graph

1591 Commits

Author SHA1 Message Date
bruvzg 35b4a1f374
[Windows] Emit native file dialog callback from event loop, fix selected options not saved.
(cherry picked from commit ea252675aa)
2024-09-17 08:57:46 +02:00
bruvzg 4944d59198
[Windows] Run native file dialogs in thread to make it non-blocking.
(cherry picked from commit 66832e9968)
2024-09-17 08:57:46 +02:00
bruvzg b1c1c40250
[Windows] Use the same API for all `OS_Windows::*_environment` functions.
(cherry picked from commit 319bfa9965)
2024-09-17 08:57:43 +02:00
David Snopek 19843328d9
GDExtension: Show warning on missing PDB file, rather than error
(cherry picked from commit 760099ca6f)
2024-09-17 08:57:42 +02:00
David Snopek 9946eba398
Windows: Call `AddDllDirectory()` with an absolute path
(cherry picked from commit e8bd385f53)
2024-09-16 17:24:05 +02:00
bruvzg b6055941b9
[Windows] Hide cursor before moving.
(cherry picked from commit 9a2977fef1)
2024-09-16 17:20:22 +02:00
Hilderin 8496e0738f
Fix drag&drop between window on Windows
(cherry picked from commit 0987a9dc06)
2024-09-16 17:12:26 +02:00
Joel Croteau 6e78eec37f
Fix reload of GDExtension libraries in framework package on macos
`GDExtension::open_library` has a check in it to see if the library was loaded
from a temp file, and if it was to restore the original name as that is the one
we actually care about. This check is breaking extension reloading on Mac when
the library path is to a framework folder, as the file inside the framework
will not generally be the same name as the folder.

This check also shouldn't be necessary even on Windows, which is the only
platform that uses `generate_temp_files`, since disposal of the created temp
file is handled within `OS_Windows::open_dynamic_library`, and
`GDExtension::open_library` (which is the only function to call
`open_dynamic_library` with a `p_data` argument) only cares about the original
library file path and has to do extra work to remove the name of the temp file.
Instead, I have removed that check and set `OS_Windows::open_dynamic_library`
to return the name of the original file and not the name of the copy.

This fixes GDExtension reloading on macOS. I do not have a Windows machine
available to test that it still works properly on Windows, so someone should
check that before merging this.

(cherry picked from commit f44d6a235f)
2024-09-16 16:55:39 +02:00
Alvin Wong 16a563b9ac DisplayServerWindows: Fix logic when creating with transient parent 2024-08-15 04:10:15 +08:00
Rémi Verschelde e693ff814a
Merge pull request #95155 from bruvzg/win_pen_checks
[Windows] Reject `WM_POINTER(UP/DOWN)` messages for non pen pointer type.
2024-08-06 12:32:02 +02:00
bruvzg e5efde9481
[Windows] Reject WM_POINTER(UP/DOWN) messages for non pen pointer type. 2024-08-04 20:07:14 +03:00
bruvzg 27474c9563
[Windows] Check if transparency is enabled in the project setting before applying DWM blur. 2024-08-01 10:30:46 +03:00
Rémi Verschelde 1d57b81d26
Merge pull request #94976 from bruvzg/win_app_name
[Windows] Improve editor grouping, set friendly name registry key for exported projects.
2024-07-31 16:13:21 +02:00
bruvzg 3f8cc6678b [Windows] Improve editor grouping, set friendly name registry key for exported projects. 2024-07-31 15:04:00 +03:00
Rémi Verschelde 3fce516155
Merge pull request #94428 from alvinhochun/windows-angle-resize-sync
Windows: Update ANGLE surface size when window is resized
2024-07-31 11:37:37 +02:00
bruvzg ad0ab2f396
[Windows] Improve OpenGL/ANGLE switching on ARM64. 2024-07-30 10:11:58 +03:00
Rémi Verschelde 9a8f18b9bf
Merge pull request #94796 from kus04e4ek/backfall
Windows: Fall back to D3D12 if Vulkan is not supported and vice versa
2024-07-29 15:17:26 +02:00
bruvzg 5d5d51937f [Windows] Remove libSynchronization 2024-07-27 17:12:27 +03:00
Kusok d30c1e6a8f Fall back to D3D12 if Vulkan is not supported and vice versa 2024-07-27 16:17:20 +08:00
Rémi Verschelde 44342c385c
Merge pull request #94735 from aitorciki/nvdrs-memset-initialization
[Windows] Use default aggregate initialization for NVAPI settings
2024-07-26 13:44:13 +02:00
Aitor Guevara 21f3e69a24 [Windows] Use default aggregate initialization for NVAPI settings
Using the member initialization encouraged in NVAPI documentation for
NVDRS_SETTING results in builds enabling `dev_mode` breaking. Default
aggregate initialization results in a clean build though.
2024-07-25 14:41:46 +02:00
Alvin Wong 97aa278edb Pass window exclusive and transient properties for subwindow creation
On Windows this allows to avoid having to change the owner of the window
after it has been created, which in rare circumstances may cause the
window to bug out.
2024-07-25 00:27:27 +08:00
bruvzg 52a2836861 Disable FP contraction. 2024-07-23 14:33:51 +03:00
Rémi Verschelde a50fe87b89
Merge pull request #94078 from Repiteo/scons/msvc-flag-fix
SCons: Don't override cl flags on msvc
2024-07-22 14:12:45 +02:00
bruvzg 0e519118d2 [Windows] Fix release export template build for ARM64 Windows. 2024-07-19 14:33:40 +03:00
Rémi Verschelde 18da250ffb
Merge pull request #93737 from aitorciki/disable-windowed-gsync
[Windows] Disable G-SYNC in windowed mode
2024-07-19 11:10:31 +02:00
Rémi Verschelde 287521c2c2
Merge pull request #94466 from bruvzg/angle_update_lib
[Windows] Add `libSynchronization` to link flags.
2024-07-18 10:45:40 +02:00
Rémi Verschelde ea018a8131
Merge pull request #94120 from bruvzg/fix_kbd_names
[Windows] Fix reading keyboard layout names.
2024-07-17 15:44:50 +02:00
Rémi Verschelde 1ca4ce284e
Merge pull request #94063 from bruvzg/tablet_drag
[Winink] Check pointer button states.
2024-07-17 15:44:47 +02:00
bruvzg 9f714bfde5 [Windows] Add `libSynchronization` to link flags. 2024-07-17 10:58:03 +03:00
Alvin Wong a1a0acff7c Windows: Update ANGLE surface size when window is resized
ANGLE needs to be told to resize the DXGI swap chain using
`eglWaitNative`. Otherwise the resize will only happen in
`eglSwapBuffers`, which causes some janky stretching during window
resize.
2024-07-16 17:01:42 +08:00
Alvin Wong d7f023ab73 Windows: Do not attempt to resize surface before it is created
`WM_WINDOWPOSCHANGED` may be received before `CreateWindowExW` has even
returned, when the window's rendering context or OpenGL context hasn't
been created yet.
2024-07-16 17:01:42 +08:00
Alvin Wong 1d542257e5 Windows: Fix wrong initial size passed to rendering driver 2024-07-16 03:30:44 +08:00
bruvzg 3afe1e7481 [Winink] Check pointer button states, fix drag and double-click. 2024-07-15 12:23:07 +03:00
Rémi Verschelde 1aa1a1879d
Merge pull request #94203 from RandomShaper/bye_bye_dxil_dll
D3D12: Get rid of `DXIL.dll`!
2024-07-11 23:16:59 +02:00
Rémi Verschelde 6c2699cbf6
Merge pull request #94187 from akien-mga/windows-remove-unused-is_wow64
Remove unused `is_wow64` method in `OS_Windows`
2024-07-11 23:16:54 +02:00
Rémi Verschelde c349f0d6a7
Remove unused `is_wow64` method in `OS_Windows`
It was added in b4d369c88 for `get_processor_count`, but this was later
changed to rely on `std::thread` in 6bf02c016.
2024-07-11 23:16:12 +02:00
Pedro J. Estébanez ee2c1584e4 D3D12: Get rid of DXIL.dll! 2024-07-11 17:56:45 +02:00
Rémi Verschelde 1b49d6393d
Merge pull request #93733 from alvinhochun/windows-restore-sizing
Windows: Restore to windowed mode using `SW_NORMAL`
2024-07-11 09:40:58 +02:00
bruvzg fea8ab0999 [Windows] Fix reading keyboard layout names. 2024-07-09 11:46:06 +03:00
Rémi Verschelde 3220b6fb11
Merge pull request #93976 from Hilderin/fix-caret-disappear-from-script-editor
Fix caret can disappear from script editor
2024-07-08 19:13:31 +02:00
Thaddeus Crews 0f691efb1b
SCons: Don't override cl flags on msvc 2024-07-08 09:48:18 -05:00
Hilderin ebd1ab646c Fix caret can disappear from script editor 2024-07-08 07:11:17 -04:00
Rémi Verschelde ec02d406ca
Merge pull request #94067 from RandomShaper/fix_build
Windows: Fix build error due to missing definition of Texture2D
2024-07-08 11:48:36 +02:00
Pedro J. Estébanez 50bf2e5b37 Windows: Fix build error due to missing definition of Texture2D 2024-07-08 10:40:17 +02:00
bruvzg eddc9cea11
[NativeMenu] Do not auto toggle check/multi-state items. Add `is_native_menu` method. 2024-07-08 11:20:28 +03:00
Rémi Verschelde abfce31ba7
Merge pull request #93152 from RandomShaper/prebuilt_asan
Enable usage of asan-enabled versions of prebuilt libraries
2024-07-02 17:27:31 +02:00
Aitor Guevara b8edc64379 [Windows] Disable G-SYNC in windowed mode
G-SYNC (NVIDIA's VRR) is known to be buggy on windowed mode in Windows.
While the driver only enables G-SYNC for full screen mode by default,
users can toggle it on for windowed mode too, resulting in unstable
refresh rates during Editor usage.
This patch extends Godot's NVIDIA profile to force the default full
screen mode only G-SYNC with Godot.
2024-06-29 13:40:15 +02:00
Alvin Wong c54477b7e6 Windows: Restore to windowed mode using SW_NORMAL
If window was maximized before minimizing, restoring the window
afterwards using SW_RESTORE seems to cause the window to forget its
original size and position before being maximized, causing the window to
fill the screen instead.
2024-06-29 18:24:45 +08:00
Pedro J. Estébanez 32d9c93af3 Improve handling of rendering startup errors 2024-06-28 19:31:50 +02:00