mirror of
https://github.com/juce-framework/JUCE.git
synced 2026-01-17 00:44:19 +00:00
ListBox: Select row on focus
This commit is contained in:
parent
8dfb916e9a
commit
edd4ff9cfc
1 changed files with 1 additions and 1 deletions
|
|
@ -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…
Add table
Add a link
Reference in a new issue