[PyQt] QtGui.QSessionManager: Syntax

Chris Giles chris.g.27 at gmail.com
Fri Dec 14 12:11:55 GMT 2007


>
> The same syntax I guess. PyQt4 is nothing else than Qt4, but with python
> syntax rather than C++. So just translate the C++ specific language
> things into the Python language equivalent and it'll work. In
> particular that page says you should override commitData() and
> saveState() not call it.
>

Thanks for the reply.  I don't think the same syntax will work in this case
because " QSessionManager" can't be instantiated or sub-classed in PyQt4.
Again, here's what I've tried:

   - QtGui.QApplication.saveState( QtGui.QSessionManager() )
   - aMain.saveState( QtGui.QSessionManager() )
   - smCurrent = QtGui.QSessionManager()

The error message I receive in each case is as follows.

   - TypeError: QtGui.QSessionManager cannot be instantiated or
   sub-classed

I don't know of any other way to call or use "QSessionManager" in PyQt4, so
I'm wondering if someone else has and knows the exact (PyQt4) syntax.  In
other words, I'm looking for someone who knows how to overcome the above
error message or who has used " QSessionManager" specifically in PyQt4
successfully.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://www.riverbankcomputing.com/pipermail/pyqt/attachments/20071214/6ea753e9/attachment.html


More information about the PyQt mailing list