Skip to content

Commit

Permalink
[#18] Do not associate devices with specific machine instances.
Browse files Browse the repository at this point in the history
  • Loading branch information
kosarev committed Feb 20, 2021
1 parent 4d0c26a commit e7b96ca
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 5 deletions.
3 changes: 1 addition & 2 deletions zx/_device.py
Original file line number Diff line number Diff line change
Expand Up @@ -74,5 +74,4 @@ class ToggleTapePause(DeviceEvent):


class Device(object):
def __init__(self, xmachine):
self.xmachine = xmachine
pass
2 changes: 1 addition & 1 deletion zx/_emulator.py
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@ def __init__(self, speed_factor=1.0, profile=None, devices=None):

# Don't even create the window on full throttle.
if devices is None and self.__speed_factor is not None:
devices = Dispatcher([self, ScreenWindow(self)])
devices = Dispatcher([self, ScreenWindow()])

self.devices = devices

Expand Down
4 changes: 2 additions & 2 deletions zx/_gui.py
Original file line number Diff line number Diff line change
Expand Up @@ -195,8 +195,8 @@ class ScreenWindow(Device):
'ALT_R': 'SYMBOL SHIFT',
'SHIFT_R': 'SYMBOL SHIFT'}

def __init__(self, emulator):
super().__init__(emulator)
def __init__(self):
super().__init__()

self.__events = []

Expand Down

0 comments on commit e7b96ca

Please sign in to comment.