Do we really need that many controls in Silverlight?

I was digesting Scott Gutherie's blog on Silverlight 2 Beta 2

We ultimately expect to ship over a 100 controls for Silverlight.

It really made me wonder, do we really need that many different types of controls built-in with the default Silverlight installation?

Beta 2 now has around about 30+ controls, and the only one that I've noticed is missing, is the combo-drop down list control.

I'm guessing if they really plan to end up with so many controls, then perhaps they'll start by porting across all the various controls that currently WPF have and Silverlight doesn't.

Edit:

Oh and some sort of Menu control

Doing a simple timeout page with WebClientApplication

<%@ Application Language="C#" Inherits="Microsoft.Practices.CompositeWeb.WebClientApplication" %>
<script Language="C#" RunAt="Server">

protected override void PrePageExecute(Page page)
{
// True when the current session was recreated with the current request
if (Session.IsNewSession)
{
// redirect if the requested page is not Default or the Timeout page
// or if the request method isn't GET
if ((!(page is Retail.Web._Default) &&
!(page is Retail.Web.Errors.Timeout)) ||
Request.HttpMethod != "GET")
{
Response.Redirect("~/Errors/Timeout.aspx");
return;
}
}
base.PrePageExecute(page);
}
 



This approach relies on the Session.IsNewSession property to tell us if the current session was created with the current request, with a bit of convenience support for the timeout/default pages.


Nikhil has a more detailed solution: Detecting Session Timeout in ASP.NET 2.0 Web Applications if you want to differentiate between



  • new session object and user was really new, (aka no ASP.NET_SessionId)

vs



  • new session object and the user really timed out (aka sorry I was surfing the web and the app timed out)

Nikhil Kothari's behaviour framework for SilverLight

Nikhil here describes a mini behaviour framework for SilverLight, and then proceed to implement a DefaultCommit, AutoComplete and TextFilter behaviours that can be attached to the SilverLight textbox.

Very cool.

http://www.nikhilk.net/Silverlight-Behaviors.aspx

http://www.nikhilk.net/Silverlight-AutoComplete.aspx

Two more SilverLight links

http://silverlight.net/forums/t/3015.aspx

A comparison of SilverLight 1.0 vs Flex/Flash

Some of the SilverLight limitations no longer apply in SilverLight 2.0 beta.

  • Linux support is handled by Moonlight - sponsored by Microsoft via Novell
  • SilverLight has data binding support
  • SilverLight has control library
  • SilverLight control library shipped with full testing tools - I assume these can be modified to do SilverLight unit testing
  • Socket programming is possible now
  • SilverLight has building download support.  Not sure about what upload support means, pushing a data into a web service?
  • Disagree with performance being slower - I would argue that both system would run equally fast.  There's no reason one should be slower than the other.
  • SilverLight is deployed in one XAP file.  The XAML is included so that it can be indexed.

The next link is a RIA test web site.

http://www.bubblemark.com/

On my machine (FireFox):

  • DHTML: 60 fps
  • Flex: 63 fps
  • Flex (cached): 63 fps
  • Java (Swing): 63 fps
  • SilverLight (JavaScript): 56 fps
  • SilverLight (CLR): a whooping 330 fps

You should free up some memory for your browser for the HTML/JavaScript tests - restarting the browser usually does the job.  If you already have 10 tabs open the DHTML/JavaScript ones won't run as well.

Seriously, you got to see this to believe it.

Removing a word from Windows Live Writer user dictionary

So I screwed up.  In my zeal to make sure my blogs are fully spell-checked, I added a misspelt word to my Windows Live Writer user dictionary.

There are no easy way (at least, as far as I could tell) to remove it.  I ended up doing the following:

Open in notepad:

%APPDATA%\Windows Live Writer\Dictionaries\userdic.tlx

Fix the spelling, save the text file back.

Restart Windows Live Writer

I hope this helps someone out there.