Runnable with both Python3 and Python2, with both PyQt5 and PyQt4 by using Qt.py #2250

Open
kashikoibumi wants to merge 127 commits from kashikoibumi/py3qt into v0.6
Showing only changes of commit c5de33d626 - Show all commits

View File

@ -6,8 +6,6 @@ import ssl
import sys
import time
from qtpy import QtCore
import account
import defaults
import network.stats
@ -117,9 +115,11 @@ def createSupportMessage(myapp):
return
myapp.ui.lineEditSubject.setText(SUPPORT_SUBJECT)
addrIndex = myapp.ui.comboBoxSendFrom.findData(
address, QtCore.Qt.UserRole,
QtCore.Qt.MatchFixedString | QtCore.Qt.MatchCaseSensitive)
# addrIndex = myapp.ui.comboBoxSendFrom.findData(
# address, QtCore.Qt.UserRole,
# QtCore.Qt.MatchFixedString | QtCore.Qt.MatchCaseSensitive
# )
addrIndex = myapp.ui.comboBoxSendFrom.findData(address)
if addrIndex == -1: # something is very wrong
return
myapp.ui.comboBoxSendFrom.setCurrentIndex(addrIndex)