commit 592a403fa71775e413b4f3199b81636bad37e928
parent d7b947e30f02c1d9d080a70d5e345d7a27c13e00
Author: ThomasV <thomasv@gitorious>
Date: Thu, 4 Sep 2014 23:33:31 +0200
qrtextedi: minor fixes
Diffstat:
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/gui/qt/qrtextedit.py b/gui/qt/qrtextedit.py
@@ -5,7 +5,7 @@ from PyQt4.QtCore import *
class QRTextEdit(QPlainTextEdit):
def __init__(self, text=None):
- QTextEdit.__init__(self, text)
+ QPlainTextEdit.__init__(self, text)
self.button = QToolButton(self)
self.button.setIcon(QIcon(":icons/qrcode.png"))
self.button.setStyleSheet("QToolButton { border: none; padding: 0px; }")
@@ -32,9 +32,9 @@ class QRTextEdit(QPlainTextEdit):
def qr_show(self):
from qrcodewidget import QRDialog
try:
- s = unicode(self.toPlainText())
- except:
s = str(self.toPlainText())
+ except:
+ s = unicode(self.toPlainText())
QRDialog(s).exec_()
def qr_input(self):