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

Part III: Patterns That Primarily Empowe... > Outlets, Targets, and Actions

17. Outlets, Targets, and Actions

When you build a graphical user interface, you need a way to configure user interface objects, such as buttons, sliders, text fields, and menu items, and connect them to application-specific operations. For example, an application might provide a menu item to center selected text and another menu item to send a seating request to an airline reservation system. Finding a good way to connect user interface objects to application-specific operations is a common recurring problem.

One potential solution is to create application-specific subclasses of the user interface objects like menu items. For example, you could create a CenterTextMenuItem class and a SendSeatingRequestMenuItem class. However, there are a number of shortcomings to creating application-specific subclasses of user interface objects.


  

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