Skip to content

Commit

Permalink
Prevent crash from setting negative size
Browse files Browse the repository at this point in the history
This change temporarily fixes several issues, as described in xceedsoftware#1381 and xceedsoftware#1379. The fix is such that the AvalonDock will no longer crash when the control goes out of bounds. However, this does not prevent the actual control from going out of bounds. Therefore, this fix should only be used as a stop-gap until an actual fix can be implemented.
  • Loading branch information
nonsensesoftware authored Oct 17, 2018
1 parent 1b0114d commit 38d36f2
Showing 1 changed file with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ public GridLength DockWidth
}
set
{
if( DockWidth != value )
if( DockWidth != value && value.Value > 0 )
{
RaisePropertyChanging( "DockWidth" );
_dockWidth = value;
Expand All @@ -74,7 +74,7 @@ public GridLength DockHeight
}
set
{
if( DockHeight != value )
if( DockHeight != value && value.Value > 0 )
{
RaisePropertyChanging( "DockHeight" );
_dockHeight = value;
Expand Down

0 comments on commit 38d36f2

Please sign in to comment.