title: The QProgressDialog is not closing
body: <p>I'm having some trouble with a <strong>QProgressDialog</strong> on my app.</p>
  
  <p>When the user clicks on a calculation button, I show a <strong>QProgressDialog</strong> that is updated from a <strong>QThread</strong> (I don't think this is related to the problem), and when this <strong>QThread</strong> finishes I call a function that closes the <strong>QProgressDialog</strong>.</p>
  
  <pre><code>progressDialog-&gt;setValue(100);
  progressDialog-&gt;close();
  </code></pre>
  
  <p>It seems to be working.</p>
  
  <p>But if the user clicks on the calculation button and minimizes the app (main window), the <strong>QProgressDialog</strong> don't close:</p>
  
  <p><a href="https://i.stack.imgur.com/MphEd.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/MphEd.png" alt="enter image description here"></a></p>
  
  <p>I already checked and the code is reaching on the command:</p>
  
  <pre><code>progressDialog-&gt;close();
  </code></pre>
  
  <p>I don't know what is happening, can someone help me?</p>
  
  <p>Thanks</p>