Notes on WPF Changes
from February 2006 CTP
to Beta 2
The Beta 2
build of WinFX contains API changes from the February 2006 Community Technology
Preview (CTP). While the basic design and principles discussed in Programming
Windows Presentation Foundation: Beta Edition are unchanged, some of the
details are different from our
last list of changes (from November 2005 CTP to February 2006 CDP).
You’ll
also want to check out Tim’s “What’s new in Beta 2?” page: http://blogs.msdn.com/tims/archive/2006/05/23/605418.aspx
Layout
- In
previous builds, the order in which items appear in a panel can determine
both the layout and the Z order. (This is not true of all panels, but it’s
true for any panel where the ordering is significant for the layout, e.g.
StackPanel, WrapPanel, DockPanel.) Now, it is possible to control the Z
order separately using the Panel.ZIndex attached property. This works much
like the Z index in earlier UI technologies in Windows
Resources
- References
to resources can no longer be forward references. A {StaticResource} or
{DynamicResource} must now refer to a resource already defined, whereas
before, it could refer to ones defined later in the file.
Interop
- The ElementHost class no longer has multiple children, but
instead has a single child. The while the following works in the Feb CTP:
// Feb CTP
host.Control.Add(avButton);
This is what you’ll need to do in
beta 2:
// Beta 2
host.Child = avButton;
Also, is seems as if the display
isn’t updated ‘til an ElementHost is resized, although I’m not sure why that is
just yet.