1 # -*- coding: utf-8 -*-
3 # Form implementation generated from reading ui file 'ui/upgradeform_base.ui'
5 # Created: Thu Feb 9 20:00:42 2012
6 # by: The PyQt User Interface Compiler (pyuic) 3.18.1
8 # WARNING! All changes made in this file will be lost!
14 class UpgradeForm_base(QDialog):
15 def __init__(self,parent = None,name = "",modal = 0,fl = 0,distro_type =1 , msg="" ):
16 QDialog.__init__(self,parent,name,modal,fl)
19 self.setName("HPLIP_Upgrade")
21 self.distro_type = distro_type
23 self.textLabel1 = QLabel(self,"textLabel1")
24 self.textLabel1.setGeometry(QRect(10,10,310,50))
27 self.buttonGroup1 = QButtonGroup(self,"buttonGroup1")
28 self.buttonGroup1.setGeometry(QRect(10,60,300,110))
30 self.installRadioBtton = QRadioButton(self.buttonGroup1,"installRadioBtton")
31 self.installRadioBtton.setGeometry(QRect(10,20,250,20))
32 self.installRadioBtton.setChecked(True)
35 self.remindRadioBtton = QRadioButton(self.buttonGroup1,"remindRadioBtton")
36 self.remindRadioBtton.setGeometry(QRect(10,50,130,20))
39 self.daysSpinBox = QSpinBox(self.buttonGroup1,"daysSpinBox")
40 self.daysSpinBox.setGeometry(QRect(139,50,50,20))
41 self.daysSpinBox.setMinValue(1)
42 self.daysSpinBox.setMaxValue(365)
43 # self.daysSpinBox.setEnabled(False)
46 self.daysLabel = QLabel(self.buttonGroup1,"daysLabel")
48 self.daysLabel.setGeometry(QRect(200,50,68,20))
51 self.dontRemindRadioBtton = QRadioButton(self.buttonGroup1,"dontRemindRadioBtton")
52 self.dontRemindRadioBtton.setGeometry(QRect(10,80,160,20))
55 self.NextButton = QPushButton(self,"NextButton")
56 self.NextButton.setGeometry(QRect(140,190,90,25))
58 self.CancelButton = QPushButton(self,"CancelButton")
59 self.CancelButton.setGeometry(QRect(240,190,80,25))
62 self.resize(QSize(328,225).expandedTo(self.minimumSizeHint()))
63 self.clearWState(Qt.WState_Polished)
65 self.connect(self.daysSpinBox,SIGNAL("valueChanged(int)"),self.daysSpinBox_change)
67 def daysSpinBox_change(self):
68 self.remindRadioBtton.setChecked(True)
70 def languageChange(self):
71 self.setCaption(self.__tr("HPLIP Upgrade Manager"))
72 self.textLabel1.setText(self.__tr(self.msg))
73 if self.distro_type == 1:
74 self.installRadioBtton.setText(self.__tr("Download and Install"))
76 self.installRadioBtton.setText(self.__tr("Follow steps from www.hplip.net"))
77 self.remindRadioBtton.setText(self.__tr("Remind me after"))
78 self.daysLabel.setText(self.__tr("days"))
79 self.dontRemindRadioBtton.setText(self.__tr("Don't remind again"))
80 self.NextButton.setText(self.__tr("Ok"))
81 self.CancelButton.setText(self.__tr("Cancel"))
85 def __tr(self,s,c = None):
86 return qApp.translate("Form1",s,c)