Changeset 88862 in vbox for trunk/src/VBox/Frontends
- Timestamp:
- May 4, 2021 4:05:25 PM (4 years ago)
- Location:
- trunk/src/VBox/Frontends/VirtualBox/src
- Files:
-
- 21 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Frontends/VirtualBox/src/extensions/QIToolBar.cpp
r86233 r88862 111 111 112 112 /* Prepare gradient: */ 113 const QColor backgroundColor = palette().color(QPalette::Active, QPalette::Mid);113 const QColor backgroundColor = QApplication::palette().color(QPalette::Active, QPalette::Mid); 114 114 QLinearGradient gradient(rectangle.topLeft(), rectangle.bottomLeft()); 115 gradient.setColorAt(0, 116 gradient.setColorAt(1, 115 gradient.setColorAt(0, backgroundColor.lighter(130)); 116 gradient.setColorAt(1, backgroundColor.lighter(125)); 117 117 118 118 /* Fill background: */ -
trunk/src/VBox/Frontends/VirtualBox/src/logviewer/UIVMLogViewerTextEdit.cpp
r88734 r88862 203 203 204 204 /* Prepare modified standard palette: */ 205 QPalette pal = style() ? style()->standardPalette() : palette(); // fallback if no style exist.205 QPalette pal = style() ? style()->standardPalette() : QApplication::palette(); // fallback if no style exist. 206 206 pal.setColor(QPalette::Inactive, QPalette::Highlight, pal.color(QPalette::Active, QPalette::Highlight)); 207 207 pal.setColor(QPalette::Inactive, QPalette::HighlightedText, pal.color(QPalette::Active, QPalette::HighlightedText)); -
trunk/src/VBox/Frontends/VirtualBox/src/manager/UIVirtualBoxManager.cpp
r88758 r88862 2225 2225 /* Make sure menu-bar fills own solid background: */ 2226 2226 menuBar()->setAutoFillBackground(true); 2227 QPalette pal = menuBar()->palette();2227 QPalette pal = QApplication::palette(); 2228 2228 const QColor color = pal.color(QPalette::Active, QPalette::Mid).lighter(160); 2229 2229 pal.setColor(QPalette::Active, QPalette::Button, color); -
trunk/src/VBox/Frontends/VirtualBox/src/manager/UIVirtualBoxManagerWidget.cpp
r88834 r88862 568 568 { 569 569 setAutoFillBackground(true); 570 QPalette pal = palette();570 QPalette pal = QApplication::palette(); 571 571 #ifdef VBOX_WS_MAC 572 572 const QColor color = pal.color(QPalette::Active, QPalette::Mid).lighter(145); … … 696 696 697 697 /* Adjust splitter colors according to main widgets it splits: */ 698 m_pSplitter->configureColor( palette().color(QPalette::Active, QPalette::Midlight).darker(110));698 m_pSplitter->configureColor(QApplication::palette().color(QPalette::Active, QPalette::Midlight).darker(110)); 699 699 /* Set the initial distribution. The right site is bigger. */ 700 700 m_pSplitter->setStretchFactor(0, 2); -
trunk/src/VBox/Frontends/VirtualBox/src/manager/chooser/UIChooserItemGlobal.cpp
r88856 r88862 559 559 560 560 /* Prepare color: */ 561 const QPalette pal = palette();561 const QPalette pal = QApplication::palette(); 562 562 563 563 /* Selected-item background: */ … … 665 665 666 666 /* Prepare color: */ 667 const QPalette pal = palette();667 const QPalette pal = QApplication::palette(); 668 668 QColor strokeColor; 669 669 -
trunk/src/VBox/Frontends/VirtualBox/src/manager/chooser/UIChooserItemGroup.cpp
r88805 r88862 1665 1665 1666 1666 /* Prepare color: */ 1667 const QPalette pal = palette(); 1668 const QColor strokeColor = pal.color(QPalette::Active, 1669 model()->selectedItems().contains(this) ? 1670 QPalette::Highlight : QPalette::Midlight).darker(headerDarkness() + 10); 1667 const QColor frameColor = QApplication::palette().color(QPalette::Active, 1668 model()->selectedItems().contains(this) ? 1669 QPalette::Highlight : QPalette::Midlight).darker(headerDarkness() + 10); 1671 1670 1672 1671 /* Create/assign pen: */ 1673 QPen pen( strokeColor);1672 QPen pen(frameColor); 1674 1673 pen.setWidth(0); 1675 1674 pPainter->setPen(pen); … … 1705 1704 1706 1705 /* Configure painter color: */ 1707 pPainter->setPen( palette().color(QPalette::Active,1708 model()->selectedItems().contains(this) ?1709 QPalette::HighlightedText : QPalette::ButtonText));1706 pPainter->setPen(QApplication::palette().color(QPalette::Active, 1707 model()->selectedItems().contains(this) ? 1708 QPalette::HighlightedText : QPalette::ButtonText)); 1710 1709 1711 1710 /* Paint name: */ -
trunk/src/VBox/Frontends/VirtualBox/src/manager/chooser/UIChooserItemMachine.cpp
r88857 r88862 903 903 904 904 /* Prepare color: */ 905 const QPalette pal = palette();905 const QPalette pal = QApplication::palette(); 906 906 907 907 /* Selected-item background: */ … … 1045 1045 1046 1046 /* Prepare color: */ 1047 const QPalette pal = palette();1047 const QPalette pal = QApplication::palette(); 1048 1048 QColor strokeColor; 1049 1049 -
trunk/src/VBox/Frontends/VirtualBox/src/manager/details/UIDetailsElement.cpp
r88149 r88862 1472 1472 1473 1473 /* Acquire palette: */ 1474 const QPalette pal = palette();1474 const QPalette pal = QApplication::palette(); 1475 1475 1476 1476 /* Paint default background: */ … … 1516 1516 1517 1517 /* Paint frame: */ 1518 const QColor strokeColor =palette().color(QPalette::Active, QPalette::Mid).lighter(m_iDefaultToneStart);1519 QPen pen( strokeColor);1518 const QColor frameColor = QApplication::palette().color(QPalette::Active, QPalette::Mid).lighter(m_iDefaultToneStart); 1519 QPen pen(frameColor); 1520 1520 pen.setWidth(0); 1521 1521 pPainter->setPen(pen); … … 1541 1541 1542 1542 /* Prepare color: */ 1543 const QPalette pal = palette();1543 const QPalette pal = QApplication::palette(); 1544 1544 const QColor buttonTextColor = pal.color(QPalette::Active, QPalette::ButtonText); 1545 1545 const QColor linkTextColor = pal.color(QPalette::Active, QPalette::Link); -
trunk/src/VBox/Frontends/VirtualBox/src/manager/tools/UIToolsItem.cpp
r88855 r88862 709 709 710 710 /* Prepare variables: */ 711 const QPalette pal = palette();711 const QPalette pal = QApplication::palette(); 712 712 713 713 /* Selection background: */ … … 817 817 818 818 /* Prepare colors: */ 819 const QPalette pal = palette();819 const QPalette pal = QApplication::palette(); 820 820 QColor strokeColor; 821 821 … … 851 851 const int iMargin = data(ToolsItemData_Margin).toInt(); 852 852 const int iSpacing = data(ToolsItemData_Spacing).toInt(); 853 const QPalette pal = palette();853 const QPalette pal = QApplication::palette(); 854 854 855 855 /* Selected or hovered item foreground: */ -
trunk/src/VBox/Frontends/VirtualBox/src/snapshots/UISnapshotDetailsWidget.cpp
r84792 r88862 252 252 253 253 /* Prepare palette colors: */ 254 const QPalette pal = palette();254 const QPalette pal = QApplication::palette(); 255 255 QColor color0 = pal.color(QPalette::Window); 256 256 QColor color1 = pal.color(QPalette::Window).lighter(110); -
trunk/src/VBox/Frontends/VirtualBox/src/widgets/UIMenuBarEditorWindow.cpp
r86233 r88862 674 674 675 675 /* Prepare palette colors: */ 676 const QPalette pal = palette();676 const QPalette pal = QApplication::palette(); 677 677 QColor color0 = pal.color(QPalette::Window); 678 678 QColor color1 = pal.color(QPalette::Window).lighter(110); -
trunk/src/VBox/Frontends/VirtualBox/src/widgets/UIMenuToolBar.cpp
r86233 r88862 249 249 } 250 250 QRect backgroundRect = rect(); 251 QColor backgroundColor = palette().color(QPalette::Window);251 QColor backgroundColor = QApplication::palette().color(QPalette::Window); 252 252 QLinearGradient headerGradient(backgroundRect.bottomLeft(), backgroundRect.topLeft()); 253 253 headerGradient.setColorAt(0, backgroundColor.darker(120)); -
trunk/src/VBox/Frontends/VirtualBox/src/widgets/UIMiniToolBar.cpp
r88635 r88862 266 266 } 267 267 QRect backgroundRect = rect(); 268 QColor backgroundColor = palette().color(QPalette::Window);268 QColor backgroundColor = QApplication::palette().color(QPalette::Window); 269 269 QLinearGradient headerGradient(backgroundRect.bottomLeft(), backgroundRect.topLeft()); 270 270 headerGradient.setColorAt(0, backgroundColor.darker(120)); … … 890 890 /* Configure own background: */ 891 891 QPalette pal = m_pToolbar->palette(); 892 pal.setColor(QPalette::Window, palette().color(QPalette::Window));892 pal.setColor(QPalette::Window, QApplication::palette().color(QPalette::Window)); 893 893 m_pToolbar->setPalette(pal); 894 894 /* Configure child connections: */ -
trunk/src/VBox/Frontends/VirtualBox/src/widgets/UIPopupBox.cpp
r84911 r88862 282 282 painter.setClipRect(pEvent->rect()); 283 283 284 QPalette pal = palette();284 QPalette pal = QApplication::palette(); 285 285 painter.setClipPath(*m_pLabelPath); 286 286 QColor base = pal.color(QPalette::Active, QPalette::Window); -
trunk/src/VBox/Frontends/VirtualBox/src/widgets/UIPopupPane.cpp
r82968 r88862 240 240 { 241 241 /* Prepare palette: */ 242 QPalette pal = palette();242 QPalette pal = QApplication::palette(); 243 243 pal.setColor(QPalette::Window, QApplication::palette().color(QPalette::Window)); 244 244 setPalette(pal); -
trunk/src/VBox/Frontends/VirtualBox/src/widgets/UISearchLineEdit.cpp
r86821 r88862 93 93 void UISearchLineEdit::colorBackground(bool fWarning) 94 94 { 95 QPalette mPalette = palette();95 QPalette mPalette = QApplication::palette(); 96 96 /** Make sure we reset color. */ 97 97 if (!fWarning || !m_fMark) -
trunk/src/VBox/Frontends/VirtualBox/src/widgets/UISlidingToolBar.cpp
r82968 r88862 165 165 /* Configure child-widget: */ 166 166 QPalette pal2 = m_pWidget->palette(); 167 pal2.setColor(QPalette::Window, palette().color(QPalette::Window));167 pal2.setColor(QPalette::Window, QApplication::palette().color(QPalette::Window)); 168 168 m_pWidget->setPalette(pal2); 169 169 /* Using abstract (old-style) connection here(!) since the base classes can be different: */ -
trunk/src/VBox/Frontends/VirtualBox/src/widgets/UIStatusBarEditorWindow.cpp
r82968 r88862 499 499 500 500 /* Prepare palette colors: */ 501 const QPalette pal = palette();501 const QPalette pal = QApplication::palette(); 502 502 QColor color0 = pal.color(QPalette::Window); 503 503 QColor color1 = pal.color(QPalette::Window).lighter(110); -
trunk/src/VBox/Frontends/VirtualBox/src/widgets/UITabBar.cpp
r82968 r88862 247 247 248 248 /* Prepare palette colors: */ 249 const QPalette pal = palette();249 const QPalette pal = QApplication::palette(); 250 250 const QColor color0 = m_fCurrent 251 251 ? pal.color(QPalette::Shadow).darker(110) … … 368 368 369 369 /* Prepare palette colors: */ 370 const QPalette pal = palette();370 const QPalette pal = QApplication::palette(); 371 371 const QColor color0 = m_fCurrent ? pal.color(QPalette::Base) 372 372 : m_fHovered ? pal.color(QPalette::Base).darker(102) -
trunk/src/VBox/Frontends/VirtualBox/src/widgets/UIToolBox.cpp
r88369 r88862 366 366 pNewPage->setTitle(strTitle); 367 367 368 const QPalette pal = palette();368 const QPalette pal = QApplication::palette(); 369 369 QColor tabBackgroundColor = pal.color(QPalette::Active, QPalette::Highlight).lighter(130); 370 370 pNewPage->setTitleBackgroundColor(tabBackgroundColor); -
trunk/src/VBox/Frontends/VirtualBox/src/widgets/graphics/UIGraphicsScrollBar.cpp
r82968 r88862 153 153 154 154 /* Prepare color: */ 155 const QPalette pal = palette();155 const QPalette pal = QApplication::palette(); 156 156 157 157 #ifdef VBOX_WS_MAC … … 991 991 992 992 /* Prepare color: */ 993 const QPalette pal = palette();993 const QPalette pal = QApplication::palette(); 994 994 995 995 #ifdef VBOX_WS_MAC
Note:
See TracChangeset
for help on using the changeset viewer.