summaryrefslogtreecommitdiff
path: root/officecfg
diff options
context:
space:
mode:
authorJan-Marek Glogowski <jan-marek.glogowski@extern.cib.de>2019-11-21 17:16:28 +0100
committerJan-Marek Glogowski <glogow@fbihome.de>2019-11-27 21:51:31 +0100
commita20e061d0a54e027a9cf3702fdc88b94e9ec8c18 (patch)
treeacb41b4fbd805b92c4deeab2ac4e0fffed294094 /officecfg
parenta83759f4909190974ed07291c6a3a9ef837e834d (diff)
tdf#43021 WIN opt-out of OS recent folder usage
The Microsoft documentation for SetFolder explicitly mentiones "In general, we do not recommended the use of this method. [...] SetDefaultFolder is the better method." If SetDefaultFolder is used the recently-used folder overwrites the value passed to SetDefaultFolder, which is shared between all file pickers. With this patch we rely on the LO internal mechanism to show the last used directory in the file picker. Regina's workaround basically does the same, as it just sets oRegistryKeyContent.WorkPathChanged, which triggers the internal path to use SetFolder instead of SetDefaultFolder. If you're wondering about the GetFolder() handling, the MS API docs have this: "Gets either the folder currently selected in the dialog, or, if the dialog is not currently displayed, the folder that is to be selected when the dialog is opened." So the call to GetFolder(), after the dialog is closed, returns the folder set by the SetFolder call, not the folder selected by the user, in case of the save dialog at least. Change-Id: Ia24f47848501df82727bfb2a99db723468bfe5b1 Reviewed-on: https://gerrit.libreoffice.org/83409 Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com> Reviewed-by: Jan-Marek Glogowski <glogow@fbihome.de> Tested-by: Jan-Marek Glogowski <glogow@fbihome.de> (cherry picked from commit ffa636ba74b04b3258ec9a696bc4eac33581fa24) Reviewed-on: https://gerrit.libreoffice.org/83839 Tested-by: Jenkins
Diffstat (limited to 'officecfg')
-rw-r--r--officecfg/registry/schema/org/openoffice/Office/Common.xcs12
1 files changed, 0 insertions, 12 deletions
diff --git a/officecfg/registry/schema/org/openoffice/Office/Common.xcs b/officecfg/registry/schema/org/openoffice/Office/Common.xcs
index d3056a325eba..cebb7d7ec0ef 100644
--- a/officecfg/registry/schema/org/openoffice/Office/Common.xcs
+++ b/officecfg/registry/schema/org/openoffice/Office/Common.xcs
@@ -1560,18 +1560,6 @@
<desc>Contains the current and default path settings used by the
Office.</desc>
</info>
- <group oor:name="Info">
- <info>
- <desc>Contains various properties information purpose only.</desc>
- </info>
- <prop oor:name="WorkPathChanged" oor:type="xs:boolean" oor:nillable="false">
- <info>
- <desc>A flag which is set by the tools options dialog whenever a
- user changed the work path.</desc>
- </info>
- <value>true</value>
- </prop>
- </group>
<group oor:name="Current">
<info>
<desc>Contains the global path settings, mainly those of the Options