summaryrefslogtreecommitdiff
path: root/qadevOOo
diff options
context:
space:
mode:
authorNoel Grandin <noel@peralex.com>2015-11-17 13:55:48 +0100
committerMichael Stahl <mstahl@redhat.com>2015-11-17 13:30:16 +0000
commitaaf3bc89d722ea3c034fd417cc36db9e4bbc125f (patch)
tree89965dae87d41d59930138cb6d3243056bf97074 /qadevOOo
parentaac3a50a392c95532a85e4c558d2eb1d1a89cdff (diff)
backport implementation part of 754ade38ddb2e96187d00f3e621203cea34961fa
Change-Id: I7c732d94346be8f37fba1a32655ba224c74e0235 Reviewed-on: https://gerrit.libreoffice.org/20017 Reviewed-by: Noel Grandin <noelgrandin@gmail.com> Tested-by: Noel Grandin <noelgrandin@gmail.com> Reviewed-by: Michael Stahl <mstahl@redhat.com> Tested-by: Michael Stahl <mstahl@redhat.com>
Diffstat (limited to 'qadevOOo')
-rw-r--r--qadevOOo/runner/util/utils.java12
1 files changed, 12 insertions, 0 deletions
diff --git a/qadevOOo/runner/util/utils.java b/qadevOOo/runner/util/utils.java
index 4a77e41e2331..766f4e5bbb25 100644
--- a/qadevOOo/runner/util/utils.java
+++ b/qadevOOo/runner/util/utils.java
@@ -30,6 +30,7 @@ import java.net.ServerSocket;
import java.net.URI;
import java.net.URISyntaxException;
+import com.sun.star.awt.XToolkitExperimental;
import com.sun.star.beans.XPropertySet;
import com.sun.star.beans.Property;
import com.sun.star.lang.XMultiServiceFactory;
@@ -661,6 +662,17 @@ public class utils {
}
}
+ public static void waitForEventIdle(XMultiServiceFactory xMSF) {
+ try {
+ XToolkitExperimental xToolkit = UnoRuntime.queryInterface(
+ XToolkitExperimental.class,
+ xMSF.createInstance("com.sun.star.awt.Toolkit"));
+ xToolkit.processEventsToIdle();
+ } catch (com.sun.star.uno.Exception ex) {
+ throw new RuntimeException(ex);
+ }
+ }
+
/**
* Validate the AppExecutionCommand. Returned is an error message, starting
* with "Error:", or a warning, if the command might work.