apprt/gtk: move surface event controllers, block events from revealers
parent
4fef41bc83
commit
832883b600
|
|
@ -41,6 +41,34 @@ Overlay terminal_page {
|
||||||
halign: start;
|
halign: start;
|
||||||
has-arrow: false;
|
has-arrow: false;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
EventControllerFocus {
|
||||||
|
enter => $focus_enter();
|
||||||
|
leave => $focus_leave();
|
||||||
|
}
|
||||||
|
|
||||||
|
EventControllerKey {
|
||||||
|
key-pressed => $key_pressed();
|
||||||
|
key-released => $key_released();
|
||||||
|
}
|
||||||
|
|
||||||
|
EventControllerScroll {
|
||||||
|
scroll => $scroll();
|
||||||
|
scroll-begin => $scroll_begin();
|
||||||
|
scroll-end => $scroll_end();
|
||||||
|
flags: both_axes;
|
||||||
|
}
|
||||||
|
|
||||||
|
EventControllerMotion {
|
||||||
|
motion => $mouse_motion();
|
||||||
|
leave => $mouse_leave();
|
||||||
|
}
|
||||||
|
|
||||||
|
GestureClick {
|
||||||
|
pressed => $mouse_down();
|
||||||
|
released => $mouse_up();
|
||||||
|
button: 0;
|
||||||
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
[overlay]
|
[overlay]
|
||||||
|
|
@ -64,6 +92,10 @@ Overlay terminal_page {
|
||||||
reveal-child: bind $should_border_be_shown(template.config, template.bell-ringing) as <bool>;
|
reveal-child: bind $should_border_be_shown(template.config, template.bell-ringing) as <bool>;
|
||||||
transition-type: crossfade;
|
transition-type: crossfade;
|
||||||
transition-duration: 500;
|
transition-duration: 500;
|
||||||
|
// Revealers take up the full size, we need this to not capture events.
|
||||||
|
can-focus: false;
|
||||||
|
can-target: false;
|
||||||
|
focusable: false;
|
||||||
|
|
||||||
Box bell_overlay {
|
Box bell_overlay {
|
||||||
styles [
|
styles [
|
||||||
|
|
@ -129,35 +161,6 @@ Overlay terminal_page {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// Event controllers for interactivity
|
|
||||||
EventControllerFocus {
|
|
||||||
enter => $focus_enter();
|
|
||||||
leave => $focus_leave();
|
|
||||||
}
|
|
||||||
|
|
||||||
EventControllerKey {
|
|
||||||
key-pressed => $key_pressed();
|
|
||||||
key-released => $key_released();
|
|
||||||
}
|
|
||||||
|
|
||||||
EventControllerMotion {
|
|
||||||
motion => $mouse_motion();
|
|
||||||
leave => $mouse_leave();
|
|
||||||
}
|
|
||||||
|
|
||||||
EventControllerScroll {
|
|
||||||
scroll => $scroll();
|
|
||||||
scroll-begin => $scroll_begin();
|
|
||||||
scroll-end => $scroll_end();
|
|
||||||
flags: both_axes;
|
|
||||||
}
|
|
||||||
|
|
||||||
GestureClick {
|
|
||||||
pressed => $mouse_down();
|
|
||||||
released => $mouse_up();
|
|
||||||
button: 0;
|
|
||||||
}
|
|
||||||
|
|
||||||
DropTarget drop_target {
|
DropTarget drop_target {
|
||||||
drop => $drop();
|
drop => $drop();
|
||||||
actions: copy;
|
actions: copy;
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue