[Libreoffice-commits] core.git: wizards/source
Jean-Pierre Ledure (via logerrit)
logerrit at kemper.freedesktop.org
Tue Apr 27 09:03:09 UTC 2021
wizards/source/sfdialogs/SF_Register.xba | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
New commits:
commit cf017d0b4316f52271fe91f8c18a5e648fd5d682
Author: Jean-Pierre Ledure <jp at ledure.be>
AuthorDate: Mon Apr 26 19:29:08 2021 +0200
Commit: Jean-Pierre Ledure <jp at ledure.be>
CommitDate: Tue Apr 27 11:02:23 2021 +0200
ScriptForge - (SFDialogs.SF_Register) DialogProvider
When launching a dialog from a Python script while the
dialog is contained in a document, the DialogProvider setup
from that context was built by the wrong method.
Use createInstanceWithArguments()
i.o. createInstanceWithContext()
This caused a LibreOffice crash.
Change-Id: I3615c55068134085579662004f5bb085de008cbd
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/114677
Tested-by: Jean-Pierre Ledure <jp at ledure.be>
Tested-by: Jenkins
Reviewed-by: Jean-Pierre Ledure <jp at ledure.be>
diff --git a/wizards/source/sfdialogs/SF_Register.xba b/wizards/source/sfdialogs/SF_Register.xba
index 8a807346babf..b99c9e337526 100644
--- a/wizards/source/sfdialogs/SF_Register.xba
+++ b/wizards/source/sfdialogs/SF_Register.xba
@@ -311,7 +311,7 @@ Try:
Case Not IsNull(vContext) And IsNull(oComp) ' Python and GlobalScope
Set oDialogProvider = vContext.getServiceManager().createInstanceWithContext("com.sun.star.awt.DialogProvider", vContext)
Case Not IsNull(vContext) And Not IsNull(oComp) ' Python and Document
- Set oDialogProvider = vContext.getServiceManager().createInstanceWithContext("com.sun.star.awt.DialogProvider", Array(oComp))
+ Set oDialogProvider = vContext.getServiceManager().createInstanceWithArguments("com.sun.star.awt.DialogProvider", Array(oComp))
End Select
' Create the graphical interface
@@ -344,4 +344,4 @@ CatchNotFound:
End Function ' SFDialogs.SF_Register._NewDialog
REM ============================================== END OF SFDIALOGS.SF_REGISTER
-</script:module>
+</script:module>
\ No newline at end of file
More information about the Libreoffice-commits
mailing list