summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--Mac/Tools/IDE/Wbase.py8
-rw-r--r--Mac/Tools/IDE/Wlists.py7
-rw-r--r--Mac/Tools/IDE/Wmenus.py3
-rw-r--r--Mac/Tools/IDE/Wwindows.py13
4 files changed, 8 insertions, 23 deletions
diff --git a/Mac/Tools/IDE/Wbase.py b/Mac/Tools/IDE/Wbase.py
index 764c131..be75d8a 100644
--- a/Mac/Tools/IDE/Wbase.py
+++ b/Mac/Tools/IDE/Wbase.py
@@ -1,15 +1,13 @@
-from Carbon import Qd
-from Carbon import Win
-from Carbon import QuickDraw
-from Carbon import Evt
+from Carbon import Evt, Qd, QuickDraw, Win
import string
from types import *
import sys
-WidgetsError = "WidgetsError"
+class WidgetsError(Exception): pass
DEBUG = 0
+
class Widget:
"""Base class for all widgets."""
diff --git a/Mac/Tools/IDE/Wlists.py b/Mac/Tools/IDE/Wlists.py
index 04266f7..e7a3501 100644
--- a/Mac/Tools/IDE/Wlists.py
+++ b/Mac/Tools/IDE/Wlists.py
@@ -1,12 +1,7 @@
import Wbase
import Wkeys
-from Carbon import Scrap
import string
-from Carbon import Evt
-from Carbon import Events
-from Carbon import Qd
-from Carbon import Win
-from Carbon import Lists
+from Carbon import Evt, Events, Lists, Qd, Scrap, Win
class List(Wbase.SelectableWidget):
diff --git a/Mac/Tools/IDE/Wmenus.py b/Mac/Tools/IDE/Wmenus.py
index 9af50a7..4d65e90 100644
--- a/Mac/Tools/IDE/Wmenus.py
+++ b/Mac/Tools/IDE/Wmenus.py
@@ -1,7 +1,6 @@
import FrameWork
-from Carbon import Qd
import Wbase, Wcontrols
-from Carbon import Ctl, Controls
+from Carbon import Ctl, Controls, Qd
from types import *
import Wapplication
diff --git a/Mac/Tools/IDE/Wwindows.py b/Mac/Tools/IDE/Wwindows.py
index 3073b4f..1494187 100644
--- a/Mac/Tools/IDE/Wwindows.py
+++ b/Mac/Tools/IDE/Wwindows.py
@@ -1,18 +1,11 @@
-from Carbon import Qd
-from Carbon import Win
-from Carbon import Evt
-from Carbon import Fm
+from Carbon import Dlg, Evt, Events, Fm
+from Carbon import Menu, Qd, Win, Windows
import FrameWork
-from Carbon import Windows
-from Carbon import Events
import Wbase
-from Carbon import Dlg
import MacOS
-from Carbon import Menu
import struct
import traceback
-
-from types import *
+from types import InstanceType, StringType
class Window(FrameWork.Window, Wbase.SelectableWidget):