@@ -42,10 +42,10 @@ def __init__(self, parent=None, *args, **kwargs):
42
42
self .ui .setupUi (self )
43
43
# For getting the icon to work
44
44
try :
45
- from PyQt5 .QtWinExtras import QtWin # type: ignore
45
+ from PyQt5 .QtWinExtras import QtWin
46
46
47
47
myappid = "my_company.my_product.sub_product.version"
48
- QtWin .setCurrentProcessExplicitAppUserModelID (myappid )
48
+ QtWin .setCurrentProcessExplicitAppUserModelID (myappid ) # type: ignore
49
49
except ImportError :
50
50
pass
51
51
@@ -59,7 +59,7 @@ def __init__(self, parent=None, *args, **kwargs):
59
59
self .batch_dialog = BatchAddDialogue (self )
60
60
self .ui .saveToLineEdit .setText (desktop_path )
61
61
self .ui .BrowseConvertToLineEdit .setText (str (Path ().cwd ()))
62
- self .ui .BrowseConvertLineEdit .files = [] # type: ignore
62
+ self .ui .BrowseConvertLineEdit .files = []
63
63
self .ui .statusbar .showMessage ("Ready." )
64
64
self .set_connections ()
65
65
@@ -130,7 +130,7 @@ def convert_file_browse(self):
130
130
file_name = str (Path (file_names [0 ]).resolve ())
131
131
self .ui .BrowseConvertLineEdit .setText (file_name )
132
132
133
- self .ui .BrowseConvertLineEdit .files = file_names # type: ignore
133
+ self .ui .BrowseConvertLineEdit .files = file_names
134
134
135
135
def convert_file (self , file_path , out_path , preferred_format , delete_tmp = False ):
136
136
if Path (file_path ).suffix == preferred_format :
@@ -148,9 +148,9 @@ def convert_file(self, file_path, out_path, preferred_format, delete_tmp=False):
148
148
}
149
149
# Using ThreadPool
150
150
pprocessorThread = PostProcessor (options )
151
- pprocessorThread .signals .statusBar_Signal .connect (self .ui .statusbar .showMessage ) # type: ignore
152
- pprocessorThread .signals .list_Signal .connect (self .add_to_table ) # type: ignore
153
- pprocessorThread .signals .row_Signal .connect (self .decrease_rowcount ) # type: ignore
151
+ pprocessorThread .signals .statusBar_Signal .connect (self .ui .statusbar .showMessage )
152
+ pprocessorThread .signals .list_Signal .connect (self .add_to_table )
153
+ pprocessorThread .signals .row_Signal .connect (self .decrease_rowcount )
154
154
self .threadpool .start (pprocessorThread )
155
155
156
156
self .ui .tabWidget .setCurrentIndex (2 )
@@ -193,11 +193,11 @@ def download_url(self, url, row=None):
193
193
194
194
# Using ThreadPool
195
195
downloadThread = Download (options )
196
- downloadThread .signals .status_bar_signal .connect (self .ui .statusbar .showMessage ) # type: ignore
197
- downloadThread .signals .remove_url_signal .connect (self .remove_url ) # type: ignore
198
- downloadThread .signals .add_update_list_signal .connect (self .add_to_table ) # type: ignore
199
- downloadThread .signals .remove_row_signal .connect (self .decrease_rowcount ) # type: ignore
200
- self .closing .closed .connect (downloadThread .stop ) # type: ignore
196
+ downloadThread .signals .status_bar_signal .connect (self .ui .statusbar .showMessage )
197
+ downloadThread .signals .remove_url_signal .connect (self .remove_url )
198
+ downloadThread .signals .add_update_list_signal .connect (self .add_to_table )
199
+ downloadThread .signals .remove_row_signal .connect (self .decrease_rowcount )
200
+ self .closing .closed .connect (downloadThread .stop )
201
201
self .threadpool .start (downloadThread )
202
202
203
203
self .ui .tabWidget .setCurrentIndex (2 )
@@ -286,7 +286,7 @@ def closeEvent(self, event):
286
286
msgBox .setWindowTitle ("Exit" )
287
287
msgBox .setText ("Some files are currently being downloaded." )
288
288
msgBox .setInformativeText ("Do you really want to close?" )
289
- msgBox .setStandardButtons (QtWidgets .QMessageBox .Close | QtWidgets .QMessageBox .Cancel ) # type: ignore
289
+ msgBox .setStandardButtons (QtWidgets .QMessageBox .Close | QtWidgets .QMessageBox .Cancel )
290
290
msgBox .setDefaultButton (QtWidgets .QMessageBox .Cancel )
291
291
ret = msgBox .exec_ ()
292
292
if ret == QtWidgets .QMessageBox .Cancel :
@@ -297,7 +297,7 @@ def closeEvent(self, event):
297
297
self .kill_all_threads ()
298
298
299
299
def kill_all_threads (self ):
300
- self .closing .closed .emit () # type: ignore
300
+ self .closing .closed .emit ()
301
301
self .threadpool .waitForDone ()
302
302
self .close ()
303
303
0 commit comments