diff --git a/glue_wwt/viewer/tools.py b/glue_wwt/viewer/tools.py index 407cb907..c69b6584 100644 --- a/glue_wwt/viewer/tools.py +++ b/glue_wwt/viewer/tools.py @@ -83,8 +83,8 @@ def activate(self): if not filename.endswith('.wtt'): filename = filename + '.wtt' - self.viewer._wwt.widget.page.runJavaScript("tourxml = '';") - tourxml = self.viewer._wwt.widget.page.runJavaScript('tourxml;') + self.viewer._wwt.widget.page.runJavaScript("tourxml = '';", asynchronous=False) + tourxml = self.viewer._wwt.widget.page.runJavaScript('tourxml;', asynchronous=False) self.viewer._wwt.widget.page.runJavaScript(SAVE_TOUR_CODE) @@ -93,7 +93,7 @@ def activate(self): while time.time() - start < 10: time.sleep(0.1) app.processEvents() - tourxml = self.viewer._wwt.widget.page.runJavaScript('tourxml;') + tourxml = self.viewer._wwt.widget.page.runJavaScript('tourxml;', asynchronous=False) if tourxml: break