diff options
Diffstat (limited to 'wizards/com/sun/star/wizards/ui/WizardDialog.py')
-rw-r--r-- | wizards/com/sun/star/wizards/ui/WizardDialog.py | 17 |
1 files changed, 15 insertions, 2 deletions
diff --git a/wizards/com/sun/star/wizards/ui/WizardDialog.py b/wizards/com/sun/star/wizards/ui/WizardDialog.py index 534122afac49..fc1ce41b047c 100644 --- a/wizards/com/sun/star/wizards/ui/WizardDialog.py +++ b/wizards/com/sun/star/wizards/ui/WizardDialog.py @@ -65,6 +65,14 @@ class WizardDialog(UnoDialog2): self.sMsgEndAutopilot = self.__oWizardResource.getResText( UIConsts.RID_DB_COMMON + 33) self.oRoadmap = None + self.terminateListener = None + + def activate(self): + try: + self.xUnoDialog.toFront() + except Exception: + pass + # do nothing; def itemStateChanged(self, itemEvent): try: @@ -445,8 +453,7 @@ class WizardDialog(UnoDialog2): def removeTerminateListener(self): if self.__bTerminateListenermustberemoved: - Desktop.getDesktop(self.xMSF).removeTerminateListener( \ - TerminateListenerProcAdapter(self)) + Desktop.getDesktop(self.xMSF).removeTerminateListener(self.terminateListener) self.__bTerminateListenermustberemoved = False ''' @@ -463,10 +470,16 @@ class WizardDialog(UnoDialog2): except Exception: traceback.print_exc() + def windowHidden(): + self.cancelWizard_1() + def queryTermination(self): self.activate() raise TerminationVetoException() + def disposing(arg0): + self.cancelWizard_1() + def optCreateFromTemplateItemChanged(self): self.bEditTemplate = False |