[Libreoffice-commits] core.git: Branch 'libreoffice-5-2' - sfx2/source

2017-01-01 Thread Julien Nabet
 sfx2/source/dialog/dinfdlg.cxx |6 --
 1 file changed, 4 insertions(+), 2 deletions(-)

New commits:
commit 342ed30e08ddf625e9c6bb35ebd772b4ec6a213f
Author: Julien Nabet 
Date:   Sat Dec 31 12:29:14 2016 +0100

tdf#105011, tdf#104795: copy string until its end if there's no comma

5  0x2aaab055f81e in rtl::OUString::copy (this=0x7fff29d0, 
beginIndex=3, count=-4) at 
/home/julien/lo/libreoffice/include/rtl/ustring.hxx:2223
6  0x2aaab070acd2 in (anonymous namespace)::GetContentPart 
(_rRawString="CN=timur.davlets...@gmail.com", _rPartId="CN")
at /home/julien/lo/libreoffice/sfx2/source/dialog/dinfdlg.cxx:748
7  0x2aaab070dd85 in SfxDocumentPage::ImplUpdateSignatures 
(this=0x5ca2e0b0) at 
/home/julien/lo/libreoffice/sfx2/source/dialog/dinfdlg.cxx:901

so do the same as GetContentPart from uui/source/secmacrowarnings.cxx
(I suppose we should avoid the redundancy but that's another story)

Change-Id: Ief3ce1cce7035fb572778bdee02a1073b7dfe1c1
Reviewed-on: https://gerrit.libreoffice.org/32530
Tested-by: Jenkins 
Reviewed-by: Julien Nabet 
(cherry picked from commit 5e149b630bd837ca6c8cae609a5c148f25f9ee82)
Reviewed-on: https://gerrit.libreoffice.org/32533
Reviewed-by: Caolán McNamara 
Tested-by: Caolán McNamara 

diff --git a/sfx2/source/dialog/dinfdlg.cxx b/sfx2/source/dialog/dinfdlg.cxx
index c801d58..3ce89ec 100644
--- a/sfx2/source/dialog/dinfdlg.cxx
+++ b/sfx2/source/dialog/dinfdlg.cxx
@@ -745,8 +745,10 @@ namespace
 ++nContStart; // now its start of content, directly after Id
 
 sal_Int32  nContEnd = _rRawString.indexOf( ',', nContStart );
-
-s = _rRawString.copy( nContStart, nContEnd - nContStart );
+if (nContEnd != -1)
+s = _rRawString.copy( nContStart, nContEnd - nContStart );
+else
+s = _rRawString.copy(nContStart);
 }
 
 return s;
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: Branch 'libreoffice-5-2' - sfx2/source

2016-12-14 Thread Stephan Bergmann
 sfx2/source/view/classificationhelper.cxx |2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit 01892beebfa1df58452b2bbc04fb2577e1627c22
Author: Stephan Bergmann 
Date:   Tue Dec 13 19:34:00 2016 +0100

That's probably not meant to be a C++ reference to a uno::Reference

...as introduced with e75f6e549eb825c310d16d11babf0fba5ee7fd7a "sfx2: make
SfxClassificationHelper not require a full doc shell".  Made
CppunitTest_sfx2_classification crash now when dereferencing
m_xDocumentProperties in
SfxClassificationHelper::Impl::pushToDocumentProperties, when built with a
recent Clang trunk build.

Change-Id: Id0b7fa0627b9642f748f07d7dfa05353114225fa
(cherry picked from commit e90b004a41153770e672bb1d4524852499ab0ca5)
Reviewed-on: https://gerrit.libreoffice.org/32003
Tested-by: Jenkins 
Reviewed-by: Michael Stahl 

diff --git a/sfx2/source/view/classificationhelper.cxx 
b/sfx2/source/view/classificationhelper.cxx
index 4560057..0e6f048 100644
--- a/sfx2/source/view/classificationhelper.cxx
+++ b/sfx2/source/view/classificationhelper.cxx
@@ -336,7 +336,7 @@ public:
 std::map 
m_aCategory;
 /// Possible categories of a policy to choose from.
 std::vector m_aCategories;
-const uno::Reference& m_xDocumentProperties;
+uno::Reference m_xDocumentProperties;
 
 explicit Impl(const uno::Reference& 
xDocumentProperties);
 void parsePolicy();
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: Branch 'libreoffice-5-2' - sfx2/source

2016-12-09 Thread Caolán McNamara
 sfx2/source/sidebar/Panel.cxx |4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

New commits:
commit 3e60ccb74ac6589e14a479c6646c63a4e5ac4e35
Author: Caolán McNamara 
Date:   Fri Dec 9 11:09:21 2016 +

Related: rhbz#1397939 crash with null pSidebarController

Change-Id: I7627ff30564b2de61669c71dafd15e7b1778b5c6
(cherry picked from commit f5edbb4158e86bfea7267115395b64e60fd61dc7)
(cherry picked from commit 5768416761756a386cba54314f783cb9c0d0d093)
Reviewed-on: https://gerrit.libreoffice.org/31787
Tested-by: Jenkins 
Reviewed-by: Markus Mohrhard 

