From 58b752127d3fcb6eb1f551aa2f07c89389685c8c Mon Sep 17 00:00:00 2001 From: Dmitri Bogomolov <4glitch@gmail.com> Date: Fri, 23 Feb 2018 15:42:50 +0200 Subject: [PATCH] QComboBox.findData() compatible with pyside --- src/bitmessageqt/support.py | 11 +++++------ 1 file changed, 5 insertions(+), 6 deletions(-) diff --git a/src/bitmessageqt/support.py b/src/bitmessageqt/support.py index 3edd7980..ca8695dd 100644 --- a/src/bitmessageqt/support.py +++ b/src/bitmessageqt/support.py @@ -4,8 +4,6 @@ import sys import os import time -from qtpy import QtCore - import account import defaults import network.stats @@ -100,10 +98,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)