by Jim McCurdy
28. August 2009 22:36
A minor annoyance of mine is that there is no way to wire up a standard Silverlight TextBox to select its text when it receives the keyboard focus; either via a mouse click or a tab key.
And since users are accustomed to web apps, browsers, and desktop applications that offer the the convenience of selecting textbox text upon focus, I wanted that behavior in my Silverlight applications.&nbs...
[More]
by Jim McCurdy
14. August 2009 22:34
Here is a simple static class, Settings, that offers methods to Read and Write application settings and preferences from Silverlight applications. These settings are similar to the ones that Windows apps would store in the registry or in an INI file, but in this case, are written to Silverlight’s isolated storage.
This class wraps Silverlight’s IsolatedStorageSettings class, so ...
[More]
by Jim McCurdy
7. August 2009 22:32
Here is a simple static class, MouseButtonHelper, that offers a single method, IsDoubleClick, to determine if a standard MouseLeftButtonDown or MouseLeftButtonUp event is a double click. In the past I have used timers, and Triggers and Behaviors to accomplish the same thing, but this approach is less code, less XAML, and uses a lot less resources.
Usage is as follows:
In XAML or in...
[More]