Silverlight controls library has been upgraded to Beta 2

15 ביוני 2008

2 תגובות

[This blog was migrated. You will not be able to comment here.
The new URL of this post is http://khason.net/blog/silverlight-controls-library-has-been-upgraded-to-beta-2/]


Finally this weekend I got  a time to upgrade one of my OpenUp submissions, Silverlight controls library to work with Silverlight 2.0 beta 2. It was very interesting to track changes between developer’s (beta 1) and production (beta 2) go-live licenses. Let’s try to understand what has need changed.

  1. Syntax of DependencyProperty registration. Now instead of DependencyProperty.Register(name, propertyType,ownerType,propertyChangedCallback) you should use DependencyProperty.Register(name, propertyType,ownerType,typeMetadata), which, actually receives only one parameter in constructor – propertyChangedCallback. This make Silverlight to be closer to WPF syntax and open it for future enhancements. You can download updated Visual Studio 2008 snippet for creation of Silverlight Dependency Properties.
  2. OnApplyTemplate method of UserControl become public instead of protected
  3. Thumb DragDelta event argument is not DragEventArg anymore. Now it’s DragDeltaEventArgs. So there is no HorizontalOffset and VerticalOffset attributes. They replaced by HorizontalChange and VerticalChange
  4. DefaultStyleKey is not null anymore
  5. Most of controls migrated from System.Windows.Controls into System.Windows namespace
  6. Some changed to ToolTip service
  7. Now Silverlight checks whether TargetType property of Style is really compatible with the control, you’re applying style to (this not happened in beta 1). Also DependencyObject.SetValue() method checks it’s type.
  8. There is no InitializeFromXaml anymore. Now Silverlight works more “WPF style” with application services – Application.LoadComponent()
  9. You cannot use x:Name and Name property together (someone did it?)

There are a ton of other changed, that was not related to Silverlight Control Library. For example, changed within Storyboard class, networking, cross-domain policy, other controls (e.g. DataGrid), Templates of some controls (e.g. Button, TextBox, etc) and API.

Also I want to invite you to take part into development of Silverlight controls library not because of complimentary ticket to PDC ‘08 or Mobile Memory Mouse 8000, but because Open Source is not “one-men-show”. To get access to SVN, submit your work and begin development of next generation of Silverlight controls, contact me via CodePlex and I’ll add you to the project as new contributor.

הוסף תגובה
facebook linkedin twitter email

כתיבת תגובה

האימייל לא יוצג באתר. (*) שדות חובה מסומנים

2 תגובות

  1. Maxim15 ביוני 2008 ב 20:14

    Thanks for snippets, work fine :)
    MS doesn't know what is "backwards support"! After the update my old projects don't run. Why don't write "[deprecated]" on old redundant class members like in Java?

    להגיב
  2. Tamir Khason15 ביוני 2008 ב 20:18

    Maxim, it was not "production ready" it was beta with developers "go live". Thus developers can recompile and change code a bit :)

    להגיב