diff options
author | Maxim Monastirsky <momonasmon@gmail.com> | 2014-08-31 21:39:10 +0300 |
---|---|---|
committer | Maxim Monastirsky <momonasmon@gmail.com> | 2014-10-24 11:45:02 +0300 |
commit | 312d903b8ec1805da91f7af367ba18cfe63313a3 (patch) | |
tree | 952f0bd54a1c17619ba978bbf72e087da9907c74 | |
parent | d9dde5e57262e2fb91636ca5d1ee91cdb647ba05 (diff) |
Register the item type based on the SID
Change-Id: If954191b71daf52c4f49fb7638e583cd0a2c97a5
-rw-r--r-- | sc/source/ui/app/scdll.cxx | 2 | ||||
-rw-r--r-- | sd/source/ui/app/sddll.cxx | 2 | ||||
-rw-r--r-- | svx/source/tbxctrls/tbcontrl.cxx | 6 |
3 files changed, 6 insertions, 4 deletions
diff --git a/sc/source/ui/app/scdll.cxx b/sc/source/ui/app/scdll.cxx index 2772993b30e6..072a551133ed 100644 --- a/sc/source/ui/app/scdll.cxx +++ b/sc/source/ui/app/scdll.cxx @@ -171,7 +171,7 @@ void ScDLL::Init() SvxFillToolBoxControl ::RegisterControl(0, pMod); SvxLineStyleToolBoxControl ::RegisterControl(0, pMod); SvxLineWidthToolBoxControl ::RegisterControl(0, pMod); - SvxColorToolBoxControl ::RegisterControl(0, pMod); + SvxColorToolBoxControl ::RegisterControl(SID_ATTR_LINE_COLOR, pMod); SvxLineEndToolBoxControl ::RegisterControl(SID_ATTR_LINEEND_STYLE, pMod); SvxStyleToolBoxControl ::RegisterControl(SID_STYLE_APPLY, pMod); SvxFontNameToolBoxControl ::RegisterControl(SID_ATTR_CHAR_FONT, pMod); diff --git a/sd/source/ui/app/sddll.cxx b/sd/source/ui/app/sddll.cxx index 22c21f0aeaa2..4eda9f20f053 100644 --- a/sd/source/ui/app/sddll.cxx +++ b/sd/source/ui/app/sddll.cxx @@ -207,7 +207,7 @@ void SdDLL::RegisterControllers() SvxFillToolBoxControl::RegisterControl(0, pMod); SvxLineStyleToolBoxControl::RegisterControl(0, pMod); SvxLineWidthToolBoxControl::RegisterControl(0, pMod); - SvxColorToolBoxControl::RegisterControl(0, pMod); + SvxColorToolBoxControl::RegisterControl(SID_ATTR_LINE_COLOR, pMod); SvxLineEndToolBoxControl::RegisterControl( SID_ATTR_LINEEND_STYLE, pMod ); diff --git a/svx/source/tbxctrls/tbcontrl.cxx b/svx/source/tbxctrls/tbcontrl.cxx index 293d8a050991..3f90933b8810 100644 --- a/svx/source/tbxctrls/tbcontrl.cxx +++ b/svx/source/tbxctrls/tbcontrl.cxx @@ -2536,8 +2536,10 @@ SfxToolBoxControl* SvxColorToolBoxControl::CreateImpl( sal_uInt16 nSlotId, sal_u void SvxColorToolBoxControl::RegisterControl(sal_uInt16 nSlotId, SfxModule *pMod) { - SfxToolBoxControl::RegisterToolBoxControl( pMod, new SfxTbxCtrlFactory( SvxColorToolBoxControl::CreateImpl, TYPE(SvxColorItem), nSlotId ) ); - SfxToolBoxControl::RegisterToolBoxControl( pMod, new SfxTbxCtrlFactory( SvxColorToolBoxControl::CreateImpl, TYPE(XLineColorItem), nSlotId ) ); + if ( nSlotId == SID_ATTR_LINE_COLOR ) + SfxToolBoxControl::RegisterToolBoxControl( pMod, new SfxTbxCtrlFactory( SvxColorToolBoxControl::CreateImpl, TYPE(XLineColorItem), nSlotId ) ); + else + SfxToolBoxControl::RegisterToolBoxControl( pMod, new SfxTbxCtrlFactory( SvxColorToolBoxControl::CreateImpl, TYPE(SvxColorItem), nSlotId ) ); } // class SvxFrameToolBoxControl -------------------------------------------- |