mirror of
https://github.com/elementary/gala.git
synced 2024-10-05 19:27:25 +03:00
WindowSwitcher: set accessible properties
This commit is contained in:
parent
18621b90ef
commit
2ae97f8007
@ -69,6 +69,9 @@ public class Gala.WindowSwitcher : CanvasActor {
|
||||
#endif
|
||||
};
|
||||
|
||||
container.get_accessible ().set_name (_("Window switcher"));
|
||||
get_accessible ().accessible_role = LIST;
|
||||
|
||||
caption = new Clutter.Text () {
|
||||
font_name = CAPTION_FONT_NAME,
|
||||
ellipsize = END,
|
||||
@ -355,6 +358,7 @@ public class Gala.WindowSwitcher : CanvasActor {
|
||||
|
||||
private void add_icon (WindowSwitcherIcon icon) {
|
||||
container.add_child (icon);
|
||||
icon.get_accessible ().accessible_parent = container.get_accessible ();
|
||||
|
||||
icon.motion_event.connect (() => {
|
||||
if (current_icon != icon && !handling_gesture) {
|
||||
|
@ -40,6 +40,9 @@ public class Gala.WindowSwitcherIcon : CanvasActor {
|
||||
icon.add_constraint (new Clutter.AlignConstraint (this, Clutter.AlignAxis.BOTH, 0.5f));
|
||||
add_child (icon);
|
||||
|
||||
get_accessible ().accessible_name = window.title;
|
||||
get_accessible ().accessible_role = LIST_ITEM;
|
||||
|
||||
reactive = true;
|
||||
|
||||
this.scale_factor = scale_factor;
|
||||
@ -76,5 +79,7 @@ public class Gala.WindowSwitcherIcon : CanvasActor {
|
||||
|
||||
ctx.restore ();
|
||||
}
|
||||
|
||||
get_accessible ().notify_state_change (Atk.StateType.SELECTED, selected);
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user