1
0
Fork 0
mirror of https://github.com/alacritty/alacritty.git synced 2024-11-25 14:05:41 -05:00

Change cursor from pointer to text (#778)

It seems that (as a rule) terminal emulators use the text mouse cursor rather
than the pointer that is used now. This commit changes the cursor to
using winit's built-in configuration function.
This commit is contained in:
Dustin 2017-10-22 14:34:31 -04:00 committed by Joe Wilm
parent bfdd7b0062
commit 16c047b08a

View file

@ -16,7 +16,7 @@ use std::fmt::{self, Display};
use std::ops::Deref;
use gl;
use glutin::{self, EventsLoop, WindowBuilder, Event, CursorState, ControlFlow, ContextBuilder};
use glutin::{self, EventsLoop, WindowBuilder, Event, MouseCursor, CursorState, ControlFlow, ContextBuilder};
use glutin::GlContext;
/// Window errors
@ -195,6 +195,9 @@ impl Window {
.with_vsync(true);
let window = ::glutin::GlWindow::new(window, context, &event_loop)?;
// Text cursor
window.set_cursor(MouseCursor::Text);
// Set OpenGL symbol loader
gl::load_with(|symbol| window.get_proc_address(symbol) as *const _);