Kirill Chibisov
c48116a8fd
Implement AsFd/AsRawFd for EventLoop<T>
...
This should help other crates to integrate winit's event loop into
their bigger event loop without adding an extra thread.
2023-10-15 20:31:29 +04:00
John Nunley
b938fe9df5
Fix potentially unaligned references in X11 device
...
Fixes #3125
Signed-off-by: John Nunley <dev@notgull.net>
2023-10-15 07:09:10 +04:00
Kirill Chibisov
b7e3649e8b
Update SCTK to 0.18.0
...
The update is pretty minor, however we support now
`WindowEvent::Occluded` when xdg-shell v6 is available.
It also adds support for `Window::show_window_menu`.
Fixes #2927 .
2023-10-15 06:49:57 +04:00
Kirill Chibisov
844269d017
Fix ndk deps versions
2023-10-15 06:39:18 +04:00
John Nunley
e41fac825c
Update to new raw-window-handle strategy
...
Signed-off-by: John Nunley <dev@notgull.net>
Co-authored-by: TornaxO7 <tornax@proton.me>
2023-10-15 06:07:39 +04:00
Ryan Hileman
bbeacc46d5
feat: Implement set_cursor_hittest for X11
2023-10-13 20:42:07 -07:00
Kirill Chibisov
61581ebb4f
Fix CHANGELOG entry for Event::MemoryWarning
...
While the changelog entries for beta releases doesn't really matter. The
change wasn't marked as breaking, while it is.
Fixes: 93f1000a0 (Add Occluded and MemoryWarning events for iOS/Android)
2023-10-13 02:02:00 +04:00
François
93f1000a05
Add Occluded and MemoryWarning events for iOS/Android
...
Hook `Occluded` event to foreground/background evens on iOS.
This commit also enabled the `MemoryWarning` event, since it's
emitted from the windowing system.
Co-authored-by: Dusty DeWeese <dustin.deweese@gmail.com>
Co-authored-by: Kirill Chibisov <contact@kchibisov.com>
2023-10-13 00:42:09 +04:00
YouKnow
1ea41a2ee2
Add Window::show_window_menu
...
Add a method to request a system menu. The implementation
is provided only on Windows for now.
Co-authored-by: daxpedda <daxpedda@gmail.com>
Co-authored-by: Kirill Chibisov <contact@kchibisov.com>
2023-10-11 01:46:16 +04:00
daxpedda
42c9b7e40e
Fix reset to Poll after the event loop starts
2023-10-11 00:46:08 +04:00
baneyue
0960635895
On Wayland, fix MonitorHandle position
2023-10-11 00:44:52 +04:00
Kirill Chibisov
789a497980
Remove obsolete docs about wayland CSD env variable
...
The env variable was removed a while ago, yet it was still present in
the user docs.
2023-10-10 09:23:37 +04:00
daxpedda
fac6110cb6
Web: fix ControlFlow::WaitUntil to never wake up **before** the given time ( #3133 )
2023-10-09 12:31:02 +02:00
Dmitry Sharshakov
0363be4776
Add Window::set_blur
...
Allow clients to request blur behind their window, implemented on
Wayland for now.
2023-10-08 23:53:15 +04:00
daxpedda
f5dd1c008c
Web: remove unnecessary usage of once_cell::unsync::Lazy ( #3134 )
2023-10-08 02:00:51 +02:00
daxpedda
48a1e84906
Update Clippy to v1.73 ( #3135 )
2023-10-08 01:21:46 +02:00
epimeletes
ee0db52ac4
Rename run_ondemand to run_on_demand
2023-10-04 01:24:42 +04:00
Fredrik Fornwall
c7cf0cfd83
Make DeviceId contain device id's on Android
2023-10-04 01:23:18 +04:00
Mads Marquart
8393d98940
Link to areweguiyet.com and arewegameyet.rs for extra deps
2023-10-04 01:22:14 +04:00
Mads Marquart
af247eac0f
X11: Add #[deny(unsafe_op_in_unsafe_fn)] ( #3121 )
...
* X11: Add #[deny(unsafe_op_in_unsafe_fn)]
* Enable #![deny(unsafe_op_in_unsafe_fn)] everywhere
2023-09-30 21:43:41 +02:00
Mads Marquart
b2b4564a5f
Windows: Add #[deny(unsafe_op_in_unsafe_fn)] ( #3070 )
2023-09-29 16:07:44 +02:00
Mads Marquart
cb58c49a90
Bump version on master ( #3119 )
...
This commit does not represent a release and only synchronizes CHANGELOG from the latest release.
2023-09-28 01:03:38 +02:00
Neil Macneale V
ffb46dd61f
Fix transparent windows on X11
2023-09-26 01:05:15 +04:00
Kirill Chibisov
8c8fb39fcd
Remove DeviceEvent::Text event
...
The event is never constructed inside the winit.
2023-09-23 18:40:23 +04:00
lucasmerlin
2422ea39d0
Pass force on touch events on android
2023-09-22 23:44:39 +04:00
daxpedda
878d832d24
Make ControlFlow::Wait the default ( #3106 )
2023-09-22 21:27:11 +02:00
Kirill Chibisov
e2e01e1fc6
Remove old docs about EventLoop::run
2023-09-22 13:46:52 +04:00
Pavel Strakhov
c8b685ddbc
On X11, fix WaitUntil and Poll behavior
...
Co-authored-by: Kirill Chibisov <contact@kchibisov.com>
2023-09-20 15:15:28 +04:00
StarStarJ
f10ae52385
Implement PartialOrd and Ord for MouseButton
2023-09-17 13:51:03 +04:00
Kirill Chibisov
e731041c15
Correct Wayland section in dpi docs
...
Fixes #3100 .
2023-09-16 18:14:46 +04:00
daxpedda
9df7fc47a1
Install cargo-apk with the stable toolchain
2023-09-16 16:17:53 +04:00
daxpedda
992aeb0ca0
Ignore foreign-types* duplicate deps on macOS
...
The dependency is duplicated due to examples, yet we still need to
exclude checking it.
Fixes #3093 .
2023-09-16 14:54:49 +04:00
daxpedda
0caba93b51
Rename PollType to PollStrategy ( #3089 )
2023-09-08 18:39:23 +02:00
John Nunley
c00c1e9eb7
Add an MSRV policy to the README ( #3046 )
2023-09-08 17:34:55 +02:00
daxpedda
83950acd5a
Add Window.requestIdleCallback() support ( #3084 )
2023-09-07 12:12:35 +02:00
Fredrik Fornwall
b99403b1b9
Correct set_exit() -> exit() in the changelog ( #3088 )
2023-09-07 11:52:53 +02:00
John Nunley
4f0ce7201d
Revert select_xkb_events to its previous impl
...
The new implementation of select_xkb_events apparently misconfigures
the server. This commit does a temporary fix by just reverting it to its
previous implementation.
This is temporary until I can figure out what Xlib is doing behind the
scenes or until I read xkbproto.pdf.
Fixes : #3079
Signed-off-by: John Nunley <dev@notgull.net>
2023-09-07 10:25:52 +04:00
daxpedda
e648169861
Move ControlFlow to EventLoopWindowTarget
...
Fixes #3042 .
2023-09-07 10:25:04 +04:00
John Nunley
8fdd81ecef
Allow the user to force X11 under Wayland
...
Use forced backend over the env variables.
Signed-off-by: John Nunley <dev@notgull.net>
Fixes : #3057
2023-09-04 01:24:05 +04:00
daxpedda
7a2a2341c2
Remove T from EventLoopTargetWindow ( #3081 )
...
Co-authored-by: nerditation <12248559+nerditation@users.noreply.github.com>
2023-09-03 02:26:53 +02:00
Kirill Chibisov
d68d9eab38
Mark startup_notify unsafe functions as safe
...
They are safe, since they use the rust `std::env` stuff. Making them
safe lets downstream to determine that `std::env` is used and not the
`libc` env manipulation routines, which are unsafe.
2023-09-02 02:05:56 +04:00
Mads Marquart
a06ea45c0f
Slightly reduce number of cfgs ( #3071 )
...
* Make Linux platforms less dependent on the root monitor handle
* Add various functions to the Wayland platform to reduce cfgs
* Don't use a cfg in listen_device_events
* Don't use a cfg in set_content_protected
* Fix instance of a target_os cfg
2023-09-01 23:14:16 +02:00
Kirill Chibisov
67b041e231
On Wayland, fix TouchPhase::Canceled sent for Move
...
Fixes #3035 .
2023-09-01 02:14:34 +04:00
Mads Marquart
6dfc78fb50
Make EventLoopWindowTarget independent of the user type on Orbital ( #3055 )
2023-08-30 16:43:28 +02:00
Mads Marquart
477619c0a7
Ensure that winit initializes NSApplication ( #3069 )
2023-08-30 15:19:30 +02:00
Mads Marquart
5f1a4b65ad
Fix missing quote ( #3068 )
2023-08-30 13:59:23 +02:00
John Nunley
bb9b629bc3
Implement X11 extensions using x11rb instead of Xlib
...
Removes Xlib code by replacing it with the x11rb equivalent,
the commit handles xrandr, xinput, xinput2, and xkb.
Signed-off-by: John Nunley <dev@notgull.net>
2023-08-30 01:01:25 +04:00
daxpedda
0c8cf94a70
Web: Fullscreen Overhaul ( #3063 )
2023-08-29 09:28:30 +02:00
daxpedda
1dfca5a395
Enable event propagation ( #3062 )
2023-08-28 19:18:10 +02:00
Mads Marquart
7541220a41
Fix macOS deminiaturize ( #3054 )
2023-08-27 17:35:45 +02:00