summaryrefslogtreecommitdiffstats
path: root/examples/integration
diff options
context:
space:
mode:
authorLibravatar Héctor Ramón Jiménez <hector0193@gmail.com>2023-06-08 20:35:40 +0200
committerLibravatar Héctor Ramón Jiménez <hector0193@gmail.com>2023-06-08 20:35:40 +0200
commitaba98e49654852281ed17bedd1becac6f9db8700 (patch)
tree661d5d42cfa968e43bb0751836de3d68cb95c59c /examples/integration
parent57db196c3a169fe1ecd654e9b58ce66defa5dd7e (diff)
downloadiced-aba98e49654852281ed17bedd1becac6f9db8700.tar.gz
iced-aba98e49654852281ed17bedd1becac6f9db8700.tar.bz2
iced-aba98e49654852281ed17bedd1becac6f9db8700.zip
Extend cursor availability to the shell level
Diffstat (limited to 'examples/integration')
-rw-r--r--examples/integration/src/main.rs5
1 files changed, 3 insertions, 2 deletions
diff --git a/examples/integration/src/main.rs b/examples/integration/src/main.rs
index c935aca7..daecfeb2 100644
--- a/examples/integration/src/main.rs
+++ b/examples/integration/src/main.rs
@@ -6,6 +6,7 @@ use scene::Scene;
use iced_wgpu::graphics::Viewport;
use iced_wgpu::{wgpu, Backend, Renderer, Settings};
+use iced_winit::core::mouse;
use iced_winit::core::renderer;
use iced_winit::core::{Color, Size};
use iced_winit::runtime::program;
@@ -194,10 +195,10 @@ pub fn main() -> Result<(), Box<dyn std::error::Error>> {
// We update iced
let _ = state.update(
viewport.logical_size(),
- conversion::cursor_position(
+ mouse::Cursor::Available(conversion::cursor_position(
cursor_position,
viewport.scale_factor(),
- ),
+ )),
&mut renderer,
&Theme::Dark,
&renderer::Style { text_color: Color::WHITE },