Free Trial

Safari Books Online is a digital library providing on-demand subscription access to thousands of learning resources.


  • Create BookmarkCreate Bookmark
  • Create Note or TagCreate Note or Tag
  • DownloadDownload
  • PrintPrint
Share this Page URL
Help

CHAPTER 4: Silverlight Controls > Multiple Mouse Click Support

Multiple Mouse Click Support

One of the new features in Silverlight 5 is support for multiple clicks of the mouse, on both the right and left mouse buttons. You can use this feature to add support for double-clicking and triple-clicking (or however many clicks you would like to support). This is done with the addition of a new property on the MouseButtonEventArgs object called ClickCount. This property is now populated with the number of clicks that the user has made. Let’s walk through a quick example to demonstrate this feature.

Try It Out: Multiple Click Support

Let’s get started by defining event handlers within the XAML markup:

  1. Create a new Silverlight application in Visual Studio called MultiClick. Allow Visual Studio to create a Web Application project to host the application.

  

You are currently reading a PREVIEW of this book.

                                                                                        

Get instant access to over
$1 million worth of books and videos.

  

Start a Free Trial