Adorner Layer lost when windows are dragged around...

Docking/MDI for WPF Forum

Posted 14 years ago by SledgeHammer01
Version: 10.1.0521
Platform: .NET 4.0
Environment: Windows XP (32-bit)
I have the following scenario:

__thumbnail view | full size image view

The DocumentImageWindow is derived from DocumentWindow and houses a thumbnail view <grid splitter> full size image view.

When I create the DocumentImageView, I'm displaying multiple images. An Image control gets created for each page and inserted into a stack panel. When I get the OnLoaded message, I get the adorner layer for the stack panel and create an adorner for each Image control and insert it into the adorner layer.

All works fine.

If I drag DocumentImageWindow around and dock it, the adorner layer gets lost.

I searched the forums and found this thread

Is that the same issue? That its "a Microsoft bug"? Is there a work-around?

[Modified at 04/26/2010 01:47 PM]

Comments (1)

Posted 14 years ago by SledgeHammer01
Never mind, I solved the problem. I'll leave this thread up for others with the same problem.

This is a Microsoft bug.

WORK-AROUND: Wrap your AdornerLayer UIElement object (in my case, the StackPanel) in an AdornerDecorator object. Now, when you dock windows around, the AdornerLayer doesn't get lost.
The latest build of this product (v24.1.2) was released 2 months ago, which was after the last post in this thread.

Add Comment

Please log in to a validated account to post comments.