diff options
author | Miklos Vajna <vmiklos@collabora.co.uk> | 2016-03-03 12:18:59 +0100 |
---|---|---|
committer | Miklos Vajna <vmiklos@collabora.co.uk> | 2016-03-03 13:40:14 +0100 |
commit | e4fe540aa4f77a4d76e4c6042d5790211aebc450 (patch) | |
tree | 606e0ac16dccae322aa15dbb6b2c701ca1acba0e /sc/source/ui | |
parent | a56ba98ec5e287f872d957493f9e81ee27a24c00 (diff) |
sc: add classification toolbar
Again this is just UI to call into sfx2, where the functionality is
shared with Writer and Impress.
Change-Id: I73ce6fb54d50c23df19ed2c610766b7c515e94d6
Diffstat (limited to 'sc/source/ui')
-rw-r--r-- | sc/source/ui/view/formatsh.cxx | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/sc/source/ui/view/formatsh.cxx b/sc/source/ui/view/formatsh.cxx index c7d409757c8e..8d7440bb4ae9 100644 --- a/sc/source/ui/view/formatsh.cxx +++ b/sc/source/ui/view/formatsh.cxx @@ -81,6 +81,7 @@ #include "scabstdlg.hxx" #include <editeng/fontitem.hxx> +#include <sfx2/classificationhelper.hxx> #include <memory> @@ -967,6 +968,18 @@ void ScFormatShell::ExecuteStyle( SfxRequest& rReq ) if ( bListAction ) pDocSh->GetUndoManager()->LeaveListAction(); } + else if (nSlotId == SID_CLASSIFICATION_APPLY) + { + const SfxPoolItem* pItem = 0; + if (pArgs && pArgs->GetItemState(nSlotId, false, &pItem) == SfxItemState::SET) + { + const OUString& rName = static_cast<const SfxStringItem*>(pItem)->GetValue(); + SfxClassificationHelper aHelper(*pDocSh); + aHelper.SetBACName(rName); + } + else + SAL_WARN("sc.ui", "missing parameter for SID_CLASSIFICATION_APPLY"); + } else { OSL_FAIL( "Unknown slot (ScViewShell::ExecuteStyle)" ); |