Logo Search packages:      
Sourcecode: guidance-power-manager version File versions

def guidance-power-manager::PowermanagerApp::__init__ (   self,
  parent = None 
)

Initialise dialog and set mainwidget. 

Definition at line 1030 of file guidance-power-manager.py.

01030                                   :
        """ Initialise dialog and set mainwidget. """
        KDialog.__init__(self, parent)
        self.setButtons(KDialog.ButtonCode(KDialog.Ok | KDialog.Cancel | KDialog.Apply | KDialog.User1))
        self.pmwidget = PowerManager(self)
        self.setButtonText(KDialog.User1, i18n("About"))

        if not self.pmwidget.powermanager.isLaptop():
            print "This is not a laptop, quitting ... "
            sys.exit(1)

        self.pmwidget.prepare()

        self.setMainWidget(self.pmwidget)
        self.resize(0, 0)

        self.connect(self, SIGNAL("okClicked()"), self.slotOk)
        self.connect(self, SIGNAL("applyClicked()"), self.slotApply)
        self.connect(self, SIGNAL("cancelClicked()"), self.slotCancel)
        self.connect(self, SIGNAL("user1Clicked()"), self.slotUser1)
        self.aboutus = KAboutApplicationDialog(aboutData, self)
        self.setWindowTitle(i18n("Guidance Power Manager")) #KDialog doesn't use app name for some reason

    def slotOk(self):


Generated by  Doxygen 1.6.0   Back to index