@@ -369,10 +369,10 @@ private static string PanelWords((string Title, string[] Selected) shown) =>
369369 /// focus is put back afterwards. UI thread.
370370 /// </summary>
371371 /// <remarks>
372- /// A stop is listed by its automation id. A group of radio buttons is listed by the group's
373- /// id, the rail by its own and not by the item the focus is on, and the header of a crop
374- /// group by the group's: the header is a part of the framework's template, with the same id
375- /// in every group.
372+ /// A stop is listed by its automation id. A group of radio buttons or choice tiles is listed
373+ /// by the group's id, the rail by its own and not by the item the focus is on, and the header
374+ /// of a crop group by the group's: the header is a part of the framework's template, with the
375+ /// same id in every group.
376376 /// </remarks>
377377 private static List < string > StopsAsItIs ( FrameworkElement content , XamlRoot root , bool putBack = true )
378378 {
@@ -410,12 +410,15 @@ private static string StopOf(DependencyObject focused)
410410 {
411411 var named = focused ;
412412 var isCropHeader = focused is ToggleButton { Name : "ExpanderHeader" } ;
413- if ( focused is ListViewItem || isCropHeader )
413+ var isChoiceTile = focused is GridViewItem ;
414+ if ( focused is ListViewItem || isChoiceTile || isCropHeader )
414415 {
415416 for ( var parent = VisualTreeHelper . GetParent ( focused ) ; parent is not null ; parent = VisualTreeHelper . GetParent ( parent ) )
416417 {
417418 if ( ( focused is SegmentedItem && parent is Segmented )
418419 || ( focused is ListViewItem && parent is ListView && AutomationProperties . GetAutomationId ( parent ) == InspectorRailId )
420+ || ( isChoiceTile && parent is GridView
421+ && ( AutomationProperties . GetAutomationId ( parent ) is "StudioLayoutChoice" or "StudioCameraShapeComboBox" ) )
419422 || ( isCropHeader && parent is Expander ) )
420423 {
421424 named = parent ;
0 commit comments