mirror of
https://forgejo.xatacraft.ru/Sunshine/mkxp-sunshine.git
synced 2026-08-19 13:29:54 +00:00
Remove unused screen_width
This commit is contained in:
parent
5f12e408cb
commit
23f53431c2
1 changed files with 3 additions and 4 deletions
|
|
@ -102,8 +102,8 @@ class Journal(QWidget):
|
|||
class Niko(QWidget):
|
||||
def __init__(self, *args, **kwargs):
|
||||
self.x, self.y, self.start_y, self.app, self.thread = kwargs['x'], kwargs['y'], kwargs['y'], kwargs['app'], kwargs['thread']
|
||||
self.screen_width, self.screen_height = kwargs['screen_width'], kwargs['screen_height']
|
||||
del kwargs['x'], kwargs['y'], kwargs['screen_width'], kwargs['screen_height'], kwargs['app'], kwargs['thread']
|
||||
self.screen_height = kwargs['screen_height']
|
||||
del kwargs['x'], kwargs['y'], kwargs['screen_height'], kwargs['app'], kwargs['thread']
|
||||
|
||||
super().__init__(*args, **kwargs)
|
||||
|
||||
|
|
@ -142,11 +142,10 @@ if __name__ == '__main__':
|
|||
if len(sys.argv) == 3:
|
||||
# "Niko-leaves-the-screen" mode
|
||||
x, y = int(sys.argv[1]), int(sys.argv[2])
|
||||
screensize = app.primaryScreen().size()
|
||||
|
||||
thread = AnimationTimer()
|
||||
|
||||
niko = Niko(x = x, y = y, screen_width = screensize.width(), screen_height = screensize.height(), app = app, thread = thread)
|
||||
niko = Niko(x = x, y = y, screen_height = app.primaryScreen().size().height(), app = app, thread = thread)
|
||||
|
||||
thread.next_frame.connect(niko.update)
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue