[PySide] initialize and delete QApplication instances many times

flyer flyer103 at gmail.com
Thu Oct 25 08:28:02 CEST 2012


Thanks anyway.

I find a solution, that is, using
*QApplication(sys.argv).processEvents()* instead
of *QApplication(sys.argv).exec_()*

On Wed, Oct 24, 2012 at 9:48 PM, Hugo Parente Lima
<hugo.lima at openbossa.org>wrote:

> On Wednesday, October 24, 2012 07:32:09 PM flyer wrote:
> > Is it possible to initialize and delete QApplication instances many
> times?
>
> No, IIRC isn't.
>
> Hugo
>
> > The following is a sample code:
> >
> > while some_condition:
> >
> >     app = QApplication(sys.argv)
> >
> >
> >
> >     some_actions
> >
> > >     del app
> >
> > I tried, but it seemed impossible.
> >
> > If I want to initialize and delete QApplication instances many times in a
> > single file, how can I do that?
>



-- 
宠辱不惊,闲看庭前花开花落;去留无意,漫随天边云卷云舒。
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.qt-project.org/pipermail/pyside/attachments/20121025/f126a5eb/attachment.html>


More information about the PySide mailing list