summaryrefslogtreecommitdiff
path: root/vcl
diff options
context:
space:
mode:
authorStephan Bergmann <sbergman@redhat.com>2015-01-06 11:50:03 +0100
committerStephan Bergmann <sbergman@redhat.com>2015-01-06 11:50:03 +0100
commit485e4432b737ec20ce78fe5afd44365000eda6f3 (patch)
treea030718ae85a874369cc6f00c31560e2defc47b7 /vcl
parent549b7fad48bb9ddcba7dfa92daea6ce917853a03 (diff)
Fix o3tl::typed_flags to bool conversions
Change-Id: Iaed915b3765a3d23aea7f771a7c912956d864c5b
Diffstat (limited to 'vcl')
-rw-r--r--vcl/unx/kde/salnativewidgets-kde.cxx6
-rw-r--r--vcl/unx/kde4/KDESalGraphics.cxx2
2 files changed, 4 insertions, 4 deletions
diff --git a/vcl/unx/kde/salnativewidgets-kde.cxx b/vcl/unx/kde/salnativewidgets-kde.cxx
index e1a7322abfe2..bd3dbaa4a4e0 100644
--- a/vcl/unx/kde/salnativewidgets-kde.cxx
+++ b/vcl/unx/kde/salnativewidgets-kde.cxx
@@ -516,7 +516,7 @@ bool WidgetPainter::drawStyledWidget( QWidget *pWidget,
pWidget->move( 0, 0 );
// Enable/disable the widget
- pWidget->setEnabled( nState & ControlState::ENABLED );
+ pWidget->setEnabled( bool(nState & ControlState::ENABLED) );
// Create pixmap to paint to
KDEX11Pixmap xPixmap( pWidget->width(), pWidget->height() );
@@ -1413,7 +1413,7 @@ bool KDESalGraphics::drawNativeControl( ControlType nType, ControlPart nPart,
if ( (nType == CTRL_PUSHBUTTON) && (nPart == PART_ENTIRE_CONTROL) )
{
bReturn = pWidgetPainter->drawStyledWidget(
- pWidgetPainter->pushButton( rControlRegion, (nState & ControlState::DEFAULT) ),
+ pWidgetPainter->pushButton( rControlRegion, bool(nState & ControlState::DEFAULT) ),
nState, aValue, this );
}
else if ( (nType == CTRL_RADIOBUTTON) && (nPart == PART_ENTIRE_CONTROL) )
@@ -1542,7 +1542,7 @@ bool KDESalGraphics::getNativeControlRegion( ControlType nType, ControlPart nPar
{
// Metrics of the push button
case CTRL_PUSHBUTTON:
- pWidget = pWidgetPainter->pushButton( rControlRegion, ( nState & ControlState::DEFAULT ) );
+ pWidget = pWidgetPainter->pushButton( rControlRegion, bool( nState & ControlState::DEFAULT ) );
switch ( nPart )
{
diff --git a/vcl/unx/kde4/KDESalGraphics.cxx b/vcl/unx/kde4/KDESalGraphics.cxx
index 282566c5e4f1..0c43fd2856da 100644
--- a/vcl/unx/kde4/KDESalGraphics.cxx
+++ b/vcl/unx/kde4/KDESalGraphics.cxx
@@ -337,7 +337,7 @@ bool KDESalGraphics::drawNativeControl( ControlType type, ControlPart part,
QStyleOptionMenuItem option;
option.checkType = ( part == PART_MENU_ITEM_CHECK_MARK )
? QStyleOptionMenuItem::NonExclusive : QStyleOptionMenuItem::Exclusive;
- option.checked = (nControlState & ControlState::PRESSED) ? true : false;
+ option.checked = bool( nControlState & ControlState::PRESSED );
// widgetRect is now the rectangle for the checkbox/radiobutton itself, but Qt
// paints the whole menu item, so translate position (and it'll be clipped);
// it is also necessary to fill the background transparently first, as this