i'm doing exactly what you do in your example code...

No matter where i call exec() the result is the same. Flashing. It seems that the dialog draws it self just like it was when it was hidden... and then refreshes... weird :/

Qt Code:
  1. void Dlg::initImport(QString &path)
  2. {
  3. m_filepath = path;
  4. setDefaults();
  5. update();
  6. exec();
  7. }
  8.  
  9. void Dlg::setDefaults()
  10. {
  11. m_probar->setValue(0);
  12. m_importButton->setEnabled(true);
  13. m_cancelButton->setEnabled(true);
  14. }
  15.  
  16. void Dlg::accept()
  17. {
  18. m_importButton->setEnabled(false);
  19. m_cancelButton->setEnabled(false);
  20.  
  21. m_probar->setValue(100);
  22. hide();
  23. }
  24.  
  25. void Dlg::reject()
  26. {
  27. clearData();
  28. hide();
  29. }
To copy to clipboard, switch view to plain text mode