summaryrefslogtreecommitdiff
path: root/wizards/source/sfwidgets/SF_ContextMenu.xba
diff options
context:
space:
mode:
authorJean-Pierre Ledure <jp@ledure.be>2024-09-08 15:47:27 +0200
committerJean-Pierre Ledure <jp@ledure.be>2024-09-08 17:14:50 +0200
commit70f3fea2f3956ec7344be45d035aafe12905896f (patch)
tree6c9a1946409b9b6e4bcbbef53b5598e02bbe2dde /wizards/source/sfwidgets/SF_ContextMenu.xba
parent7639d707034cbd6e578be7e074e73d4ab4b3563c (diff)
ScriptForge (Dictionary) support case-sensitive keys
To enhance the compatibility between - sf dictionaries - python dicts - arrays of PropertyValues it was necessary to propose the support of case-sensitive keys, i.e. keys are different if a case-sensitive comparison finds them different. So far only not case-sensitive keys were supported. This required a re-visit of the implementation of the ScriptForge.SF_Dictionary service. So far it was built upon a Basic Collection class which differentiates keys not case-sensitively. The new implementation uses sorted arrays. The invocation of the service is now: dict = CreateScriptService("Dictionary", True/False) True means case-sensitive keys. Default = False, which preserves the compatibility with the past. ScriptForge uses dictionaries internally in several places. For each of them it has been assessed if the new attribute was justified or not. For most of the contexts, it was. The functionality makes sense only for Basic user scripts. The documentation of the Dictionary page should be revised according to the new invocation syntax. Change-Id: If1f695bcbf1673a2b71c1e41487b1781caab71c2 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/173044 Tested-by: Jenkins Reviewed-by: Jean-Pierre Ledure <jp@ledure.be>
Diffstat (limited to 'wizards/source/sfwidgets/SF_ContextMenu.xba')
-rw-r--r--wizards/source/sfwidgets/SF_ContextMenu.xba2
1 files changed, 1 insertions, 1 deletions
diff --git a/wizards/source/sfwidgets/SF_ContextMenu.xba b/wizards/source/sfwidgets/SF_ContextMenu.xba
index e246c5aeb5d6..0694569cf9c0 100644
--- a/wizards/source/sfwidgets/SF_ContextMenu.xba
+++ b/wizards/source/sfwidgets/SF_ContextMenu.xba
@@ -482,7 +482,7 @@ Dim MainConfigManager As Object &apos; com.sun.star.ui.XUIConfigurationManager
Try:
&apos; Initialize the dictionary
- Set MenuTree = ScriptForge.SF_Services.CreateScriptService(&quot;Dictionary&quot;)
+ Set MenuTree = ScriptForge.SF_Services.CreateScriptService(&quot;Dictionary&quot;, True) &apos; with case-sensitive comparison of keys
&apos; Identify the container of the menu tree
&apos; The container is taken either from the system configuration manager of from the local (= in document) one