Closed barrc closed 4 years ago
@barrc very interesting. Apparently, it seems that it only does this when the main window is maximized, any other size window won't get resized when running simulation.
@TongZhai that's correct. I was looking at the code and I think it's happening in the below section of frmRunSWMM.py, specifically the statement in the try/except block. If you get rid of the try/except block the window doesn't get resized and it doesn't seem to cause any problems, but I'm not sure the difference between the two showNormal calls?
if self._main_form:
try:
self._main_form.showNormal()
except:
pass
self.showNormal()
@barrc thanks for the tip, I will take a look at this.
@barrc you are right, the _main_form is referencing the main window of the application and you are also right in that there is no particular reason for it, so that action is removed. Please help confirm this fix, you can close the issue afterwards, thanks.
@TongZhai tested successfully in my development environment so I'll close the issue. Thanks!
If I have the SWMM UI maximized, every time I run a simulation it becomes "unmaximized". The program shouldn't change its state unless the user asks. I don't think this happened with older versions of the UI.
Before:
After:
Version: MTP6r1