diff --git a/sfx2/source/sidebar/Panel.cxx b/sfx2/source/sidebar/Panel.cxx
index 9c05dde..d5c6b78 100644
--- a/sfx2/source/sidebar/Panel.cxx
+++ b/sfx2/source/sidebar/Panel.cxx
@@ -115,14 +115,14 @@ void Panel::SetUIElement (const 
Reference& rxElement)
 
 void Panel::SetExpanded (const bool bIsExpanded)
 {
-SidebarController* pSidebarController= 
SidebarController::GetSidebarControllerForFrame(mxFrame);
+SidebarController* pSidebarController = 
SidebarController::GetSidebarControllerForFrame(mxFrame);
 
 if (mbIsExpanded != bIsExpanded)
 {
 mbIsExpanded = bIsExpanded;
 maDeckLayoutTrigger();
 
-if (maContextAccess)
+if (maContextAccess && pSidebarController)
 {
 pSidebarController->GetResourceManager()->StorePanelExpansionState(
 msPanelId,
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: Branch 'libreoffice-5-2' - sfx2/source

2016-12-05 Thread Caolán McNamara
 sfx2/source/control/unoctitm.cxx |   12 ++--
 1 file changed, 10 insertions(+), 2 deletions(-)

New commits:
commit a2e1f2749ee446e3be87e6bb8eacc26376f1f34b
Author: Caolán McNamara 
Date:   Fri Dec 2 14:21:46 2016 +

usageinfo causes one of our more frequent fedora 25 crashes


https://retrace.fedoraproject.org/faf/problems/bthash/?bth=17ba9a57f40d5ca29778866a9f96c1c0dfc7593c=2f1801e44e9cb0be2b013624521fb0959dc2c73a=5e8a1e07503f53b13b3a6779084f8b0637aaf5a7=8033013a2ce586bccc23245583fa86ef4a761dce=975271167132418534cb07336601efb5b0c711f0=de75c2ad7917bc889d6307b152f79d34e79ce74d

Change-Id: Ie93afa476eca9fdbf7ea17ff0189fbaa493a5531
(cherry picked from commit a064f1226b9864f0d0ef6d969f2ae53cc413eb51)
Reviewed-on: https://gerrit.libreoffice.org/31554
Tested-by: Jenkins 
Reviewed-by: Michael Stahl 

diff --git a/sfx2/source/control/unoctitm.cxx b/sfx2/source/control/unoctitm.cxx
index 7ed25a4..5fa526b 100644
--- a/sfx2/source/control/unoctitm.cxx
+++ b/sfx2/source/control/unoctitm.cxx
@@ -452,6 +452,9 @@ class UsageInfo {
 /// Command vs. how many times it was used
 UsageMap maUsage;
 
+/// config path, get it long before atexit time
+OUString msConfigPath;
+
 public:
 UsageInfo() : mbIsCollecting(false)
 {
@@ -469,7 +472,12 @@ public:
 void save();
 
 /// Modify the flag whether we are collecting.
-void setCollecting(bool bIsCollecting) { mbIsCollecting = bIsCollecting; }
+void setCollecting(bool bIsCollecting)
+{
+mbIsCollecting = bIsCollecting;
+if (mbIsCollecting)
+msConfigPath = SvtPathOptions().GetConfigPath();
+}
 };
 
 void UsageInfo::increment(const OUString )
@@ -487,7 +495,7 @@ void UsageInfo::save()
 if (!mbIsCollecting)
 return;
 
-OUString path(SvtPathOptions().GetConfigPath());
+OUString path(msConfigPath);
 path += "usage/";
 osl::Directory::createPath(path);
 
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: Branch 'libreoffice-5-2' - sfx2/source

2016-11-07 Thread Justin Luth
 sfx2/source/doc/docfile.cxx |3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

New commits:
commit 07b1e1025653c05f6422278da793261cbff42c71
Author: Justin Luth 
Date:   Wed Oct 26 19:59:32 2016 +0300

tdf#62625 - reopen temp stream to readBasic .xls VBA

InputStream was closed, but an InStream was still open,
so InputStream was not being re-created.
Apparently either most web protocols aren't properly closed,
or else a second stream is needed for these kinds of protocols.

Required on Linux for INetProtocol::Http, Generic, Smb, Sftp
and perhaps more.  Required on Windows/Mac for Remote WebDAV
(although http://xx/xx.xls worked)

Change-Id: Icb732518fb8185168c5ed1cb9e32c84c9d8d71bb
Reviewed-on: https://gerrit.libreoffice.org/30303
Tested-by: Jenkins 
Reviewed-by: Stephan Bergmann 
(cherry picked from commit d9c7b0a01162254240a1328fa594991eccf6bc65)
Reviewed-on: https://gerrit.libreoffice.org/30662
Reviewed-by: Justin Luth 

diff --git a/sfx2/source/doc/docfile.cxx b/sfx2/source/doc/docfile.cxx
index f681bbf..a792860 100644
--- a/sfx2/source/doc/docfile.cxx
+++ b/sfx2/source/doc/docfile.cxx
@@ -2368,7 +2368,8 @@ void SfxMedium::GetLockingStream_Impl()
 
 void SfxMedium::GetMedium_Impl()
 {
-if ( !pImpl->m_pInStream )
+if ( !pImpl->m_pInStream
+|| (pImpl->bIsTemp && !pImpl->xInputStream.is() && 
!pImpl->m_xInputStreamToLoadFrom.is() && !pImpl->xStream.is() && 
!pImpl->m_xLockingStream.is() ) )
 {
 pImpl->bDownloadDone = false;
 Reference< css::task::XInteractionHandler > xInteractionHandler = 
GetInteractionHandler();
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: Branch 'libreoffice-5-2' - sfx2/source

2016-10-18 Thread Caolán McNamara
 sfx2/source/doc/templatedlg.cxx |   10 ++
 1 file changed, 6 insertions(+), 4 deletions(-)

New commits:
commit 065d396c10b69feaaf7cbff8803bf1bf5bd3acaf
Author: Caolán McNamara 
Date:   Tue Oct 18 09:59:33 2016 +0100

Resolves: tdf#101590 cannot interact with filepicker from import category

the post-execute category dialog is picked as the toplevel parent, and
gtk3 vclplug will grab events to that hierarchy, but can't interact with
them in this state. Just dispose the category dialog so its not a
candidate for the file dialog parent.

Change-Id: I063fc6d687d556db229e2e200bb280a6cd3425f5
(cherry picked from commit c7ac773480bfbfcaac15c9bfdeeab400028a96d4)
Reviewed-on: https://gerrit.libreoffice.org/29993
Tested-by: Jenkins 
Reviewed-by: Miklos Vajna 

diff --git a/sfx2/source/doc/templatedlg.cxx b/sfx2/source/doc/templatedlg.cxx
index a13c05b..7ace61f 100644
--- a/sfx2/source/doc/templatedlg.cxx
+++ b/sfx2/source/doc/templatedlg.cxx
@@ -659,10 +659,11 @@ IMPL_LINK_NOARG_TYPED(SfxTemplateManagerDlg, 
MoveClickHdl, Button*, void)
 
 size_t nItemId = 0;
 
-if(aDlg->Execute() == RET_OK)
+if (aDlg->Execute() == RET_OK)
 {
 OUString sCategory = aDlg->GetSelectedCategory();
 bool bIsNewCategory = aDlg->IsNewCategoryCreated();
+aDlg.disposeAndClear();
 if(bIsNewCategory)
 {
 if (!sCategory.isEmpty())
@@ -710,10 +711,11 @@ IMPL_LINK_NOARG_TYPED(SfxTemplateManagerDlg, 
ImportClickHdl, Button*, void)
 ScopedVclPtrInstance aDlg;
 aDlg->SetCategoryLBEntries(mpLocalView->getFolderNames());
 
-if(aDlg->Execute() == RET_OK)
+if (aDlg->Execute() == RET_OK)
 {
 OUString sCategory = aDlg->GetSelectedCategory();
 bool bIsNewCategory = aDlg->IsNewCategoryCreated();
+aDlg.disposeAndClear();
 if(bIsNewCategory)
 {
 if(mpCurView->createRegion(sCategory))
@@ -1264,10 +1266,10 @@ void SfxTemplateManagerDlg::OnCategoryDelete()
 aDlg->SetText(SfxResId(STR_CATEGORY_DELETE).toString());
 aDlg->SetSelectLabelText(SfxResId(STR_CATEGORY_SELECT).toString());
 
-if(aDlg->Execute() == RET_OK)
+if (aDlg->Execute() == RET_OK)
 {
 OUString sCategory = aDlg->GetSelectedCategory();
-aDlg->Close();
+aDlg.disposeAndClear();
 ScopedVclPtrInstance< MessageDialog > popupDlg(this, 
SfxResId(STR_QMSG_SEL_FOLDER_DELETE),
 VCL_MESSAGE_QUESTION, VCL_BUTTONS_YES_NO);
 
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: Branch 'libreoffice-5-2' - sfx2/source

2016-10-17 Thread Mike Kaganski
 sfx2/source/doc/docfile.cxx |6 ++
 1 file changed, 2 insertions(+), 4 deletions(-)

New commits:
commit 4af1ac3a9a773e4875712dd2f43f06a1a4edcc19
Author: Mike Kaganski 
Date:   Sat Oct 15 00:26:09 2016 +1000

tdf#92817: re-implement empty lockfile fix

As stated in original commit 8d411a4a1ef6844c00bc714f8b144d3729e4f4e8,
An empty lock file doesn't have OOOUSERNAME and SYSUSERNAME.

Change-Id: I17fc6d3375f411749fcbbe80535beb8ba53a0e71
Reviewed-on: https://gerrit.libreoffice.org/29836
Tested-by: Jenkins 
Reviewed-by: Miklos Vajna 

diff --git a/sfx2/source/doc/docfile.cxx b/sfx2/source/doc/docfile.cxx
index 288632c..f681bbf 100644
--- a/sfx2/source/doc/docfile.cxx
+++ b/sfx2/source/doc/docfile.cxx
@@ -830,10 +830,8 @@ sal_Int8 SfxMedium::ShowLockedDocumentDialog( const 
LockFileEntry& aData, bool b
 {
 sal_Int8 nResult = LOCK_UI_NOLOCK;
 
-if( aData[LockFileComponent::OOOUSERNAME] == 
aData[LockFileComponent::SYSUSERNAME] ||
-  
aData[LockFileComponent::OOOUSERNAME].isEmpty()  ||
-  
aData[LockFileComponent::SYSUSERNAME].isEmpty()
-)
+// tdf#92817: Simple check for empty lock file that needs to be deleted
+if( aData[LockFileComponent::OOOUSERNAME].isEmpty() && 
aData[LockFileComponent::SYSUSERNAME].isEmpty() )
 bOwnLock=true;
 
 // show the interaction regarding the document opening
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: Branch 'libreoffice-5-2' - sfx2/source

2016-09-12 Thread Yousuf Philips
 sfx2/source/dialog/backingwindow.cxx |5 -
 1 file changed, 5 deletions(-)

New commits:
commit 937a284ebfe1261e4b7666e4c1d2b8f9677c1763
Author: Yousuf Philips 
Date:   Sat Sep 10 19:19:46 2016 +0400

tdf#101812 Dont switch to templates view when opening template manager

Change-Id: I3671de21b04f50045c1b7d209e745e2678b7c6f9
Reviewed-on: https://gerrit.libreoffice.org/28808
Tested-by: Jenkins 
Reviewed-by: Samuel Mehrbrodt 

diff --git a/sfx2/source/dialog/backingwindow.cxx 
b/sfx2/source/dialog/backingwindow.cxx
index 350dc4a..6cbd43b 100644
--- a/sfx2/source/dialog/backingwindow.cxx
+++ b/sfx2/source/dialog/backingwindow.cxx
@@ -619,11 +619,6 @@ IMPL_LINK_TYPED( BackingWindow, MenuSelectHdl, 
MenuButton*, pButton, void )
 dispatchURL( ".uno:NewDoc", OUString(), xFrame, aArgs );
 
 }
-
-mpAllRecentThumbnails->Hide();
-mpLocalView->Show();
-mpLocalView->reload();
-mpLocalView->GrabFocus();
 }
 
 IMPL_LINK_TYPED(BackingWindow, CreateContextMenuHdl, ThumbnailViewItem*, 
pItem, void)
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: Branch 'libreoffice-5-2' - sfx2/source

2016-09-12 Thread Caolán McNamara
 sfx2/source/dialog/templdlg.cxx |2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit c0d5a89b081b81261b7f4b306e64cfb6ce6e950a
Author: Caolán McNamara 
Date:   Fri Sep 9 10:50:37 2016 +0100

Resolves: tdf#101921 no tab navigation in style sidebar

Change-Id: I737ed446d0ead9d748873fec90b62dcced35e328
Reviewed-on: https://gerrit.libreoffice.org/28767
Reviewed-by: Caolán McNamara 
Tested-by: Caolán McNamara 
(cherry picked from commit 3d7d318914bd69262da647e0db23ec47d6550afe)
Reviewed-on: https://gerrit.libreoffice.org/28770
Tested-by: Jenkins 
Reviewed-by: Miklos Vajna 

diff --git a/sfx2/source/dialog/templdlg.cxx b/sfx2/source/dialog/templdlg.cxx
index ca53f4c..b81e561 100644
--- a/sfx2/source/dialog/templdlg.cxx
+++ b/sfx2/source/dialog/templdlg.cxx
@@ -340,7 +340,7 @@ std::unique_ptr 
SfxActionListBox::CreateContextMenu()
 }
 
 SfxTemplatePanelControl::SfxTemplatePanelControl(SfxBindings* pBindings, 
vcl::Window* pParentWindow)
-: Window(pParentWindow)
+: Window(pParentWindow, WB_DIALOGCONTROL)
 , pImpl(new SfxTemplateDialog_Impl(pBindings, this))
 , mpBindings(pBindings)
 {
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: Branch 'libreoffice-5-2' - sfx2/source

2016-08-09 Thread Markus Mohrhard
 sfx2/source/appl/workwin.cxx |3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

New commits:
commit 152de33c612f219471c96975f4ab6fd24d95dc1b
Author: Markus Mohrhard 
Date:   Mon Aug 8 05:36:59 2016 +0200

no range based for loop when container is modified, tdf#100870, tdf#101320

This crash has been responsible for around 20% of the 5.2.0.4 crashes
with backtraces for the modification of the container similar to:

sxlo.dll!SfxWorkWindow::SetChildWindowVisible_Impl(unsigned long lId, 
bool bEnabled, unsigned short nMode) Line 1834C++
 sfxlo.dll!SfxDispatcher::Update_Impl_(bool bUIActive, bool bIsMDIApp, 
bool bIsIPOwner, SfxWorkWindow * pTaskWin) Line 1452C++
 sfxlo.dll!SfxDispatcher::Update_Impl(bool bForce) Line 1326C++
 sfxlo.dll!SfxApplication::SetViewFrame_Impl(SfxViewFrame * pFrame) 
Line 372C++
 sfxlo.dll!SfxViewFrame::SetViewFrame(SfxViewFrame * pFrame) Line 3138  
  C++
 sfxlo.dll!SfxViewFrame::MakeActive_Impl(bool bGrabFocus) Line 1697
C++
 sfxlo.dll!SfxFrameWindow_Impl::Notify(NotifyEvent & rNEvt) Line 111
C++
 vcllo.dll!vcl::Window::CompatNotify(NotifyEvent & rNEvt) Line 3747
C++
 vcllo.dll!vcl::Window::Notify(NotifyEvent & rNEvt) Line 198C++
 vcllo.dll!DockingWindow::Notify(NotifyEvent & rNEvt) Line 633C++
 vcllo.dll!vcl::Window::CompatNotify(NotifyEvent & rNEvt) Line 3747
C++
 vcllo.dll!vcl::Window::Notify(NotifyEvent & rNEvt) Line 198C++
 vcllo.dll!DockingWindow::Notify(NotifyEvent & rNEvt) Line 633C++
 sfxlo.dll!SfxDockingWindow::Notify(NotifyEvent & rEvt) Line 1655C++
 vcllo.dll!vcl::Window::CompatNotify(NotifyEvent & rNEvt) Line 3747
C++
 vcllo.dll!vcl::Window::Notify(NotifyEvent & rNEvt) Line 198C++
 vcllo.dll!vcl::Window::CompatNotify(NotifyEvent & rNEvt) Line 3747
C++
 vcllo.dll!vcl::Window::Notify(NotifyEvent & rNEvt) Line 198C++
 vcllo.dll!vcl::Window::CompatNotify(NotifyEvent & rNEvt) Line 3747
C++
 vcllo.dll!vcl::Window::Notify(NotifyEvent & rNEvt) Line 198C++
 vcllo.dll!Control::Notify(NotifyEvent & rNEvt) Line 274C++
 vcllo.dll!vcl::Window::CompatNotify(NotifyEvent & rNEvt) Line 3747
C++
 vcllo.dll!vcl::Window::GetFocus() Line 1842C++
 svtlo.dll!SvTreeListBox::GetFocus() Line 2096C++
 swlo.dll!SwContentTree::GetFocus() Line 2571C++
 vcllo.dll!vcl::Window::CompatGetFocus() Line 3716C++
 vcllo.dll!vcl::Window::ImplGrabFocus(GetFocusFlags nFlags) Line 384
C++
 vcllo.dll!vcl::Window::GrabFocus() Line 3004C++
 swlo.dll!SwNavigationPI::SwNavigationPI(SfxBindings * _pBindings, 
SfxChildWindowContext * pCw, vcl::Window * pParent) Line 835C++
 swlo.dll!VclPtr::Create(SfxBinsfdings * & , SwNavigationChild * const && , 
vcl::Window * & ) Line 131C++
 swlo.dll!SwNavigationChild::SwNavigationChild(vcl::Window * pParent, 
unsigned short nId, SfxBindings * _pBindings, SfxChildWinInfo * __formal) Line 
1306C++
 swlo.dll!SwNavigationChild::CreateImpl(vcl::Window * pParent, 
SfxBindings * pBindings, SfxChildWinInfo * pInfo) Line 69C++
 sfxlo.dll!SfxChildWindow::CreateContext(unsigned short nContextId, 
SfxBindings & rBindings) Line 457C++
 sfxlo.dll!SfxWorkWindow::CreateChildWin_Impl(SfxChildWin_Impl * pCW, 
bool bSetFocus) Line 1436C++
 sfxlo.dll!SfxWorkWindow::UpdateChildWindows_Impl() Line 1328C++
 sfxlo.dll!SfxWorkWindow::UpdateObjectBars_Impl() Line 1283C++
 sfxlo.dll!SfxFrameWorkWin_Impl::UpdateObjectBars_Impl() Line 1114
C++
 sfxlo.dll!SfxDispatcher::Update_Impl(bool bForce) Line 1329C++
 sfxlo.dll!SfxBaseController::ConnectSfxFrame_Impl(const 
SfxBaseController::ConnectSfxFrame i_eConnect) Line 1326C++
 sfxlo.dll!SfxBaseController::attachFrame(const 
com::sun::star::uno::Reference & xFrame) Line 
584C++
 sfxlo.dll!`anonymous 
namespace'::SfxFrameLoader_Impl::impl_createDocumentView(const 
com::sun::star::uno::Reference & i_rModel, 
const com::sun::star::uno::Reference & i_rFrame, 
const comphelper::NamedValueCollection & i_rViewFactoryArgs, const 
rtl::OUString & i_rViewName) Line 604C++
 sfxlo.dll!`anonymous namespace'::SfxFrameLoader_Impl::load(const 
com::sun::star::uno::Sequence & rArgs, 
const com::sun::star::uno::Reference & 
_rTargetFrame) Line 721C++
 fwklo.dll!framework::LoadEnv::impl_loadContent() Line 1122C++
 fwklo.dll!framework::LoadEnv::startLoading() Line 379C++
 fwklo.dll!framework::LoadDispatcher::impl_dispatch(const 
com::sun::star::util::URL & rURL, const 
com::sun::star::uno::Sequence & 
lArguments, const 
com::sun::star::uno::Reference 
& xListener) Line 116C++
 

[Libreoffice-commits] core.git: Branch 'libreoffice-5-2' - sfx2/source

2016-08-03 Thread Giuseppe Castagno
 sfx2/source/doc/docfile.cxx |   10 ++
 1 file changed, 10 insertions(+)

New commits:
commit c4c30cfac570aeb0f8ac91b36b986e438e2811bc
Author: Giuseppe Castagno 
Date:   Sat Jul 30 11:53:34 2016 +0200

Fix the WebDAV lock owner name shown on file locked dialog UI

Probably due to 8d411a4a1ef6844c00bc714f8b144d3729e4f4e8.

See comment in the added code for details.

Change-Id: I3e8a856a715385ed2ab1d9ecda31dd25e05e6c59
Reviewed-on: https://gerrit.libreoffice.org/27716
Tested-by: Jenkins 
Reviewed-by: Giuseppe Castagno 
(cherry picked from commit 97353e5c43815b45a6f365ccaea474899683d38e)
Reviewed-on: https://gerrit.libreoffice.org/27728
Reviewed-by: Miklos Vajna 

diff --git a/sfx2/source/doc/docfile.cxx b/sfx2/source/doc/docfile.cxx
index 6a0c4c9..288632c 100644
--- a/sfx2/source/doc/docfile.cxx
+++ b/sfx2/source/doc/docfile.cxx
@@ -1006,7 +1006,17 @@ void SfxMedium::LockOrigFileOnDemand( bool bLoading, 
bool bNoUI )
 css::ucb::Lock aLock = aLocks[0];
 OUString aOwner;
 if(aLock.Owner >>= aOwner)
+{
+// This solution works right when the LO 
user name and the WebDAV user
+// name are the same.
+// A better thing to do would be to obtain 
the 'real' WebDAV user name,
+// but that's not possible from a WebDAV 
UCP provider client.
+LockFileEntry aOwnData = 
svt::LockFileCommon::GenerateOwnEntry();
+// use the current LO user name as the 
system name
+aLockData[LockFileComponent::SYSUSERNAME] 
= aOwnData[LockFileComponent::SYSUSERNAME];
+// we need to display the WebDAV user name 
owning the lock, not the local one
 aLockData[LockFileComponent::OOOUSERNAME] 
= aOwner;
+}
 }
 
 if ( !bResult && !bNoUI )
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: Branch 'libreoffice-5-2' - sfx2/source

2016-07-20 Thread Olivier Hallot
 sfx2/source/view/view.src |3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

New commits:
commit 7abca37660487336e6da123bd13f8f9e0ef9e4a7
Author: Olivier Hallot 
Date:   Wed Jun 15 10:31:23 2016 -0300

tdf#100351 attempt to fix untranslatable string

string "National Security" was not ported to pootle.

Change-Id: I35b4659f5b5e239e86a7c0517c5a9a719a2aa612
Reviewed-on: https://gerrit.libreoffice.org/26309
Tested-by: Jenkins 
Reviewed-by: Olivier Hallot 
Tested-by: Olivier Hallot 
(cherry picked from commit ee24e7f2b689bf0f63ba618fc7ee7ac6bc644172)
Reviewed-on: https://gerrit.libreoffice.org/27332
Reviewed-by: Christian Lohmaier 
Tested-by: Christian Lohmaier 

diff --git a/sfx2/source/view/view.src b/sfx2/source/view/view.src
index 16b3e59..8f0d6c6 100644
--- a/sfx2/source/view/view.src
+++ b/sfx2/source/view/view.src
@@ -114,9 +114,8 @@ String STR_CLASSIFIED_INTELLECTUAL_PROPERTY
 String STR_CLASSIFIED_NATIONAL_SECURITY
 {
 Text [ en-US ] = "National Security:" ;
-}
+};
 
-;
 String STR_CLASSIFIED_EXPORT_CONTROL
 {
 Text [ en-US ] = "Export Control:" ;
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: Branch 'libreoffice-5-2' - sfx2/source vcl/source

2016-07-18 Thread Miklos Vajna
 sfx2/source/view/classificationcontroller.cxx |4 +++-
 vcl/source/window/toolbox2.cxx|6 ++
 2 files changed, 9 insertions(+), 1 deletion(-)

New commits:
commit 1cf7025df7f825326ce57b4e2817ee9544f059b7
Author: Miklos Vajna 
Date:   Tue Jul 12 10:13:22 2016 +0200

tdf#100600 sfx2 classification: never replace the control with label

Thanks to Caolán McNamara for pointing out where is the condition of the
replacement in VCL.

(cherry picked from commit 8192da8e4de7a058ef95253f992f4143f83fa0f1)

Change-Id: I7e1ef4a016a37b25e084c4c6467a42ca557069a4
Reviewed-on: https://gerrit.libreoffice.org/27214
Tested-by: Jenkins 
Reviewed-by: Caolán McNamara 
Tested-by: Caolán McNamara 

diff --git a/sfx2/source/view/classificationcontroller.cxx 
b/sfx2/source/view/classificationcontroller.cxx
index 1e932c8..f37490c 100644
--- a/sfx2/source/view/classificationcontroller.cxx
+++ b/sfx2/source/view/classificationcontroller.cxx
@@ -234,7 +234,9 @@ void ClassificationCategoriesController::removeEntries()
 }
 
 ClassificationControl::ClassificationControl(vcl::Window* pParent)
-: Window(pParent, WB_DIALOGCONTROL)
+// WB_NOLABEL means here that the control won't be replaced with a label
+// when it wouldn't fit the available space.
+: Window(pParent, WB_DIALOGCONTROL | WB_NOLABEL)
 {
 m_pLabels[SfxClassificationPolicyType::IntellectualProperty] = 
VclPtr::Create(this, WB_CENTER);
 m_pLabels[SfxClassificationPolicyType::NationalSecurity] = 
VclPtr::Create(this, WB_CENTER);
diff --git a/vcl/source/window/toolbox2.cxx b/vcl/source/window/toolbox2.cxx
index 7a93e50..a7fc473 100644
--- a/vcl/source/window/toolbox2.cxx
+++ b/vcl/source/window/toolbox2.cxx
@@ -214,6 +214,12 @@ Size ImplToolItem::GetSize( bool bHorz, bool 
bCheckMaxWidth, long maxWidth, cons
 // get size of item window and check if it fits
 // no windows in vertical toolbars (the default is 
mbShowWindow=false)
 Size aWinSize = mpWindow->GetSizePixel();
+
+if (mpWindow->GetStyle() & WB_NOLABEL)
+// Window wants no label? Then don't check width, it'll be just
+// clipped.
+bCheckMaxWidth = false;
+
 if ( !bCheckMaxWidth || (aWinSize.Width() <= maxWidth) )
 {
 aSize.Width()   = aWinSize.Width();
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: Branch 'libreoffice-5-2' - sfx2/source

2016-07-17 Thread Caolán McNamara
 sfx2/source/dialog/dinfdlg.cxx |4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

New commits:
commit 4dc52f44d5098c3f367fe5414e3dfbbdaef81600
Author: Caolán McNamara 
Date:   Sat Jul 16 21:58:31 2016 +0100

Resolves: tdf#100910 yes/no doesn't clear bg

Change-Id: If6a31cefe7137d338a57b5a28dfda63809957190
(cherry picked from commit 997c7accd393bc665538403a5738ce1a626d9665)
Reviewed-on: https://gerrit.libreoffice.org/27259
Tested-by: Jenkins 
Reviewed-by: Markus Mohrhard 

diff --git a/sfx2/source/dialog/dinfdlg.cxx b/sfx2/source/dialog/dinfdlg.cxx
index eb4039f..b78c09b 100644
--- a/sfx2/source/dialog/dinfdlg.cxx
+++ b/sfx2/source/dialog/dinfdlg.cxx
@@ -1236,10 +1236,10 @@ 
CustomPropertiesYesNoButton::CustomPropertiesYesNoButton( vcl::Window* pParent,
 m_aNoButton ( VclPtr::Create(this, ResId( RB_PROPERTY_NO, 
*rResId.GetResMgr() )) )
 {
 FreeResource();
-Wallpaper aWall( Color( COL_TRANSPARENT ) );
-SetBackground( aWall );
+SetBackground( Wallpaper( GetSettings().GetStyleSettings().GetFieldColor() 
) );
 SetBorderStyle( WindowBorderStyle::MONO  );
 CheckNo();
+Wallpaper aWall( Color( COL_TRANSPARENT ) );
 m_aYesButton->SetBackground( aWall );
 m_aNoButton->SetBackground( aWall );
 }
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: Branch 'libreoffice-5-2' - sfx2/source

2016-06-21 Thread Miklos Vajna
 sfx2/source/view/classificationhelper.cxx |   14 ++
 1 file changed, 14 insertions(+)

New commits:
commit c9a16da8617634955eacded60083bec7ffd8b58b
Author: Miklos Vajna 
Date:   Tue Jun 21 09:16:26 2016 +0200

tdf#100352 sfx classification: support localized policy files

The example policy is at:

instdir/share/classification/example.xml

If there is a localized version, e.g.:

instdir/share/classification/example_hu-HU.xml

(same syntax as already used for the autocorrect files), then use that
instead of the configured policy.

(cherry picked from commit 1811e656f08ba011a3c2a51cc60e90d2fa58e4c2)

Change-Id: I0369e69f90a633af0676981f0c5760f8477b3c8c
Reviewed-on: https://gerrit.libreoffice.org/26549
Reviewed-by: Miklos Vajna 
Tested-by: Jenkins 
Reviewed-by: Caolán McNamara 
Tested-by: Caolán McNamara 

diff --git a/sfx2/source/view/classificationhelper.cxx 
b/sfx2/source/view/classificationhelper.cxx
index 0c93e93..8a3bc96 100644
--- a/sfx2/source/view/classificationhelper.cxx
+++ b/sfx2/source/view/classificationhelper.cxx
@@ -33,6 +33,7 @@
 #include 
 #include 
 #include 
+#include 
 #include 
 
 using namespace com::sun::star;
@@ -355,6 +356,19 @@ void SfxClassificationHelper::Impl::parsePolicy()
 uno::Reference xComponentContext = 
comphelper::getProcessComponentContext();
 SvtPathOptions aOptions;
 OUString aPath = aOptions.GetClassificationPath();
+
+// See if there is a localized variant next to the configured XML.
+OUString aExtension(".xml");
+if (aPath.endsWith(aExtension))
+{
+OUString aBase = aPath.copy(0, aPath.getLength() - 
aExtension.getLength());
+const LanguageTag& rLanguageTag = 
Application::GetSettings().GetLanguageTag();
+// Expected format is "_xx-XX.xml".
+OUString aLocalized = aBase + "_" + rLanguageTag.getBcp47() + 
aExtension;
+if (FStatHelper::IsDocument(aLocalized))
+aPath = aLocalized;
+}
+
 SvStream* pStream = utl::UcbStreamHelper::CreateStream(aPath, 
StreamMode::READ);
 uno::Reference xInputStream(new 
utl::OStreamWrapper(*pStream));
 xml::sax::InputSource aParserInput;
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: Branch 'libreoffice-5-2' - sfx2/source

2016-06-17 Thread Akshay Deep
 sfx2/source/control/recentdocsview.cxx |6 ++
 1 file changed, 6 insertions(+)

New commits:
commit bcefc1a01507b8b4316e0b5801298c9edb3f75e8
Author: Akshay Deep 
Date:   Fri Jun 17 09:39:01 2016 +0530

tdf#79198 START CENTER: Close button doesn't reappear after being clicked

Change-Id: I23e3aed71eec85e8b8f0aceac125809fd56be4d5
Reviewed-on: https://gerrit.libreoffice.org/26399
Tested-by: Jenkins 
Reviewed-by: Samuel Mehrbrodt 
(cherry picked from commit 27bd030aa033565dfdff56c298c797c80cee5160)
Reviewed-on: https://gerrit.libreoffice.org/26415
Reviewed-by: Akshay Deep 
Tested-by: Akshay Deep 

diff --git a/sfx2/source/control/recentdocsview.cxx 
b/sfx2/source/control/recentdocsview.cxx
index 1d6e0c1..abfc888 100644
--- a/sfx2/source/control/recentdocsview.cxx
+++ b/sfx2/source/control/recentdocsview.cxx
@@ -233,8 +233,14 @@ void RecentDocsView::MouseButtonUp(const MouseEvent& rMEvt)
 ThumbnailViewItem* pItem = ImplGetItem(nPos);
 
 if (pItem && nPos == mnLastMouseDownItem)
+{
 pItem->MouseButtonUp(rMEvt);
 
+ThumbnailViewItem* pNewItem = ImplGetItem(nPos);
+if(pNewItem)
+pNewItem->setHighlight(true);
+}
+
 mnLastMouseDownItem = THUMBNAILVIEW_ITEM_NOTFOUND;
 
 if (pItem)
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: Branch 'libreoffice-5-2' - sfx2/source

2016-06-17 Thread Akshay Deep
 sfx2/source/control/templateabstractview.cxx |5 -
 sfx2/source/control/templatelocalview.cxx|1 +
 sfx2/source/control/templatesearchview.cxx   |8 +++-
 sfx2/source/doc/templatedlg.cxx  |3 ---
 4 files changed, 12 insertions(+), 5 deletions(-)

New commits:
commit edd2f7b4793b29ae1aff05e1e54c957ac0fed15d
Author: Akshay Deep 
Date:   Thu Jun 16 19:18:30 2016 +0530

tdf#100423 Template Manager: ctrl + A and del should work correctly

Change-Id: Ibe0326827e6dacb670bb948ca4f6e9797ab7edeb
Reviewed-on: https://gerrit.libreoffice.org/26374
Reviewed-by: Akshay Deep 
Reviewed-by: Samuel Mehrbrodt 
Tested-by: Samuel Mehrbrodt 
(cherry picked from commit 5b8c86f2a3eb5e092fb96f5ae2eaf58c10c8f4f0)
Reviewed-on: https://gerrit.libreoffice.org/26403
Tested-by: Akshay Deep 

diff --git a/sfx2/source/control/templateabstractview.cxx 
b/sfx2/source/control/templateabstractview.cxx
index a29b4b0..45f644d 100644
--- a/sfx2/source/control/templateabstractview.cxx
+++ b/sfx2/source/control/templateabstractview.cxx
@@ -258,7 +258,10 @@ void TemplateAbstractView::KeyInput( const KeyEvent& rKEvt 
)
 if ( aQueryDlg->Execute() != RET_YES )
 return;
 
-for (ThumbnailViewItem* pItem : mFilteredItemList)
+//copy to avoid changing filtered item list during deletion
+ThumbnailValueItemList mFilteredItemListCopy = mFilteredItemList;
+
+for (ThumbnailViewItem* pItem : mFilteredItemListCopy)
 {
 if (pItem->isSelected())
 {
diff --git a/sfx2/source/control/templatelocalview.cxx 
b/sfx2/source/control/templatelocalview.cxx
index 5374af0..3608334 100644
--- a/sfx2/source/control/templatelocalview.cxx
+++ b/sfx2/source/control/templatelocalview.cxx
@@ -239,6 +239,7 @@ IMPL_LINK_TYPED(TemplateLocalView, ContextMenuSelectHdl, 
Menu*, pMenu, bool)
 break;
 
 maDeleteTemplateHdl.Call(maSelectedItem);
+reload();
 }
 break;
 case MNI_DEFAULT_TEMPLATE:
diff --git a/sfx2/source/control/templatesearchview.cxx 
b/sfx2/source/control/templatesearchview.cxx
index 0767c13..b225b29 100644
--- a/sfx2/source/control/templatesearchview.cxx
+++ b/sfx2/source/control/templatesearchview.cxx
@@ -64,11 +64,17 @@ void TemplateSearchView::KeyInput( const KeyEvent& rKEvt )
 if ( aQueryDlg->Execute() != RET_YES )
 return;
 
-for (ThumbnailViewItem* pItem : mFilteredItemList)
+//copy to avoid changing filtered item list during deletion
+ThumbnailValueItemList mFilteredItemListCopy = mFilteredItemList;
+
+for (ThumbnailViewItem* pItem : mFilteredItemListCopy)
 {
 if (pItem->isSelected())
 {
 maDeleteTemplateHdl.Call(pItem);
+RemoveItem(pItem->mnId);
+
+CalculateItemPositions();
 }
 }
 }
diff --git a/sfx2/source/doc/templatedlg.cxx b/sfx2/source/doc/templatedlg.cxx
index 9e83a73..df1e7bf 100644
--- a/sfx2/source/doc/templatedlg.cxx
+++ b/sfx2/source/doc/templatedlg.cxx
@@ -847,9 +847,6 @@ IMPL_LINK_TYPED(SfxTemplateManagerDlg, DeleteTemplateHdl, 
ThumbnailViewItem*, pI
 OUString aMsg( SfxResId(STR_MSG_ERROR_DELETE_TEMPLATE).toString() );
 ScopedVclPtrInstance::Create(this, 
aMsg.replaceFirst("$1",aDeletedTemplate))->Execute();
 }
-
-if(mpSearchView->IsVisible())
-SearchUpdateHdl(*mpSearchFilter);
 }
 
 IMPL_LINK_TYPED(SfxTemplateManagerDlg, DefaultTemplateHdl, ThumbnailViewItem*, 
pItem, void)
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: Branch 'libreoffice-5-2' - sfx2/source

2016-06-15 Thread Akshay Deep
 sfx2/source/doc/doctempl.cxx |2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit 51034e90af7e7da683598724f9aba90953a67fa5
Author: Akshay Deep 
Date:   Wed Jun 15 12:54:23 2016 +0530

Template Export: Don't overwrite the existing template in a directory

Change-Id: I19470c7eeb961665cb5248861b030479a0796a24
Reviewed-on: https://gerrit.libreoffice.org/26290
Reviewed-by: Samuel Mehrbrodt 
Tested-by: Samuel Mehrbrodt 
(cherry picked from commit 4f61b652323e1bde5c45bc9dece3c61b2f69b83d)
Reviewed-on: https://gerrit.libreoffice.org/26312
Tested-by: Jenkins 
Reviewed-by: Akshay Deep 

diff --git a/sfx2/source/doc/doctempl.cxx b/sfx2/source/doc/doctempl.cxx
index c3d9d34..2ed3fc6 100644
--- a/sfx2/source/doc/doctempl.cxx
+++ b/sfx2/source/doc/doctempl.cxx
@@ -721,7 +721,7 @@ bool SfxDocumentTemplates::CopyTo
 aTransferInfo.MoveData = false;
 aTransferInfo.SourceURL = pSource->GetTargetURL();
 aTransferInfo.NewTitle = aTitle;
-aTransferInfo.NameClash = NameClash::OVERWRITE;
+aTransferInfo.NameClash = NameClash::RENAME;
 
 Any aArg = makeAny( aTransferInfo );
 OUString aCmd( COMMAND_TRANSFER  );
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: Branch 'libreoffice-5-2' - sfx2/source

2016-06-13 Thread Akshay Deep
 sfx2/source/doc/templatedlg.cxx |6 --
 1 file changed, 6 deletions(-)

New commits:
commit 0f9a51344863344082c71005e054094e78bb31aa
Author: Akshay Deep 
Date:   Tue Jun 14 02:12:59 2016 +0530

Code cleanup: No need to explicitly show tooltips in Template Manager

Change-Id: I32b0bb79c38a91cbafb3075963155d3b38b3012a
Reviewed-on: https://gerrit.libreoffice.org/26231
Reviewed-by: Akshay Deep 
Tested-by: Jenkins 
(cherry picked from commit a8bd44573b75d1399257d6f5d052611439607189)
Reviewed-on: https://gerrit.libreoffice.org/26233
Tested-by: Akshay Deep 

diff --git a/sfx2/source/doc/templatedlg.cxx b/sfx2/source/doc/templatedlg.cxx
index fa6c28a..9e83a73 100644
--- a/sfx2/source/doc/templatedlg.cxx
+++ b/sfx2/source/doc/templatedlg.cxx
@@ -380,7 +380,6 @@ void SfxTemplateManagerDlg::fillFolderComboBox()
 }
 mpCBFolder->SelectEntryPos(0);
 mpActionMenu->HideItem(MNI_ACTION_RENAME_FOLDER);
-mpLocalView->ShowTooltips(true);
 }
 
 void SfxTemplateManagerDlg::getApplicationSpecificSettings()
@@ -466,7 +465,6 @@ void SfxTemplateManagerDlg::readSettings ()
 //show all categories
 mpCBFolder->SelectEntryPos(0);
 mpActionMenu->HideItem(MNI_ACTION_RENAME_FOLDER);
-mpLocalView->ShowTooltips(true);
 mpLocalView->showAllTemplates();
 }
 else
@@ -504,7 +502,6 @@ IMPL_LINK_NOARG_TYPED(SfxTemplateManagerDlg, 
SelectApplicationHdl, ListBox&, voi
 mpCurView->showAllTemplates();
 mpCBFolder->SelectEntryPos(0);
 mpActionMenu->HideItem(MNI_ACTION_RENAME_FOLDER);
-mpCurView->ShowTooltips(true);
 }
 
 if(mpSearchView->IsVisible())
@@ -519,13 +516,11 @@ IMPL_LINK_NOARG_TYPED(SfxTemplateManagerDlg, 
SelectRegionHdl, ListBox&, void)
 if(mpCBFolder->GetSelectEntryPos() == 0)
 {
 mpLocalView->showAllTemplates();
-mpLocalView->ShowTooltips(true);
 mpActionMenu->HideItem(MNI_ACTION_RENAME_FOLDER);
 }
 else
 {
 mpLocalView->showRegion(sSelectedRegion);
-mpLocalView->ShowTooltips(false);
 mpActionMenu->ShowItem(MNI_ACTION_RENAME_FOLDER);
 }
 }
@@ -1255,7 +1250,6 @@ void SfxTemplateManagerDlg::OnCategoryRename()
 
 mpLocalView->reload();
 mpLocalView->showRegion(aName);
-mpLocalView->ShowTooltips(true);
 }
 else
 {
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: Branch 'libreoffice-5-2' - sfx2/source

2016-06-10 Thread Akshay Deep
 sfx2/source/control/templateabstractview.cxx |2 -
 sfx2/source/control/templatelocalview.cxx|   20 
 sfx2/source/doc/doc.hrc  |4 +-
 sfx2/source/doc/doc.src  |   12 ++-
 sfx2/source/doc/templatedlg.cxx  |   43 ++-
 5 files changed, 46 insertions(+), 35 deletions(-)

New commits:
commit 82889bf59f0e455d877cf2a6d5c9f4ec243e36cf
Author: Akshay Deep 
Date:   Fri Jun 10 09:02:26 2016 +0530

GSoC: Template Manager: Add respones for User Interaction

1. Success message when templates are successfully exported
2. Query message before copy executes when moving templates

Reviewed-on: https://gerrit.libreoffice.org/26143
Reviewed-by: Samuel Mehrbrodt 
Tested-by: Samuel Mehrbrodt 
(cherry picked from commit ef9e713f6a06191d327dbf236fcc7607d16f61e3)

Change-Id: I11048aa7946d623840e45130affe1b848a3da357
Reviewed-on: https://gerrit.libreoffice.org/26162
Tested-by: Jenkins 
Reviewed-by: Akshay Deep 

diff --git a/sfx2/source/control/templateabstractview.cxx 
b/sfx2/source/control/templateabstractview.cxx
index 6c7fcae..8440d01 100644
--- a/sfx2/source/control/templateabstractview.cxx
+++ b/sfx2/source/control/templateabstractview.cxx
@@ -155,7 +155,7 @@ void TemplateAbstractView::insertItems(const 
std::vector
 else
 {
 OUString sHelpText = SfxResId(STR_TEMPLATE_TOOLTIP).toString();
-sHelpText = (sHelpText.replaceFirst("$1", 
pCur->aName)).replaceFirst("$1", pCur->aRegionName);
+sHelpText = (sHelpText.replaceFirst("$1", 
pCur->aName)).replaceFirst("$2", pCur->aRegionName);
 pChild->setHelpText(sHelpText);
 }
 
diff --git a/sfx2/source/control/templatelocalview.cxx 
b/sfx2/source/control/templatelocalview.cxx
index 83d0e47b..e988bfd 100644
--- a/sfx2/source/control/templatelocalview.cxx
+++ b/sfx2/source/control/templatelocalview.cxx
@@ -21,6 +21,7 @@
 #include 
 #include 
 #include 
+#include 
 
 #include 
 #include 
@@ -468,6 +469,12 @@ bool TemplateLocalView::moveTemplate (const 
ThumbnailViewItem *pItem, const sal_
 
 if (bCopy)
 {
+OUString sQuery = 
(OUString(SfxResId(STR_MSG_QUERY_COPY).toString()).replaceFirst("$1", 
pViewItem->maTitle)).replaceFirst("$2",
+getRegionName(nTargetRegion));
+ScopedVclPtrInstance< MessageDialog > aQueryDlg(this, sQuery, 
VclMessageType::VCL_MESSAGE_QUESTION, VCL_BUTTONS_YES_NO);
+if ( aQueryDlg->Execute() != RET_YES )
+return false;
+
 if 
(!mpDocTemplates->Copy(nTargetRegion,nTargetIdx,nSrcRegionId,pViewItem->mnDocId))
 return false;
 }
@@ -563,6 +570,19 @@ bool TemplateLocalView::moveTemplates(const std::setmaTitle)).replaceFirst("$2",
+getRegionName(nTargetRegion));
+ScopedVclPtrInstance< MessageDialog > aQueryDlg(this, 
sQuery, VclMessageType::VCL_MESSAGE_QUESTION, VCL_BUTTONS_YES_NO);
+
+if ( aQueryDlg->Execute() != RET_YES )
+{
+OUString 
sMsg(SfxResId(STR_MSG_ERROR_LOCAL_MOVE).toString());
+sMsg = 
sMsg.replaceFirst("$1",getRegionName(nTargetRegion));
+ScopedVclPtrInstance::Create(this, 
sMsg.replaceFirst( "$2",pViewItem->maTitle))->Execute();
+
+return false; //return if any single move operation 
fails
+}
+
 if 
(!mpDocTemplates->Copy(nTargetRegion,nTargetIdx,nSrcRegionId,pViewItem->mnDocId))
 {
 ret = false;
diff --git a/sfx2/source/doc/doc.hrc b/sfx2/source/doc/doc.hrc
index 1f516c2..8f12146 100644
--- a/sfx2/source/doc/doc.hrc
+++ b/sfx2/source/doc/doc.hrc
@@ -127,9 +127,11 @@
 #define STR_CATEGORY_RENAME (RID_SFX_DOC_START+109)
 #define STR_RESET_DEFAULT   (RID_SFX_DOC_START+122)
 #define STR_TEMPLATE_TOOLTIP(RID_SFX_DOC_START+169)
+#define STR_MSG_EXPORT_SUCCESS  (RID_SFX_DOC_START+170)
+#define STR_MSG_QUERY_COPY  (RID_SFX_DOC_START+171)
 
 // please update to the last id
-#define ACT_SFX_DOC_END IMG_ACTION_REFRESH
+#define ACT_SFX_DOC_END STR_MSG_QUERY_COPY
 #if ACT_SFX_DOC_END > RID_SFX_DOC_END
 #error resource overflow in #line, #file
 #endif
diff --git a/sfx2/source/doc/doc.src b/sfx2/source/doc/doc.src
index 9b7c0a5..2e7f999 100644
--- a/sfx2/source/doc/doc.src
+++ b/sfx2/source/doc/doc.src
@@ -86,7 +86,7 @@ String STR_RENAME_TEMPLATE
 };
 String STR_TEMPLATE_TOOLTIP
 {
-Text [ en-US ] = "Title: $1\nCategory: $1" ;
+Text [ en-US ] = "Title: $1\nCategory: $2" ;
 };
 String STR_AUTOMATICVERSION
 {
@@ -262,6 +262,16 @@ String STR_CATEGORY_SELECT
 Text [ 

[Libreoffice-commits] core.git: Branch 'libreoffice-5-2' - sfx2/source

2016-06-10 Thread Caolán McNamara
 sfx2/source/appl/shutdownicon.cxx |   11 ++-
 1 file changed, 2 insertions(+), 9 deletions(-)

New commits:
commit dd02cca2e64b061ddd5003ad0485dcbfae7f5ddf
Author: Caolán McNamara 
Date:   Thu Jun 9 21:25:12 2016 +0100

Resolves: tdf#100181 quickstart crashes immediately without Quickstarter

Change-Id: I0257651b3841dea596077cfacbf7d69a20b04252
Reviewed-on: https://gerrit.libreoffice.org/26134
Tested-by: Jenkins 
Reviewed-by: Caolán McNamara 
Tested-by: Caolán McNamara 
(cherry picked from commit dfb2a8deab1324047a4ed81a131a1ef3552c3e8e)

diff --git a/sfx2/source/appl/shutdownicon.cxx 
b/sfx2/source/appl/shutdownicon.cxx
index d515d40..3c6a1d2 100644
--- a/sfx2/source/appl/shutdownicon.cxx
+++ b/sfx2/source/appl/shutdownicon.cxx
@@ -122,19 +122,16 @@ css::uno::Sequence SAL_CALL 
ShutdownIcon::getSupportedServiceNames()
 bool ShutdownIcon::bModalMode = false;
 ShutdownIcon* ShutdownIcon::pShutdownIcon = nullptr;
 
-#if !defined( ENABLE_QUICKSTART_APPLET )
-// To remove conditionals
 extern "C" {
 static void disabled_initSystray() { }
 static void disabled_deInitSystray() { }
 }
-#endif
 
 namespace {
 
 boost::logic::tribool loaded(boost::logic::indeterminate);
-oslGenericFunction pInitSystray(nullptr);
-oslGenericFunction pDeInitSystray(nullptr);
+oslGenericFunction pInitSystray = disabled_initSystray;
+oslGenericFunction pDeInitSystray = disabled_deInitSystray;
 
 bool LoadModule()
 {
@@ -170,10 +167,6 @@ bool LoadModule()
 loaded = true;
 }
 #  endif // UNX
-#else
-pInitSystray = disabled_initSystray;
-pDeInitSystray = disabled_deInitSystray;
-loaded = false;
 #endif // ENABLE_QUICKSTART_APPLET
 }
 assert(!boost::logic::indeterminate(loaded));
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: Branch 'libreoffice-5-2' - sfx2/source

2016-06-09 Thread Akshay Deep
 sfx2/source/doc/templatedlg.cxx |   61 
 1 file changed, 31 insertions(+), 30 deletions(-)

New commits:
commit 048ca1825e9213dba6b94045900d4099a3cfa75c
Author: Akshay Deep 
Date:   Wed Jun 8 06:35:35 2016 +0530

GSoC: Template Manager: Improve "Rename Category" functionality

Change-Id: I0b32179133eca5cf01df6d581a25843da40a8a7e
Reviewed-on: https://gerrit.libreoffice.org/26043
Tested-by: Jenkins 
Reviewed-by: Samuel Mehrbrodt 
Reviewed-on: https://gerrit.libreoffice.org/26137
Reviewed-by: Akshay Deep 
Tested-by: Akshay Deep 

diff --git a/sfx2/source/doc/templatedlg.cxx b/sfx2/source/doc/templatedlg.cxx
index c440095..ab0da91 100644
--- a/sfx2/source/doc/templatedlg.cxx
+++ b/sfx2/source/doc/templatedlg.cxx
@@ -377,6 +377,7 @@ void SfxTemplateManagerDlg::fillFolderComboBox()
 mpCBFolder->InsertEntry(aFolderNames[i], i+1);
 }
 mpCBFolder->SelectEntryPos(0);
+mpActionMenu->HideItem(MNI_ACTION_RENAME_FOLDER);
 mpLocalView->ShowTooltips(true);
 }
 
@@ -386,6 +387,7 @@ void SfxTemplateManagerDlg::getApplicationSpecificSettings()
 {
 mpCBApp->SelectEntryPos(0);
 mpCBFolder->SelectEntryPos(0);
+mpActionMenu->HideItem(MNI_ACTION_RENAME_FOLDER);
 
mpCurView->filterItems(ViewFilter_Application(getCurrentApplicationFilter()));
 mpLocalView->showAllTemplates();
 return;
@@ -416,6 +418,7 @@ void SfxTemplateManagerDlg::getApplicationSpecificSettings()
 
 
mpCurView->filterItems(ViewFilter_Application(getCurrentApplicationFilter()));
 mpCBFolder->SelectEntryPos(0);
+mpActionMenu->HideItem(MNI_ACTION_RENAME_FOLDER);
 mpLocalView->showAllTemplates();
 }
 
@@ -460,6 +463,7 @@ void SfxTemplateManagerDlg::readSettings ()
 {
 //show all categories
 mpCBFolder->SelectEntryPos(0);
+mpActionMenu->HideItem(MNI_ACTION_RENAME_FOLDER);
 mpLocalView->ShowTooltips(true);
 mpLocalView->showAllTemplates();
 }
@@ -467,6 +471,7 @@ void SfxTemplateManagerDlg::readSettings ()
 {
 mpCBFolder->SelectEntry(aLastFolder);
 mpLocalView->showRegion(aLastFolder);
+mpActionMenu->ShowItem(MNI_ACTION_RENAME_FOLDER);
 }
 }
 
@@ -496,6 +501,7 @@ IMPL_LINK_NOARG_TYPED(SfxTemplateManagerDlg, 
SelectApplicationHdl, ListBox&, voi
 
mpCurView->filterItems(ViewFilter_Application(getCurrentApplicationFilter()));
 mpCurView->showAllTemplates();
 mpCBFolder->SelectEntryPos(0);
+mpActionMenu->HideItem(MNI_ACTION_RENAME_FOLDER);
 mpCurView->ShowTooltips(true);
 }
 
@@ -512,11 +518,13 @@ IMPL_LINK_NOARG_TYPED(SfxTemplateManagerDlg, 
SelectRegionHdl, ListBox&, void)
 {
 mpLocalView->showAllTemplates();
 mpLocalView->ShowTooltips(true);
+mpActionMenu->HideItem(MNI_ACTION_RENAME_FOLDER);
 }
 else
 {
 mpLocalView->showRegion(sSelectedRegion);
 mpLocalView->ShowTooltips(false);
+mpActionMenu->ShowItem(MNI_ACTION_RENAME_FOLDER);
 }
 }
 
@@ -732,6 +740,7 @@ IMPL_LINK_NOARG_TYPED(SfxTemplateManagerDlg, 
ImportClickHdl, Button*, void)
 mpLocalView->ShowTooltips(true);
 mpCBApp->SelectEntryPos(0);
 mpCBFolder->SelectEntryPos(0);
+mpActionMenu->HideItem(MNI_ACTION_RENAME_FOLDER);
 }
 
 IMPL_STATIC_LINK_NOARG_TYPED(SfxTemplateManagerDlg, LinkClickHdl, Button*, 
void)
@@ -928,6 +937,7 @@ IMPL_LINK_NOARG_TYPED(SfxTemplateManagerDlg, 
SearchUpdateHdl, Edit&, void)
 {
 OUString sLastFolder = mpCBFolder->GetSelectEntry();
 mpLocalView->showRegion(sLastFolder);
+mpActionMenu->ShowItem(MNI_ACTION_RENAME_FOLDER);
 }
 }
 }
@@ -1225,41 +1235,31 @@ void SfxTemplateManagerDlg::OnCategoryNew()
 
 void SfxTemplateManagerDlg::OnCategoryRename()
 {
-ScopedVclPtrInstance< SfxTemplateCategoryDialog > aDlg;
-aDlg->SetCategoryLBEntries(mpLocalView->getFolderNames());
-aDlg->HideNewCategoryOption();
-aDlg->SetText(SfxResId(STR_CATEGORY_RENAME).toString());
-aDlg->SetSelectLabelText(SfxResId(STR_CATEGORY_SELECT).toString());
+OUString sCategory = mpCBFolder->GetSelectEntry();
+ScopedVclPtrInstance< InputDialog > 
dlg(SfxResId(STR_INPUT_NEW).toString(),this);
 
-if(aDlg->Execute() == RET_OK)
-{
-OUString sCategory = aDlg->GetSelectedCategory();
-ScopedVclPtrInstance< InputDialog > 
dlg(SfxResId(STR_INPUT_NEW).toString(),this);
+dlg->SetEntryText(sCategory);
+int ret = dlg->Execute();
 
-dlg->SetEntryText(sCategory);
-int ret = dlg->Execute();
+if (ret)
+{
+OUString aName = dlg->GetEntryText();
 
-if (ret)
+if(mpLocalView->renameRegion(sCategory, aName))
 {
-OUString aName = 

[Libreoffice-commits] core.git: Branch 'libreoffice-5-2' - sfx2/source

2016-06-09 Thread Akshay Deep
 sfx2/source/control/templateabstractview.cxx |1 +
 sfx2/source/doc/templatedlg.cxx  |5 +
 2 files changed, 6 insertions(+)

New commits:
commit 75e8a542f6515a364ea178fe26d6105a4e10cdcc
Author: Akshay Deep 
Date:   Thu Jun 9 08:07:27 2016 +0530

Hide Default Template icon when resetting default using toolbox menu

Change-Id: I7a3e7c9413edbdfb74e0415dd7e203d65201eb08
Reviewed-on: https://gerrit.libreoffice.org/26081
Tested-by: Jenkins 
Reviewed-by: Akshay Deep 
(cherry picked from commit 4599858e21925f2f5febed8eebf4f5bd0fa97163)
Reviewed-on: https://gerrit.libreoffice.org/26083
Tested-by: Akshay Deep 

diff --git a/sfx2/source/control/templateabstractview.cxx 
b/sfx2/source/control/templateabstractview.cxx
index df34797..6d74a62 100644
--- a/sfx2/source/control/templateabstractview.cxx
+++ b/sfx2/source/control/templateabstractview.cxx
@@ -297,6 +297,7 @@ void TemplateAbstractView::RemoveDefaultTemplateIcon(const 
OUString& rPath)
 if(pViewItem->getPath().match(rPath))
 {
 pViewItem->showDefaultIcon(false);
+Invalidate();
 return;
 }
 }
diff --git a/sfx2/source/doc/templatedlg.cxx b/sfx2/source/doc/templatedlg.cxx
index ad4683a..24a18f3 100644
--- a/sfx2/source/doc/templatedlg.cxx
+++ b/sfx2/source/doc/templatedlg.cxx
@@ -628,6 +628,11 @@ IMPL_LINK_TYPED(SfxTemplateManagerDlg, 
DefaultTemplateMenuSelectHdl, Menu*, pMen
 sal_uInt16 nId = pMenu->GetCurItemId();
 
 OUString aServiceName = SfxObjectShell::GetServiceNameFromFactory( 
mpTemplateDefaultMenu->GetItemCommand(nId));
+
+OUString sPrevDefault = SfxObjectFactory::GetStandardTemplate( 
aServiceName );
+if(!sPrevDefault.isEmpty())
+mpLocalView->RemoveDefaultTemplateIcon(sPrevDefault);
+
 SfxObjectFactory::SetStandardTemplate( aServiceName, OUString() );
 
 createDefaultTemplateMenu();
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: Branch 'libreoffice-5-2' - sfx2/source

2016-06-08 Thread Akshay Deep
 sfx2/source/control/templatelocalview.cxx  |1 +
 sfx2/source/control/templatesearchview.cxx |1 +
 2 files changed, 2 insertions(+)

New commits:
commit e73fc92829bbb4c06c951006fc7577131564ed67
Author: Akshay Deep 
Date:   Wed Jun 8 06:07:29 2016 +0530

Template Manager: Enable "Move" and "Export" buttons on right click

Change-Id: Ibdf3d0cd721333730638e71d2d5258092074af93
Reviewed-on: https://gerrit.libreoffice.org/26042
Tested-by: Jenkins 
Reviewed-by: Samuel Mehrbrodt 
(cherry picked from commit e07f23b148fe95b2418cb9dc5f1d335db8713c9f)
Reviewed-on: https://gerrit.libreoffice.org/26065
Reviewed-by: Akshay Deep 
Tested-by: Akshay Deep 

diff --git a/sfx2/source/control/templatelocalview.cxx 
b/sfx2/source/control/templatelocalview.cxx
index 0722eb1..b1e0242 100644
--- a/sfx2/source/control/templatelocalview.cxx
+++ b/sfx2/source/control/templatelocalview.cxx
@@ -195,6 +195,7 @@ void TemplateLocalView::createContextMenu(const bool 
bIsDefault)
 pItemMenu->InsertSeparator();
 deselectItems();
 maSelectedItem->setSelection(true);
+maItemStateHdl.Call(maSelectedItem);
 pItemMenu->SetSelectHdl(LINK(this, TemplateLocalView, 
ContextMenuSelectHdl));
 pItemMenu->Execute(this, Rectangle(maPosition,Size(1,1)), 
PopupMenuFlags::ExecuteDown);
 Invalidate();
diff --git a/sfx2/source/control/templatesearchview.cxx 
b/sfx2/source/control/templatesearchview.cxx
index e5754d9..ab2f489 100644
--- a/sfx2/source/control/templatesearchview.cxx
+++ b/sfx2/source/control/templatesearchview.cxx
@@ -67,6 +67,7 @@ void TemplateSearchView::createContextMenu( const bool 
bIsDefault)
 pItemMenu->InsertSeparator();
 pItemMenu->InsertItem(MNI_DELETE,SfxResId(STR_DELETE).toString());
 maSelectedItem->setSelection(true);
+maItemStateHdl.Call(maSelectedItem);
 pItemMenu->SetSelectHdl(LINK(this, TemplateSearchView, 
ContextMenuSelectHdl));
 pItemMenu->Execute(this, Rectangle(maPosition,Size(1,1)), 
PopupMenuFlags::ExecuteDown);
 Invalidate();
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: Branch 'libreoffice-5-2' - sfx2/source

2016-06-07 Thread Tor Lillqvist
 sfx2/source/control/templateabstractview.cxx |1 -
 1 file changed, 1 deletion(-)

New commits:
commit b340ad6dfe333bec3da4bd1bfd4b80acc39ec9cf
Author: Tor Lillqvist 
Date:   Mon Jun 6 10:21:56 2016 +0300

loplugin:unusedvariablecheck

Change-Id: Icbf2138d3ac69fb0022134fb7ceab34935ccdc2a
(cherry picked from commit d6efb4e417b3f85782c82fd97788db6b26740a19)
Reviewed-on: https://gerrit.libreoffice.org/26034
Reviewed-by: Tor Lillqvist 
Tested-by: Tor Lillqvist 

diff --git a/sfx2/source/control/templateabstractview.cxx 
b/sfx2/source/control/templateabstractview.cxx
index 490cfea..df34797 100644
--- a/sfx2/source/control/templateabstractview.cxx
+++ b/sfx2/source/control/templateabstractview.cxx
@@ -277,7 +277,6 @@ BitmapEx TemplateAbstractView::scaleImg (const BitmapEx 
, long width, long
 bool TemplateAbstractView::IsDefaultTemplate(const OUString& rPath)
 {
 SvtModuleOptions aModOpt;
-std::vector aList;
 const css::uno::Sequence  = 
aModOpt.GetAllServiceNames();
 
 for( sal_Int32 i=0, nCount = aServiceNames.getLength(); i < nCount; ++i )
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: Branch 'libreoffice-5-2' - sfx2/source

2016-06-07 Thread Akshay Deep
 sfx2/source/control/templatelocalview.cxx |8 
 1 file changed, 4 insertions(+), 4 deletions(-)

New commits:
commit c34baeeca744498d39b116d7bc7739905195daca
Author: Akshay Deep 
Date:   Tue Jun 7 20:15:06 2016 +0530

Switch "Delete" and "Rename" in Template context menu

Change-Id: Ib40a27c25d15c4dd65bbfc4d50f55b16496c7a0a
Reviewed-on: https://gerrit.libreoffice.org/26024
Reviewed-by: Akshay Deep 
Tested-by: Akshay Deep 
(cherry picked from commit 665844d8dd0cf4b3fc6cdb56f3e155704ba76b00)
Reviewed-on: https://gerrit.libreoffice.org/26025

diff --git a/sfx2/source/control/templatelocalview.cxx 
b/sfx2/source/control/templatelocalview.cxx
index c2df6bf..bd1245b 100644
--- a/sfx2/source/control/templatelocalview.cxx
+++ b/sfx2/source/control/templatelocalview.cxx
@@ -185,8 +185,8 @@ void TemplateLocalView::createContextMenu()
 pItemMenu->InsertItem(MNI_EDIT,SfxResId(STR_EDIT_TEMPLATE).toString());
 
pItemMenu->InsertItem(MNI_DEFAULT_TEMPLATE,SfxResId(STR_DEFAULT_TEMPLATE).toString());
 pItemMenu->InsertSeparator();
-pItemMenu->InsertItem(MNI_DELETE,SfxResId(STR_DELETE).toString());
 pItemMenu->InsertItem(MNI_RENAME,SfxResId(STR_RENAME).toString());
+pItemMenu->InsertItem(MNI_DELETE,SfxResId(STR_DELETE).toString());
 pItemMenu->InsertSeparator();
 deselectItems();
 maSelectedItem->setSelection(true);
@@ -207,9 +207,6 @@ IMPL_LINK_TYPED(TemplateLocalView, ContextMenuSelectHdl, 
Menu*, pMenu, bool)
 case MNI_EDIT:
 maEditTemplateHdl.Call(maSelectedItem);
 break;
-case MNI_DELETE:
-maDeleteTemplateHdl.Call(maSelectedItem);
-break;
 case MNI_RENAME:
 {
 ScopedVclPtrInstance< InputDialog > m_pTitleEditDlg( 
SfxResId(STR_RENAME_TEMPLATE).toString(), this);
@@ -227,6 +224,9 @@ IMPL_LINK_TYPED(TemplateLocalView, ContextMenuSelectHdl, 
Menu*, pMenu, bool)
 }
 }
 break;
+case MNI_DELETE:
+maDeleteTemplateHdl.Call(maSelectedItem);
+break;
 case MNI_DEFAULT_TEMPLATE:
 maDefaultTemplateHdl.Call(maSelectedItem);
 break;
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: Branch 'libreoffice-5-2' - sfx2/source

2016-05-30 Thread Akshay Deep
 sfx2/source/doc/saveastemplatedlg.cxx |1 +
 1 file changed, 1 insertion(+)

New commits:
commit 8ef56a27a00b6af3e37f5c5be8e3b46f8d68fb97
Author: Akshay Deep 
Date:   Sat May 28 20:52:34 2016 +0530

Resolves: Error when overwriting a template in Template Save As Dialog

After overwriting a template, overwritten template does not exist in the
template manager because SfxDocumentTemplates is not updated..

Change-Id: I7e8605091de71b921f8dbed5ab2022ac292fe4b2
Reviewed-on: https://gerrit.libreoffice.org/25584
Tested-by: Jenkins 
Reviewed-by: Samuel Mehrbrodt 
(cherry picked from commit 395db598591edc123148770de42dac30bf505296)
Reviewed-on: https://gerrit.libreoffice.org/25680
Reviewed-by: Akshay Deep 
Tested-by: Akshay Deep 

diff --git a/sfx2/source/doc/saveastemplatedlg.cxx 
b/sfx2/source/doc/saveastemplatedlg.cxx
index 1d46197..beef6e6 100644
--- a/sfx2/source/doc/saveastemplatedlg.cxx
+++ b/sfx2/source/doc/saveastemplatedlg.cxx
@@ -162,6 +162,7 @@ bool SfxSaveAsTemplateDialog::SaveTemplate()
 if(!mpDocTemplates->InsertTemplate( mnRegionPos, nDocId, msTemplateName, 
sURL))
 return false;
 
+mpDocTemplates->Update();
 return true;
 }
 
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: Branch 'libreoffice-5-2' - sfx2/source sfx2/uiconfig

2016-05-27 Thread Akshay Deep
 sfx2/source/dialog/backingwindow.cxx |2 +-
 sfx2/uiconfig/ui/startcenter.ui  |4 ++--
 2 files changed, 3 insertions(+), 3 deletions(-)

New commits:
commit 792337781f079d14679d05f08f4433a7dfa6fe9a
Author: Akshay Deep 
Date:   Thu May 26 15:31:52 2016 +0530

Start Center: Rename "Edit Templates" to "Manage Templates"

Change-Id: I184c0508dba673153153a83cf033c9fb057a3435
Reviewed-on: https://gerrit.libreoffice.org/25507
Tested-by: Jenkins 
Reviewed-by: Katarina Behrens 
(cherry picked from commit 9b8da7a53b7bd3b43076a7d9bc3ce735bbe7f80f)
Reviewed-on: https://gerrit.libreoffice.org/25535
Reviewed-by: Samuel Mehrbrodt 
Tested-by: Samuel Mehrbrodt 

diff --git a/sfx2/source/dialog/backingwindow.cxx 
b/sfx2/source/dialog/backingwindow.cxx
index 61f280c..06955c2 100644
--- a/sfx2/source/dialog/backingwindow.cxx
+++ b/sfx2/source/dialog/backingwindow.cxx
@@ -609,7 +609,7 @@ IMPL_LINK_TYPED( BackingWindow, MenuSelectHdl, MenuButton*, 
pButton, void )
 {
 
mpLocalView->filterItems(ViewFilter_Application(FILTER_APPLICATION::DRAW));
 }
-else if( sId == "edit" )
+else if( sId == "manage" )
 {
 Reference< XDispatchProvider > xFrame( mxFrame, UNO_QUERY );
 
diff --git a/sfx2/uiconfig/ui/startcenter.ui b/sfx2/uiconfig/ui/startcenter.ui
index 5b78deb..2591be7 100644
--- a/sfx2/uiconfig/ui/startcenter.ui
+++ b/sfx2/uiconfig/ui/startcenter.ui
@@ -56,10 +56,10 @@
   
 
 
-  
+  
 True
 False
-Edit Templates
+Manage Templates
   
 
   
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits