Skip to content

Commit

Permalink
Merge pull request #57 from markotoplak/fix-qapp
Browse files Browse the repository at this point in the history
Use QApplication.instance() instead of qApp (Qt6 compatibility)
  • Loading branch information
PrimozGodec authored Sep 29, 2023
2 parents 80b4983 + 37690eb commit c045621
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions orangecontrib/associate/widgets/owassociate.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@

from AnyQt.QtCore import Qt, QSortFilterProxyModel
from AnyQt.QtGui import QStandardItem, QStandardItemModel
from AnyQt.QtWidgets import QTableView, qApp, QGridLayout, QLabel
from AnyQt.QtWidgets import QTableView, QGridLayout, QLabel, QApplication

from Orange.data import Table, ContinuousVariable, StringVariable, Domain
from Orange.widgets import widget, gui, settings
Expand Down Expand Up @@ -415,7 +415,7 @@ def find_rules(self):
if not self._is_running or nRules >= self.maxRules:
break

qApp.processEvents()
QApplication.instance().processEvents()

if not self._is_running or nRules >= self.maxRules:
break
Expand Down
4 changes: 2 additions & 2 deletions orangecontrib/associate/widgets/owitemsets.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
from scipy.sparse import issparse

from AnyQt.QtCore import Qt, QItemSelection, QItemSelectionModel
from AnyQt.QtWidgets import QTreeWidget, QTreeWidgetItem, qApp
from AnyQt.QtWidgets import QTreeWidget, QTreeWidgetItem, QApplication

from Orange.data import Table
from Orange.widgets import widget, gui, settings
Expand Down Expand Up @@ -297,7 +297,7 @@ def __init__(self, item):
if not self._is_running or nItemsets >= self.maxItemsets:
break

qApp.processEvents()
QApplication.instance().processEvents()

if not filterSearch:
self.filter_change()
Expand Down

0 comments on commit c045621

Please sign in to comment.