summaryrefslogtreecommitdiff
path: root/sfx2/source/toolbox
diff options
context:
space:
mode:
authorMaxim Monastirsky <momonasmon@gmail.com>2015-07-17 10:12:06 +0300
committerSzymon Kłos <eszkadev@gmail.com>2015-07-24 12:28:46 +0200
commit24ad90870931b9aa4482469f0d03cb4fc1df9feb (patch)
tree0230a5e4655dd98877baf4f72fc8a8eb6f81aeb2 /sfx2/source/toolbox
parent4963c4b5cf23e9bbc84ee4e3551de9d0100f6c92 (diff)
Don't show open remote entry in the recent doc menu
We use the same menu controller for both the Open toolbar button and the Recent Documents menu. While it's reasonable to put the open remote file command under the open button, it has nothing to do with recent documents, so it shouldn't appear there. Also don't add the "No Document" entry in case the open remote entry is visible. The whole point of the "No Document" entry is that we can't leave the menu empty, but if there is another visible entry, it's not needed. Change-Id: Ibefbdc6dc7d1d49f555d8ee23f67b47eba19b445 Signed-off-by: Szymon Kłos <eszkadev@gmail.com>
Diffstat (limited to 'sfx2/source/toolbox')
-rw-r--r--sfx2/source/toolbox/tbxitem.cxx6
1 files changed, 5 insertions, 1 deletions
diff --git a/sfx2/source/toolbox/tbxitem.cxx b/sfx2/source/toolbox/tbxitem.cxx
index ed53d9693ce6..29061001dc61 100644
--- a/sfx2/source/toolbox/tbxitem.cxx
+++ b/sfx2/source/toolbox/tbxitem.cxx
@@ -1153,6 +1153,10 @@ VclPtr<SfxPopupWindow> SfxRecentFilesToolBoxControl::CreatePopupWindow()
aPropValue.Value <<= m_xFrame;
aArgs[1] <<= aPropValue;
+ aPropValue.Name = "ShowRemote";
+ aPropValue.Value <<= true;
+ aArgs[2] <<= aPropValue;
+
uno::Reference< frame::XPopupMenuController > xPopupController( m_xContext->getServiceManager()->createInstanceWithArgumentsAndContext(
"com.sun.star.comp.framework.RecentFilesMenuController", aArgs, m_xContext ), UNO_QUERY );
@@ -1191,7 +1195,7 @@ VclPtr<SfxPopupWindow> SfxSaveAsToolBoxControl::CreatePopupWindow()
sal_uInt16 nItemId = GetId();
::Rectangle aRect( rBox.GetItemRect( nItemId ) );
- Sequence< Any > aArgs( 2 );
+ Sequence< Any > aArgs( 3 );
PropertyValue aPropValue;
aPropValue.Name = "CommandURL";