mirror of
https://github.com/bec-project/bec_widgets.git
synced 2025-07-13 19:21:50 +02:00
fix: import pyqtRemoveInputHook only for pyqt distributions
This commit is contained in:
@ -4,12 +4,17 @@ import platform
|
||||
import sys
|
||||
|
||||
import termqt
|
||||
from qtpy.QtCore import QSocketNotifier, Qt, pyqtRemoveInputHook
|
||||
from qtpy.QtCore import QSocketNotifier, Qt
|
||||
from qtpy.QtGui import QFont
|
||||
from qtpy.QtWidgets import QApplication, QHBoxLayout, QScrollBar, QWidget
|
||||
from termqt import Terminal
|
||||
|
||||
pyqtRemoveInputHook()
|
||||
try:
|
||||
from qtpy.QtCore import pyqtRemoveInputHook
|
||||
|
||||
pyqtRemoveInputHook()
|
||||
except ImportError:
|
||||
pass
|
||||
|
||||
if platform.system() in ["Linux", "Darwin"]:
|
||||
terminal_cmd = os.environ["SHELL"]
|
||||
|
@ -25,6 +25,7 @@ dependencies = [
|
||||
"pyqtdarktheme",
|
||||
"black", # needed for bw-generate-cli
|
||||
"isort", # needed for bw-generate-cli
|
||||
"termqt @ git+ssh://git@github.com:TerryGeng/termqt.git"
|
||||
]
|
||||
|
||||
|
||||
@ -36,6 +37,7 @@ dev = [
|
||||
"pytest-xvfb",
|
||||
"coverage",
|
||||
"pytest-qt",
|
||||
"isort",
|
||||
"fakeredis",
|
||||
]
|
||||
pyqt5 = ["PyQt5>=5.9", "PyQtWebEngine>=5.9"]
|
||||
|
Reference in New Issue
Block a user