diff options
author | Noel Grandin <noel@peralex.com> | 2014-10-14 09:36:33 +0200 |
---|---|---|
committer | Noel Grandin <noelgrandin@gmail.com> | 2014-10-15 10:13:04 +0000 |
commit | d9fa1247be9d3a3d559adbbf9e1ed12395744738 (patch) | |
tree | 20fb4e43af4c94760b290d62ad3a6ac581665bf1 /vcl/source/control | |
parent | d7a0916e68238d619d74cbab72e66980e24d2f48 (diff) |
fdo#84938: replace SYMBOL_TYPE constants with enum
Change-Id: Ib3763f20d74c22e28d519a9ac47f6f3ab4e31f51
Reviewed-on: https://gerrit.libreoffice.org/11983
Reviewed-by: Noel Grandin <noelgrandin@gmail.com>
Tested-by: Noel Grandin <noelgrandin@gmail.com>
Diffstat (limited to 'vcl/source/control')
-rw-r--r-- | vcl/source/control/button.cxx | 8 | ||||
-rw-r--r-- | vcl/source/control/ilstbox.cxx | 4 | ||||
-rw-r--r-- | vcl/source/control/morebtn.cxx | 4 | ||||
-rw-r--r-- | vcl/source/control/scrbar.cxx | 16 | ||||
-rw-r--r-- | vcl/source/control/spinfld.cxx | 24 |
5 files changed, 28 insertions, 28 deletions
diff --git a/vcl/source/control/button.cxx b/vcl/source/control/button.cxx index 03329959edcf..e39c00d8a795 100644 --- a/vcl/source/control/button.cxx +++ b/vcl/source/control/button.cxx @@ -638,7 +638,7 @@ void PushButton::ImplInitPushButtonData() { mpWindowImpl->mbPushButton = true; - meSymbol = SYMBOL_NOSYMBOL; + meSymbol = SymbolType::DONTKNOW; meState = TRISTATE_FALSE; meSaveValue = TRISTATE_FALSE; mnDDStyle = 0; @@ -899,7 +899,7 @@ void PushButton::ImplDrawPushButtonContent( OutputDevice* pDev, sal_uLong nDrawF } ImplSetSeparatorX( nSeparatorX ); - aDecoView.DrawSymbol( aSymbolRect, SYMBOL_SPIN_DOWN, aColor, nStyle ); + aDecoView.DrawSymbol( aSymbolRect, SymbolType::SPIN_DOWN, aColor, nStyle ); } } @@ -986,7 +986,7 @@ void PushButton::ImplDrawPushButton( bool bLayout ) break; } - bool bDropDown = ( IsSymbol() && (GetSymbol()==SYMBOL_SPIN_DOWN) && GetText().isEmpty() ); + bool bDropDown = ( IsSymbol() && (GetSymbol()==SymbolType::SPIN_DOWN) && GetText().isEmpty() ); if( bDropDown && (aCtrlType == CTRL_COMBOBOX || aCtrlType == CTRL_LISTBOX ) ) { @@ -1526,7 +1526,7 @@ bool PushButton::PreNotify( NotifyEvent& rNEvt ) break; } - bool bDropDown = ( IsSymbol() && (GetSymbol()==SYMBOL_SPIN_DOWN) && GetText().isEmpty() ); + bool bDropDown = ( IsSymbol() && (GetSymbol()==SymbolType::SPIN_DOWN) && GetText().isEmpty() ); if( bDropDown && GetParent()->IsNativeControlSupported( aCtrlType, PART_ENTIRE_CONTROL) && !GetParent()->IsNativeControlSupported( aCtrlType, PART_BUTTON_DOWN) ) diff --git a/vcl/source/control/ilstbox.cxx b/vcl/source/control/ilstbox.cxx index 693070fe6261..8a987f44338f 100644 --- a/vcl/source/control/ilstbox.cxx +++ b/vcl/source/control/ilstbox.cxx @@ -78,9 +78,9 @@ void ImplInitFieldSettings( vcl::Window* pWin, bool bFont, bool bForeground, boo void ImplInitDropDownButton( PushButton* pButton ) { if ( pButton->GetSettings().GetStyleSettings().GetOptions() & STYLE_OPTION_SPINUPDOWN ) - pButton->SetSymbol( SYMBOL_SPIN_UPDOWN ); + pButton->SetSymbol( SymbolType::SPIN_UPDOWN ); else - pButton->SetSymbol( SYMBOL_SPIN_DOWN ); + pButton->SetSymbol( SymbolType::SPIN_DOWN ); if ( pButton->IsNativeControlSupported(CTRL_LISTBOX, PART_ENTIRE_CONTROL) && ! pButton->IsNativeControlSupported(CTRL_LISTBOX, PART_BUTTON_DOWN) ) diff --git a/vcl/source/control/morebtn.cxx b/vcl/source/control/morebtn.cxx index f84e0a891287..0b585a1587a8 100644 --- a/vcl/source/control/morebtn.cxx +++ b/vcl/source/control/morebtn.cxx @@ -62,12 +62,12 @@ void MoreButton::ShowState() { if ( mbState ) { - SetSymbol( SYMBOL_PAGEUP ); + SetSymbol( SymbolType::PAGEUP ); SetText( mpMBData->maLessText ); } else { - SetSymbol( SYMBOL_PAGEDOWN ); + SetSymbol( SymbolType::PAGEDOWN ); SetText( mpMBData->maMoreText ); } } diff --git a/vcl/source/control/scrbar.cxx b/vcl/source/control/scrbar.cxx index df763dd5ad4f..1af0b65f4c8e 100644 --- a/vcl/source/control/scrbar.cxx +++ b/vcl/source/control/scrbar.cxx @@ -646,16 +646,16 @@ void ScrollBar::ImplDraw( sal_uInt16 nDrawFlags, OutputDevice* pOutDev ) if ( rStyleSettings.GetOptions() & STYLE_OPTION_SCROLLARROW ) { if ( GetStyle() & WB_HORZ ) - eSymbolType = SYMBOL_ARROW_LEFT; + eSymbolType = SymbolType::ARROW_LEFT; else - eSymbolType = SYMBOL_ARROW_UP; + eSymbolType = SymbolType::ARROW_UP; } else { if ( GetStyle() & WB_HORZ ) - eSymbolType = SYMBOL_SPIN_LEFT; + eSymbolType = SymbolType::SPIN_LEFT; else - eSymbolType = SYMBOL_SPIN_UP; + eSymbolType = SymbolType::SPIN_UP; } aDecoView.DrawSymbol( aTempRect, eSymbolType, rStyleSettings.GetButtonTextColor(), nStyle ); } @@ -673,16 +673,16 @@ void ScrollBar::ImplDraw( sal_uInt16 nDrawFlags, OutputDevice* pOutDev ) if ( rStyleSettings.GetOptions() & STYLE_OPTION_SCROLLARROW ) { if ( GetStyle() & WB_HORZ ) - eSymbolType = SYMBOL_ARROW_RIGHT; + eSymbolType = SymbolType::ARROW_RIGHT; else - eSymbolType = SYMBOL_ARROW_DOWN; + eSymbolType = SymbolType::ARROW_DOWN; } else { if ( GetStyle() & WB_HORZ ) - eSymbolType = SYMBOL_SPIN_RIGHT; + eSymbolType = SymbolType::SPIN_RIGHT; else - eSymbolType = SYMBOL_SPIN_DOWN; + eSymbolType = SymbolType::SPIN_DOWN; } aDecoView.DrawSymbol( aTempRect, eSymbolType, rStyleSettings.GetButtonTextColor(), nStyle ); } diff --git a/vcl/source/control/spinfld.cxx b/vcl/source/control/spinfld.cxx index c1a81b2e73d6..8bbdbb9e14d7 100644 --- a/vcl/source/control/spinfld.cxx +++ b/vcl/source/control/spinfld.cxx @@ -156,26 +156,26 @@ void ImplDrawSpinButton( OutputDevice* pOutDev, // arrows are only use in OS/2 look if ( bHorz ) { - eType1 = bMirrorHorz ? SYMBOL_ARROW_RIGHT : SYMBOL_ARROW_LEFT; - eType2 = bMirrorHorz ? SYMBOL_ARROW_LEFT : SYMBOL_ARROW_RIGHT; + eType1 = bMirrorHorz ? SymbolType::ARROW_RIGHT : SymbolType::ARROW_LEFT; + eType2 = bMirrorHorz ? SymbolType::ARROW_LEFT : SymbolType::ARROW_RIGHT; } else { - eType1 = SYMBOL_ARROW_UP; - eType2 = SYMBOL_ARROW_DOWN; + eType1 = SymbolType::ARROW_UP; + eType2 = SymbolType::ARROW_DOWN; } } else { if ( bHorz ) { - eType1 = bMirrorHorz ? SYMBOL_SPIN_RIGHT : SYMBOL_SPIN_LEFT; - eType2 = bMirrorHorz ? SYMBOL_SPIN_LEFT : SYMBOL_SPIN_RIGHT; + eType1 = bMirrorHorz ? SymbolType::SPIN_RIGHT : SymbolType::SPIN_LEFT; + eType2 = bMirrorHorz ? SymbolType::SPIN_LEFT : SymbolType::SPIN_RIGHT; } else { - eType1 = SYMBOL_SPIN_UP; - eType2 = SYMBOL_SPIN_DOWN; + eType1 = SymbolType::SPIN_UP; + eType2 = SymbolType::SPIN_DOWN; } } @@ -615,9 +615,9 @@ void SpinField::Paint( const Rectangle& rRect ) nStyle |= BUTTON_DRAW_PRESSED; Rectangle aInnerRect = aView.DrawButton( maDropDownRect, nStyle ); - SymbolType eSymbol = SYMBOL_SPIN_DOWN; + SymbolType eSymbol = SymbolType::SPIN_DOWN; if ( GetSettings().GetStyleSettings().GetOptions() & STYLE_OPTION_SPINUPDOWN ) - eSymbol = SYMBOL_SPIN_UPDOWN; + eSymbol = SymbolType::SPIN_UPDOWN; nStyle = IsEnabled() ? 0 : SYMBOL_DRAW_DISABLE; aView.DrawSymbol( aInnerRect, eSymbol, GetSettings().GetStyleSettings().GetButtonTextColor(), nStyle ); @@ -1023,9 +1023,9 @@ void SpinField::Draw( OutputDevice* pDev, const Point& rPos, const Size& rSize, DecorationView aView( pDev ); sal_uInt16 nStyle = BUTTON_DRAW_NOLIGHTBORDER; Rectangle aInnerRect = aView.DrawButton( aDD, nStyle ); - SymbolType eSymbol = SYMBOL_SPIN_DOWN; + SymbolType eSymbol = SymbolType::SPIN_DOWN; if ( GetSettings().GetStyleSettings().GetOptions() & STYLE_OPTION_SPINUPDOWN ) - eSymbol = SYMBOL_SPIN_UPDOWN; + eSymbol = SymbolType::SPIN_UPDOWN; nStyle = ( IsEnabled() || ( nFlags & WINDOW_DRAW_NODISABLE ) ) ? 0 : SYMBOL_DRAW_DISABLE; aView.DrawSymbol( aInnerRect, eSymbol, aButtonTextColor, nStyle ); |