From dc17f2cb22fb110c8f525679ab6d3fc175b1e4ee Mon Sep 17 00:00:00 2001 From: Fina Wilke Date: Thu, 24 Oct 2024 22:56:30 +0200 Subject: [PATCH] accessible_value: Fix errormessage relation layout The type was recently changed because it was inconsistent within GTK. See https://gitlab.gnome.org/GNOME/gtk/-/commit/649782b547aa837196344e3b2e51803ee94be74e --- gtk4/src/accessible.rs | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/gtk4/src/accessible.rs b/gtk4/src/accessible.rs index 87c5e384ef55..c73c6726f743 100644 --- a/gtk4/src/accessible.rs +++ b/gtk4/src/accessible.rs @@ -161,7 +161,7 @@ pub enum Relation<'r> { Controls(&'r [&'r Accessible]), DescribedBy(&'r [&'r Accessible]), Details(&'r [&'r Accessible]), - ErrorMessage(&'r Accessible), + ErrorMessage(&'r [&'r Accessible]), FlowTo(&'r [&'r Accessible]), LabelledBy(&'r [&'r Accessible]), Owns(&'r [&'r Accessible]), @@ -202,7 +202,7 @@ impl<'r> Relation<'r> { Controls(v) => (AccessibleRelation::Controls, to_ref_list_value(v)), DescribedBy(v) => (AccessibleRelation::DescribedBy, to_ref_list_value(v)), Details(v) => (AccessibleRelation::Details, to_ref_list_value(v)), - ErrorMessage(v) => (AccessibleRelation::ErrorMessage, v.to_value()), + ErrorMessage(v) => (AccessibleRelation::ErrorMessage, to_ref_list_value(v)), FlowTo(v) => (AccessibleRelation::FlowTo, to_ref_list_value(v)), LabelledBy(v) => (AccessibleRelation::LabelledBy, to_ref_list_value(v)), Owns(v) => (AccessibleRelation::Owns, to_ref_list_value(v)), @@ -301,7 +301,7 @@ mod tests { Relation::Controls(&[other1.upcast_ref(), other2.upcast_ref()]), Relation::DescribedBy(&[other1.upcast_ref(), other2.upcast_ref()]), Relation::Details(&[other1.upcast_ref(), other2.upcast_ref()]), - Relation::ErrorMessage(other1.upcast_ref()), + Relation::ErrorMessage(&[other1.upcast_ref()]), Relation::FlowTo(&[other1.upcast_ref(), other2.upcast_ref()]), Relation::LabelledBy(&[other1.upcast_ref(), other2.upcast_ref()]), Relation::Owns(&[other1.upcast_ref(), other2.upcast_ref()]),