diff options
author | Noel Grandin <noel@peralex.com> | 2014-10-20 09:10:45 +0200 |
---|---|---|
committer | Noel Grandin <noel@peralex.com> | 2014-10-21 09:06:40 +0200 |
commit | 182fc4f184b77330fdbb32096b64f5fbc5b5f874 (patch) | |
tree | 1ba73fb9188796ed43976fe32f291f9c64fb1d5b /toolkit | |
parent | 43327878920f424f8bac1114bee51c54609796c5 (diff) |
fdo#84938: replace WINDOW_BORDER constants with enum
Change-Id: I91ca8e09971aee26f16257a4fd01125cfb2ebcdb
Diffstat (limited to 'toolkit')
-rw-r--r-- | toolkit/source/awt/vclxwindow.cxx | 11 | ||||
-rw-r--r-- | toolkit/source/awt/vclxwindows.cxx | 2 |
2 files changed, 7 insertions, 6 deletions
diff --git a/toolkit/source/awt/vclxwindow.cxx b/toolkit/source/awt/vclxwindow.cxx index 8971e360f979..2b5c7f637d62 100644 --- a/toolkit/source/awt/vclxwindow.cxx +++ b/toolkit/source/awt/vclxwindow.cxx @@ -1697,9 +1697,10 @@ void VCLXWindow::setProperty( const OUString& PropertyName, const ::com::sun::st case BASEPROPERTY_BORDER: { WinBits nStyle = pWindow->GetStyle(); - sal_uInt16 nBorder = 0; - Value >>= nBorder; - if ( !nBorder ) + sal_uInt16 nTmp = 0; + Value >>= nTmp; + WindowBorderStyle nBorder = static_cast<WindowBorderStyle>(nTmp); + if ( !bool(nBorder) ) { pWindow->SetStyle( nStyle & ~WB_BORDER ); } @@ -2029,10 +2030,10 @@ void VCLXWindow::setProperty( const OUString& PropertyName, const ::com::sun::st break; case BASEPROPERTY_BORDER: { - sal_Int16 nBorder = 0; + WindowBorderStyle nBorder = WindowBorderStyle::NONE; if ( GetWindow()->GetStyle() & WB_BORDER ) nBorder = GetWindow()->GetBorderStyle(); - aProp <<= nBorder; + aProp <<= static_cast<sal_uInt16>(nBorder); } break; case BASEPROPERTY_TABSTOP: diff --git a/toolkit/source/awt/vclxwindows.cxx b/toolkit/source/awt/vclxwindows.cxx index a55844f104f8..d9714a98c173 100644 --- a/toolkit/source/awt/vclxwindows.cxx +++ b/toolkit/source/awt/vclxwindows.cxx @@ -4395,7 +4395,7 @@ void VCLXComboBox::setProperty( const OUString& PropertyName, const ::com::sun:: { sal_uInt16 nBorder = sal_uInt16(); if ( (Value >>= nBorder) && nBorder != 0 ) - pComboBox->SetBorderStyle( nBorder ); + pComboBox->SetBorderStyle( static_cast<WindowBorderStyle>(nBorder) ); } } } |