Changeset 88857 in vbox for trunk/src/VBox
- Timestamp:
- May 4, 2021 2:05:11 PM (4 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Frontends/VirtualBox/src/manager/chooser/UIChooserItemMachine.cpp
r88856 r88857 992 992 { 993 993 /* Window color: */ 994 QColor color1; 995 QColor color2; 994 QColor backgroundColor; 996 995 997 996 QLinearGradient dragTokenGradient; … … 1001 1000 /* Selected-item background: */ 1002 1001 if (model()->selectedItems().contains(unconst(this))) 1003 { 1004 QColor backgroundColor = pal.color(QPalette::Active, QPalette::Highlight); 1005 color1 = backgroundColor.lighter(m_iHighlightLightnessMax); 1006 color2 = backgroundColor.lighter(m_iHighlightLightnessMax - 70); 1007 } 1002 backgroundColor = pal.color(QPalette::Active, QPalette::Highlight); 1008 1003 /* Default background: */ 1009 1004 else 1010 { 1011 QColor backgroundColor = pal.color(QPalette::Active, QPalette::Mid); 1012 color1 = backgroundColor.lighter(m_iDefaultLightnessMax); 1013 color2 = backgroundColor.lighter(m_iDefaultLightnessMax - 70); 1014 } 1005 backgroundColor = pal.color(QPalette::Active, QPalette::Window); 1015 1006 1016 1007 dragTokenRect.setHeight(5); … … 1022 1013 /* Selected-item background: */ 1023 1014 if (model()->selectedItems().contains(unconst(this))) 1024 { 1025 QColor backgroundColor = pal.color(QPalette::Active, QPalette::Highlight); 1026 color1 = backgroundColor.lighter(m_iHighlightLightnessMin); 1027 color2 = backgroundColor.lighter(m_iHighlightLightnessMin - 40); 1028 } 1015 backgroundColor = pal.color(QPalette::Active, QPalette::Highlight); 1029 1016 /* Default background: */ 1030 1017 else 1031 { 1032 QColor backgroundColor = pal.color(QPalette::Active, QPalette::Mid); 1033 color1 = backgroundColor.lighter(m_iDefaultLightnessMin); 1034 color2 = backgroundColor.lighter(m_iDefaultLightnessMin - 40); 1035 } 1018 backgroundColor = pal.color(QPalette::Active, QPalette::Window); 1036 1019 1037 1020 dragTokenRect.setTopLeft(dragTokenRect.bottomLeft() - QPoint(0, 4)); … … 1039 1022 dragTokenGradient.setFinalStop(dragTokenRect.bottomLeft()); 1040 1023 } 1024 QColor color1 = backgroundColor; 1025 QColor color2 = backgroundColor; 1026 color1.setAlpha(64); 1027 color2.setAlpha(255); 1041 1028 dragTokenGradient.setColorAt(0, color1); 1042 1029 dragTokenGradient.setColorAt(1, color2);
Note:
See TracChangeset
for help on using the changeset viewer.