Browse Source

ListBox: Select row on focus

v6.1.6
ed 4 years ago
parent
commit
edd4ff9cfc
1 changed files with 1 additions and 1 deletions
  1. +1
    -1
      modules/juce_gui_basics/widgets/juce_ListBox.cpp

+ 1
- 1
modules/juce_gui_basics/widgets/juce_ListBox.cpp View File

@@ -32,12 +32,12 @@ static AccessibilityActions getListRowAccessibilityActions (RowComponentType& ro
auto onFocus = [&rowComponent]
{
rowComponent.owner.scrollToEnsureRowIsOnscreen (rowComponent.row);
rowComponent.owner.selectRow (rowComponent.row);
};
auto onPress = [&rowComponent, onFocus]
{
onFocus();
rowComponent.owner.selectRow (rowComponent.row);
rowComponent.owner.keyPressed (KeyPress (KeyPress::returnKey));
};


Loading…
Cancel
Save