From 147063f58c6b7898e659321f581ea9551305a574 Mon Sep 17 00:00:00 2001 From: Noel Grandin Date: Thu, 28 Mar 2024 09:39:31 +0100 Subject: Revert "tdf#158803 remove some unused imports, unnecessary semicolons and related styling" This reverts commit 9d4844374395ecce6b2ff4f9a71b3c8dae23050a. Reason for revert: fails in unit tests Change-Id: Icfaf6ab331ecce691b9a9462432e07c68d0fb40c Reviewed-on: https://gerrit.libreoffice.org/c/core/+/165417 Tested-by: Noel Grandin Reviewed-by: Noel Grandin --- wizards/com/sun/star/wizards/agenda/TopicsControl.py | 2 +- wizards/com/sun/star/wizards/common/ConfigGroup.py | 2 +- wizards/com/sun/star/wizards/common/Configuration.py | 2 +- wizards/com/sun/star/wizards/common/SystemDialog.py | 2 +- wizards/com/sun/star/wizards/fax/FaxWizardDialog.py | 2 +- wizards/com/sun/star/wizards/letter/LetterWizardDialogImpl.py | 2 +- wizards/com/sun/star/wizards/text/TextDocument.py | 6 +++--- 7 files changed, 9 insertions(+), 9 deletions(-) (limited to 'wizards/com') diff --git a/wizards/com/sun/star/wizards/agenda/TopicsControl.py b/wizards/com/sun/star/wizards/agenda/TopicsControl.py index bb8d8b81ae01..6e269f6bf242 100644 --- a/wizards/com/sun/star/wizards/agenda/TopicsControl.py +++ b/wizards/com/sun/star/wizards/agenda/TopicsControl.py @@ -643,7 +643,7 @@ class TopicsControl(ControlScroller): elif tmp_switch_var1 == 3: return cr.timebox else: - raise Exception("No such column") + raise Exception("No such column"); '''getControl returns a control out of the given row, which is diff --git a/wizards/com/sun/star/wizards/common/ConfigGroup.py b/wizards/com/sun/star/wizards/common/ConfigGroup.py index 4155e87f63cc..200d4ef9d1ad 100644 --- a/wizards/com/sun/star/wizards/common/ConfigGroup.py +++ b/wizards/com/sun/star/wizards/common/ConfigGroup.py @@ -47,7 +47,7 @@ class ConfigGroup(object): propertyName = field[len(prefix):] child = getattr(self, field) if isinstance(child, ConfigGroup): - child.setRoot(self.root) + child.setRoot(self.root); child.readConfiguration(configView.getByName(propertyName), prefix) else: diff --git a/wizards/com/sun/star/wizards/common/Configuration.py b/wizards/com/sun/star/wizards/common/Configuration.py index 7a469a11bba5..91274e0b288c 100644 --- a/wizards/com/sun/star/wizards/common/Configuration.py +++ b/wizards/com/sun/star/wizards/common/Configuration.py @@ -44,7 +44,7 @@ class Configuration(object): @classmethod def getProductName(self, xMSF): try: - oProdNameAccess = self.getConfigurationRoot(xMSF, "org.openoffice.Setup/Product", False) + oProdNameAccess = self.getConfigurationRoot(xMSF, "org.openoffice.Setup/Product", False); return oProdNameAccess.getByName("ooName") except Exception: traceback.print_exc() diff --git a/wizards/com/sun/star/wizards/common/SystemDialog.py b/wizards/com/sun/star/wizards/common/SystemDialog.py index f9c3776b40c1..35bcdadfac3b 100644 --- a/wizards/com/sun/star/wizards/common/SystemDialog.py +++ b/wizards/com/sun/star/wizards/common/SystemDialog.py @@ -114,7 +114,7 @@ class SystemDialog(object): return str(i.Value).replace("%productname%", "LibreOffice") raise Exception( - "UIName property not found for Filter " + filterName) + "UIName property not found for Filter " + filterName); except Exception: traceback.print_exc() return None diff --git a/wizards/com/sun/star/wizards/fax/FaxWizardDialog.py b/wizards/com/sun/star/wizards/fax/FaxWizardDialog.py index 58d50463c5ab..0153eb639d30 100644 --- a/wizards/com/sun/star/wizards/fax/FaxWizardDialog.py +++ b/wizards/com/sun/star/wizards/fax/FaxWizardDialog.py @@ -16,7 +16,7 @@ # the License at http://www.apache.org/licenses/LICENSE-2.0 . # from .FaxWizardDialogResources import FaxWizardDialogResources -from .FaxWizardDialogConst import FaxWizardDialogConst, HIDMAIN +from .FaxWizardDialogConst import FaxWizardDialogConst, HIDMAIN, HID from ..ui.WizardDialog import WizardDialog, uno, UIConsts, PropertyNames diff --git a/wizards/com/sun/star/wizards/letter/LetterWizardDialogImpl.py b/wizards/com/sun/star/wizards/letter/LetterWizardDialogImpl.py index de85eb50c049..66c0e33457b5 100644 --- a/wizards/com/sun/star/wizards/letter/LetterWizardDialogImpl.py +++ b/wizards/com/sun/star/wizards/letter/LetterWizardDialogImpl.py @@ -234,7 +234,7 @@ class LetterWizardDialogImpl(LetterWizardDialog): self.xUnoDialog.endExecute() self.running = False - return True + return True; def closeDocument(self): try: diff --git a/wizards/com/sun/star/wizards/text/TextDocument.py b/wizards/com/sun/star/wizards/text/TextDocument.py index fe425741f4bb..f975dad5718b 100644 --- a/wizards/com/sun/star/wizards/text/TextDocument.py +++ b/wizards/com/sun/star/wizards/text/TextDocument.py @@ -56,10 +56,10 @@ class TextDocument(object): elif xArgs is not None: '''creates an instance of TextDocument and creates a frame and loads a document''' - self.xDesktop = Desktop.getDesktop(xMSF) + self.xDesktop = Desktop.getDesktop(xMSF); self.xFrame = OfficeDocument.createNewFrame(xMSF, listener) self.xTextDocument = OfficeDocument.load( - self.xFrame, URL, "_self", xArgs) + self.xFrame, URL, "_self", xArgs); self.xWindowPeer = self.xFrame.getComponentWindow() self.m_xDocProps = self.xTextDocument.DocumentProperties CharLocale = self.xTextDocument.CharLocale @@ -68,7 +68,7 @@ class TextDocument(object): else: '''creates an instance of TextDocument from the desktop's current frame''' - self.xDesktop = Desktop.getDesktop(xMSF) + self.xDesktop = Desktop.getDesktop(xMSF); self.xFrame = self.xDesktop.getActiveFrame() self.xTextDocument = self.xFrame.getController().Model -- cgit