Results 1 to 5 of 5

Thread: Main UI Freezes on QFileDilog is up

  1. #1
    Join Date
    Aug 2008
    Posts
    134
    Thanks
    10
    Thanked 3 Times in 3 Posts
    Qt products
    Qt4
    Platforms
    Windows

    Default Main UI Freezes on QFileDilog is up

    Hi,
    I am developing a app which displays continuous data from the external device using QTcpSocket. This data's are displayed either in text controls or in image format(if it is image). my application has the facility to save the data which is recieved.

    Data's are updated properly in the controls when the app is up. But if i open the saveToFile (Using QFileDialog:: getSaveFileName()), all the main app's data will freeze. I found that data's are recievd and processed when SaveToFile() dialog is opened. but updating in controls getting freezed. when i close the SaveToFile() dialog, data's prperly updated in control.

    Can anyone tellme why it is like this?? Is there any solution to resolve???

  2. #2
    Join Date
    Aug 2008
    Posts
    134
    Thanks
    10
    Thanked 3 Times in 3 Posts
    Qt products
    Qt4
    Platforms
    Windows

    Default Re: Main UI Freezes on QFileDilog is up

    I further noticed that, since i am drawing image too, the data's will not update() if i call update(). But if i call repaint() all the data's in the controls, as well as image in the widget is updated.

    Can you please tell me which function is blocking from drawing(calling paintEvent()) when modal dialog is executed on the top of main UI.

  3. #3
    Join Date
    Aug 2006
    Posts
    221
    Thanks
    3
    Thanked 29 Times in 19 Posts

    Default Re: Main UI Freezes on QFileDilog is up

    You are working on Windows? According to docs:

    On Windows the dialog will spin a blocking modal event loop that will not dispatch any QTimers,

  4. #4
    Join Date
    Aug 2008
    Posts
    134
    Thanks
    10
    Thanked 3 Times in 3 Posts
    Qt products
    Qt4
    Platforms
    Windows

    Default Re: Main UI Freezes on QFileDilog is up

    Is there anyway to avoiding the freeze????

  5. #5
    Join Date
    Aug 2006
    Posts
    221
    Thanks
    3
    Thanked 29 Times in 19 Posts

    Default Re: Main UI Freezes on QFileDilog is up

    Quote Originally Posted by navi1084 View Post
    Is there anyway to avoiding the freeze????
    If it really is this problem, you might want to instantiate and configure your file dialog 'manually' and not use the convenient static function.

Similar Threads

  1. QT-Phonon Immage freezes
    By ma.giorgio in forum Qt Programming
    Replies: 0
    Last Post: 28th April 2010, 16:47
  2. GUI Freezes unless there's incoming data
    By crisp in forum Qt Programming
    Replies: 17
    Last Post: 7th February 2009, 17:56
  3. Keyboards freezes
    By giusepped in forum Qt-based Software
    Replies: 0
    Last Post: 28th October 2008, 01:30
  4. Replies: 11
    Last Post: 11th August 2008, 09:14
  5. Replies: 15
    Last Post: 23rd March 2007, 16:16

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Digia, Qt and their respective logos are trademarks of Digia Plc in Finland and/or other countries worldwide.