From a498b12dc1723b072a165f8c528c377024fd4c98 Mon Sep 17 00:00:00 2001 From: Noel Grandin Date: Wed, 7 Mar 2018 08:42:58 +0200 Subject: use more Color in editeng..forms Change-Id: If6c862e7bb61cd78c3379afde11b528a74162900 Reviewed-on: https://gerrit.libreoffice.org/50860 Tested-by: Jenkins Reviewed-by: Noel Grandin --- extensions/source/propctrlr/formcomponenthandler.cxx | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-) (limited to 'extensions/source/propctrlr/formcomponenthandler.cxx') diff --git a/extensions/source/propctrlr/formcomponenthandler.cxx b/extensions/source/propctrlr/formcomponenthandler.cxx index 40fce9868229..a24eb5cf1868 100644 --- a/extensions/source/propctrlr/formcomponenthandler.cxx +++ b/extensions/source/propctrlr/formcomponenthandler.cxx @@ -2847,9 +2847,8 @@ namespace pcr bool FormComponentPropertyHandler::impl_dialogColorChooser_throw( sal_Int32 _nColorPropertyId, Any& _out_rNewValue, ::osl::ClearableMutexGuard& _rClearBeforeDialog ) const { - sal_Int32 nColor = 0; - OSL_VERIFY( impl_getPropertyValue_throw( impl_getPropertyNameFromId_nothrow( _nColorPropertyId ) ) >>= nColor ); - ::Color aColor( nColor ); + ::Color aColor; + OSL_VERIFY( impl_getPropertyValue_throw( impl_getPropertyNameFromId_nothrow( _nColorPropertyId ) ) >>= aColor ); SvColorDialog aColorDlg( impl_getDefaultDialogParent_nothrow() ); aColorDlg.SetColor( aColor ); @@ -2857,9 +2856,7 @@ namespace pcr if ( !aColorDlg.Execute() ) return false; - aColor = aColorDlg.GetColor(); - nColor = aColor.GetColor(); - _out_rNewValue <<= nColor; + _out_rNewValue <<= aColorDlg.GetColor(); return true; } -- cgit