mirror of
https://github.com/slint-ui/slint.git
synced 2025-10-01 14:21:16 +00:00
Use hover for the ugly style combo box as well
This appears to be more consistent with how most combo boxes behave
This commit is contained in:
parent
141c05410e
commit
ecaa55832f
1 changed files with 2 additions and 2 deletions
|
@ -507,11 +507,11 @@ export ComboBox := Rectangle {
|
||||||
VerticalLayout {
|
VerticalLayout {
|
||||||
spacing: 0px;
|
spacing: 0px;
|
||||||
for value[idx] in root.model: Rectangle {
|
for value[idx] in root.model: Rectangle {
|
||||||
background: idx == root.current_index ? Palette.highlight_background : Palette.base_background_color;
|
background: item_area.has_hover ? Palette.highlight_background : Palette.base_background_color;
|
||||||
VerticalLayout { // FIXME: ideally this layout shouldn't be required
|
VerticalLayout { // FIXME: ideally this layout shouldn't be required
|
||||||
Text {
|
Text {
|
||||||
text: value;
|
text: value;
|
||||||
TouchArea {
|
item_area := TouchArea {
|
||||||
width: 100%;
|
width: 100%;
|
||||||
height: 100%;
|
height: 100%;
|
||||||
clicked => {
|
clicked => {
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue