[Libreoffice-commits] core.git: sc/sdi sc/source
Samuel Mehrbrodt
s.mehrbrodt at gmail.com
Fri Dec 5 04:31:04 PST 2014
sc/sdi/scalc.sdi | 2 +-
sc/source/ui/view/tabvwsh3.cxx | 16 ++++++----------
sc/source/ui/view/tabvwsha.cxx | 6 ------
3 files changed, 7 insertions(+), 17 deletions(-)
New commits:
commit 2f90974fd06870457301ec0be0ab8c43981689ec
Author: Samuel Mehrbrodt <s.mehrbrodt at gmail.com>
Date: Fri Dec 5 13:22:06 2014 +0100
fdo85897 Make 'Function List' only accessible in sidebar
Change-Id: I875d1dd75c02f617814a934b34b5099f9c2279cc
diff --git a/sc/sdi/scalc.sdi b/sc/sdi/scalc.sdi
index e196e85..2fbf373 100644
--- a/sc/sdi/scalc.sdi
+++ b/sc/sdi/scalc.sdi
@@ -2866,7 +2866,7 @@ SfxVoidItem FreezePanes SID_WINDOW_FIX
]
-SfxBoolItem FunctionBox FID_FUNCTION_BOX
+SfxVoidItem FunctionBox FID_FUNCTION_BOX
[
/* flags: */
diff --git a/sc/source/ui/view/tabvwsh3.cxx b/sc/source/ui/view/tabvwsh3.cxx
index 312ff21..8253b37 100644
--- a/sc/source/ui/view/tabvwsh3.cxx
+++ b/sc/source/ui/view/tabvwsh3.cxx
@@ -25,6 +25,7 @@
#include <sfx2/dispatch.hxx>
#include <sfx2/passwd.hxx>
#include <sfx2/request.hxx>
+#include <sfx2/sidebar/Sidebar.hxx>
#include <svl/ptitem.hxx>
#include <svl/stritem.hxx>
#include <tools/urlobj.hxx>
@@ -540,16 +541,11 @@ void ScTabViewShell::Execute( SfxRequest& rReq )
case FID_FUNCTION_BOX:
{
- sal_uInt16 nChildId = ScFunctionChildWindow::GetChildWindowId();
- if ( rReq.GetArgs() )
- pThisFrame->SetChildWindow( nChildId, static_cast<const SfxBoolItem&>(rReq.GetArgs()->Get(FID_FUNCTION_BOX)).GetValue());
- else
- {
- pThisFrame->ToggleChildWindow( nChildId );
- rReq.AppendItem( SfxBoolItem( FID_FUNCTION_BOX , pThisFrame->HasChildWindow( nChildId ) ) );
- }
+ // First make sure that the sidebar is visible
+ pThisFrame->ShowChildWindow(SID_SIDEBAR);
- GetViewFrame()->GetBindings().Invalidate(FID_FUNCTION_BOX);
+ ::sfx2::sidebar::Sidebar::ShowPanel("FunctionsPanel",
+ pThisFrame->GetFrame().GetFrameInterface());
rReq.Done ();
}
break;
@@ -1107,7 +1103,7 @@ void ScTabViewShell::Execute( SfxRequest& rReq )
break;
default:
- OSL_FAIL("Unbekannter Slot bei ScTabViewShell::Execute");
+ OSL_FAIL("Unknown Slot at ScTabViewShell::Execute");
break;
}
}
diff --git a/sc/source/ui/view/tabvwsha.cxx b/sc/source/ui/view/tabvwsha.cxx
index e543588..6c2896d 100644
--- a/sc/source/ui/view/tabvwsha.cxx
+++ b/sc/source/ui/view/tabvwsha.cxx
@@ -152,7 +152,6 @@ void ScTabViewShell::GetState( SfxItemSet& rSet )
SCCOL nPosX = rViewData.GetCurX();
SCROW nPosY = rViewData.GetCurY();
SCTAB nTab = rViewData.GetTabNo();
- sal_uInt16 nMyId = 0;
SfxViewFrame* pThisFrame = GetViewFrame();
bool bOle = GetViewFrame()->GetFrame().IsInPlace();
@@ -344,11 +343,6 @@ void ScTabViewShell::GetState( SfxItemSet& rSet )
}
break;
- case FID_FUNCTION_BOX:
- nMyId = ScFunctionChildWindow::GetChildWindowId();
- rSet.Put(SfxBoolItem(FID_FUNCTION_BOX, pThisFrame->HasChildWindow(nMyId)));
- break;
-
case FID_PROTECT_DOC:
{
if ( pDocShell && pDocShell->IsDocShared() )
More information about the Libreoffice-commits
mailing list