[Libreoffice-commits] core.git: Branch 'libreoffice-4-0' - fpicker/source
Tor Lillqvist
tml at iki.fi
Thu Apr 25 23:08:05 PDT 2013
fpicker/source/win32/filepicker/VistaFilePickerImpl.cxx | 9 ++++++++-
1 file changed, 8 insertions(+), 1 deletion(-)
New commits:
commit ddbe7cd615689797ef8029c29a8eaeafd610ad09
Author: Tor Lillqvist <tml at iki.fi>
Date: Fri Apr 26 09:01:38 2013 +0300
fdo#63622: Revert '"Fix" bnc#777788'
Let's keep that "fix" just in the SUSE-specific branch.
This reverts commit 56d41fef8f96888d5aaf39a9c4d0c7eca5b63d44.
diff --git a/fpicker/source/win32/filepicker/VistaFilePickerImpl.cxx b/fpicker/source/win32/filepicker/VistaFilePickerImpl.cxx
index 75a3f79..6555685 100644
--- a/fpicker/source/win32/filepicker/VistaFilePickerImpl.cxx
+++ b/fpicker/source/win32/filepicker/VistaFilePickerImpl.cxx
@@ -668,6 +668,7 @@ void VistaFilePickerImpl::impl_sta_SetFileName(const RequestRef& rRequest)
void VistaFilePickerImpl::impl_sta_SetDirectory(const RequestRef& rRequest)
{
::rtl::OUString sDirectory = rRequest->getArgumentOrDefault(PROP_DIRECTORY, ::rtl::OUString());
+ bool bForce = rRequest->getArgumentOrDefault(PROP_FORCE, false);
if( !m_bInExecute)
{
@@ -694,7 +695,13 @@ void VistaFilePickerImpl::impl_sta_SetDirectory(const RequestRef& rRequest)
if ( FAILED(hResult) )
return;
- iDialog->SetFolder(pFolder);
+ if ( m_bInExecute || bForce )
+ iDialog->SetFolder(pFolder);
+ else
+ {
+ // Use set default folder as Microsoft recommends in the IFileDialog documentation.
+ iDialog->SetDefaultFolder(pFolder);
+ }
}
void VistaFilePickerImpl::impl_sta_GetDirectory(const RequestRef& rRequest)
More information about the Libreoffice-commits
mailing list