Skip to content

Commit

Permalink
faster
Browse files Browse the repository at this point in the history
  • Loading branch information
zdimension committed Apr 11, 2018
1 parent 14b148d commit d40739c
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 5 deletions.
3 changes: 1 addition & 2 deletions src/lang/translator.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,6 @@
from PyQt5.QtCore import *
from PyQt5.QtWidgets import QWidget

import maths.lib

uis: List[Tuple[object, QWidget]] = []
current_lang = None
tr_object: QTranslator = None
Expand All @@ -25,6 +23,7 @@ def remove(ui: object):


def update():
import maths.lib
global uis
uis = [x for x in uis if not sip.isdeleted(x[1])]

Expand Down
5 changes: 2 additions & 3 deletions src/main.py
Original file line number Diff line number Diff line change
Expand Up @@ -21,8 +21,6 @@
import util.code
import util.html
from algo.stmts import *
from algo.worker import Worker
from forms.ui_mainwindow import Ui_MainWindow
from lang import translator
from maths.nodes import *
from maths.parser import quick_parse as parse
Expand Down Expand Up @@ -98,7 +96,6 @@
last_saved = None
current_stmt = None


def sleep(duration: int):
duration *= 1000
begin = datetime.datetime.now()
Expand Down Expand Up @@ -416,6 +413,7 @@ def stmt_GLine(stmt: GLineStmt):


def init_worker():
from algo.worker import Worker
global worker
worker = Worker(algo.children)
worker.callback_print = python_print
Expand Down Expand Up @@ -1559,6 +1557,7 @@ def algo_sel_changed():


def init_ui():
from forms.ui_mainwindow import Ui_MainWindow
global window, ui
window = MainWindowWrapper()
ui = Ui_MainWindow()
Expand Down

0 comments on commit d40739c

Please sign in to comment.