mirror of
https://git.sr.ht/~eliasnaur/gio
synced 2026-07-07 10:25:37 +00:00
io/pointer: added the grab cursor
Signed-off-by: pierre <pierre.curto@gmail.com>
This commit is contained in:
@@ -118,10 +118,13 @@ func (w *x11Window) WriteClipboard(s string) {
|
||||
}
|
||||
|
||||
func (w *x11Window) SetCursor(name pointer.CursorName) {
|
||||
if name == pointer.CursorNone {
|
||||
switch name {
|
||||
case pointer.CursorNone:
|
||||
w.cursor = name
|
||||
C.XFixesHideCursor(w.x, w.xw)
|
||||
return
|
||||
case pointer.CursorGrab:
|
||||
name = "hand1"
|
||||
}
|
||||
if w.cursor == pointer.CursorNone {
|
||||
C.XFixesShowCursor(w.x, w.xw)
|
||||
|
||||
Reference in New Issue
Block a user