Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ComboBox cant use cursor to select items but Keyboard Okay #18228

Open
MatinxHT opened this issue Feb 18, 2025 · 2 comments
Open

ComboBox cant use cursor to select items but Keyboard Okay #18228

MatinxHT opened this issue Feb 18, 2025 · 2 comments

Comments

@MatinxHT
Copy link

Describe the bug

Hellow my Avalonia Project have a ComboBox for user choose device.But I found that my mouse chick open ComboBox and the ItemsSource show fine(we define there is itemA and itemB,itemA is the default SelectedItem),then when i click on the itemB, ComboBox drop closed but SelectedItem still itemA.

Then I try to use keyboard chose itemB and click Enter then SelectedItem successfully changed to itemB.

To Reproduce

My AXAML Code:

                <ComboBox
                    Width="150"
                    Height="40"
                    MinWidth="150"
                    HorizontalAlignment="Center"
                    VerticalAlignment="Center"
                    SelectedItem="{Binding SelectedDevice,Mode=TwoWay}"
                    ItemsSource="{Binding DeviceList}" />

Expected behavior

No response

Avalonia version

11.2.1

OS

Windows

Additional context

happened both Windows and Ubuntu.

@MatinxHT MatinxHT added the bug label Feb 18, 2025
@maxkatz6
Copy link
Member

Do you have any custom styles or any other logic that could affect it?
Normally, cursor/pointer selection works as expected.

@MatinxHT
Copy link
Author

Do you have any custom styles or any other logic that could affect it? Normally, cursor/pointer selection works as expected.

hi maxkatz6. I dont have custom styles becauser this just a test program. I wonder if anybody else have same situation :-(

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants