Initial Qt5/Python3 switch

This converts the GUI code to use Qt5 and Python3

The GUI is still somewhat buggy, and it can't open files yet,
but seems to be mostly working, extensive testing will
be needed before this can be released.
This commit is contained in:
Salvo 'LtWorf' Tomaselli
2015-02-19 14:00:47 +01:00
parent 98da6fa7f6
commit cf377eca46
11 changed files with 526 additions and 574 deletions

View File

@@ -17,15 +17,17 @@
#
# author Salvo "LtWorf" Tomaselli <tiposchi@tiscali.it>
from PyQt4 import QtCore, QtGui
import compatibility
from relational import maintenance
import platform
import locale
from PyQt5 import QtCore, QtGui, QtWidgets
class surveyForm (QtGui.QWidget):
from relational_gui import compatibility
from relational import maintenance
class surveyForm (QtWidgets.QWidget):
'''This class is the form used for the survey, needed to intercept the events.
It also sends the data with http POST to a page'''
@@ -85,10 +87,10 @@ class surveyForm (QtGui.QWidget):
response = maintenance.send_survey(post)
if response.status != 200:
QtGui.QMessageBox.information(None, QtGui.QApplication.translate(
"Form", "Error"), QtGui.QApplication.translate("Form", "Unable to send the data!"))
QtWidgets.QMessageBox.information(None, QtWidgets.QApplication.translate(
"Form", "Error"), QtWidgets.QApplication.translate("Form", "Unable to send the data!"))
else:
QtGui.QMessageBox.information(None, QtGui.QApplication.translate(
"Form", "Thanks"), QtGui.QApplication.translate("Form", "Thanks for sending!"))
QtWidgets.QMessageBox.information(None, QtWidgets.QApplication.translate(
"Form", "Thanks"), QtWidgets.QApplication.translate("Form", "Thanks for sending!"))
self.hide()