summaryrefslogtreecommitdiff
path: root/svx
diff options
context:
space:
mode:
authorSamuel Mehrbrodt <s.mehrbrodt@gmail.com>2014-08-22 22:37:56 +0200
committerThomas Arnhold <thomas@arnhold.org>2014-08-24 06:26:17 -0500
commitb4558b508141af16d335f45a0f12bdd34521e944 (patch)
treef8479fe8131a0d1677100e2cc16c244e860189cb /svx
parenta75e0f8e4e5f0baa5805d01c5f8edc7b40fceb0f (diff)
fdo#73151 Make better use of the sidebar
The general idea is to encourage use of the sidebar instead of floating windows (for Navigator, Styles&Formatting and Gallery) Changes: * Show the sidebar by default in Writer & Impress * Remove the Gallery floating window (Gallery now always opens in the sidebar) * Remove all Gallery, Navigator and Styles&Formatting links from the default toolbar in Writer (since they have an icon in the sidebar and the sidebar is shown by default now) * When selecting "More" from the Styles dropdown, the Stylelist opens in the sidebar instead of the floating window This has all been discussed extensively here: https://bugs.freedesktop.org/show_bug.cgi?id=73151 Change-Id: I3a0461d1472711da7121801000af294b432fccb1 Reviewed-on: https://gerrit.libreoffice.org/11077 Reviewed-by: Thomas Arnhold <thomas@arnhold.org> Tested-by: Thomas Arnhold <thomas@arnhold.org>
Diffstat (limited to 'svx')
-rw-r--r--svx/sdi/svx.sdi2
-rw-r--r--svx/source/gallery2/galbrws.cxx18
-rw-r--r--svx/source/tbxctrls/tbcontrl.cxx13
3 files changed, 5 insertions, 28 deletions
diff --git a/svx/sdi/svx.sdi b/svx/sdi/svx.sdi
index 88885bbb3b6a..10b254ff6554 100644
--- a/svx/sdi/svx.sdi
+++ b/svx/sdi/svx.sdi
@@ -4885,7 +4885,7 @@ SfxBoolItem AutoColorInvalid SID_ATTR_AUTO_COLOR_INVALID
]
-SfxBoolItem Gallery SID_GALLERY
+SfxVoidItem Gallery SID_GALLERY
[
/* flags: */
diff --git a/svx/source/gallery2/galbrws.cxx b/svx/source/gallery2/galbrws.cxx
index bb5c7fb450a1..7bec886eff94 100644
--- a/svx/source/gallery2/galbrws.cxx
+++ b/svx/source/gallery2/galbrws.cxx
@@ -34,24 +34,6 @@
#include <boost/bind.hpp>
-GalleryChildWindow::GalleryChildWindow( Window* _pParent, sal_uInt16 nId, SfxBindings* pBindings, SfxChildWinInfo* pInfo ) :
- SfxChildWindow( _pParent, nId )
-{
-
- pWindow = new GalleryBrowser( pBindings, this, _pParent, GAL_RES( RID_SVXDLG_GALLERYBROWSER ) );
- eChildAlignment = SFX_ALIGN_TOP;
- ( (GalleryBrowser*) pWindow )->Initialize( pInfo );
-};
-
-GalleryChildWindow::~GalleryChildWindow()
-{
-}
-
-SFX_IMPL_DOCKINGWINDOW_WITHID( GalleryChildWindow, SID_GALLERY )
-
-// - GalleryBrowser -
-
-
GalleryBrowser::GalleryBrowser(
SfxBindings* _pBindings,
SfxChildWindow* pCW,
diff --git a/svx/source/tbxctrls/tbcontrl.cxx b/svx/source/tbxctrls/tbcontrl.cxx
index 5124dc199ef3..4c2e985c6942 100644
--- a/svx/source/tbxctrls/tbcontrl.cxx
+++ b/svx/source/tbxctrls/tbcontrl.cxx
@@ -57,6 +57,7 @@
#include <svx/svxitems.hrc>
#include "helpid.hrc"
#include <sfx2/htmlmode.hxx>
+#include <sfx2/sidebar/Sidebar.hxx>
#include <svx/xtable.hxx>
#include <editeng/fontitem.hxx>
#include <editeng/fhgtitem.hxx>
@@ -363,15 +364,9 @@ void SvxStyleBox_Impl::Select()
{
SfxViewFrame* pViewFrm = SfxViewFrame::Current();
DBG_ASSERT( pViewFrm, "SvxStyleBox_Impl::Select(): no viewframe" );
- pViewFrm->ShowChildWindow( SID_STYLE_DESIGNER );
- SfxChildWindow* pChildWin = pViewFrm->GetChildWindow( SID_STYLE_DESIGNER );
- if ( pChildWin && pChildWin->GetWindow() )
- {
- static_cast< SfxTemplateDialogWrapper* >( pChildWin )->SetParagraphFamily();
- static_cast< SfxDockingWindow* >( pChildWin->GetWindow() )->AutoShow( true );
- Application::PostUserEvent(
- STATIC_LINK( 0, SvxStyleBox_Impl, FocusHdl_Impl ), pChildWin->GetWindow() );
- }
+ pViewFrm->ShowChildWindow( SID_SIDEBAR );
+ ::sfx2::sidebar::Sidebar::ShowPanel("StyleListPanel",
+ pViewFrm->GetFrame().GetFrameInterface());
bDoIt = false;
}
}