Our application uses DockPanel and has DirectX content panes. I just upgraded the version of DockPanel in our app from 2.2 to 2.3.1. After upgrading to 2.3.1 we found that our application would throw an exception when minimizing the application form. The problem was in the DockPane.SetContentBounds method. When the app is minimized the code that's setting the bounds of the form would cause the exception. In DockPane.SetContentBounds the following line of code was changed from:
if (content.DockHandler.Pane == this && rectContent.Width > 0 && rectContent.Height > 0)
in version 2.2 to:
if (content.DockHandler.Pane == this)
in version 2.3.1. When I reverted this line of code to check the width and height of the content rectangle before trying to set the bounds the problem went away.
Why was this line of code changed? Is this a bug or should we be doing something with our DirectX content windows before minimizing the app window?
Attached is the call stack from the exception. Thanks.
Michael
Exception Call Stack