Safari Books Online is a digital library providing on-demand subscription access to thousands of learning resources.
After much work at the whiteboard considering how our goals for the Story Architect application should be translated into a user interface, it was determined that there will be two primary views to the application: a Chooser and an Editor. When you open up the application, you have a number of options available with regard to creating and managing your Stories and Series. You could choose a Story and export it as a file, delete it, change its name, etc. Or you could choose to write, and that leads you to the Editor, where you will be able to do just that. The Editor will provide you with the functionality for attaching descriptions and notes to any part of the Story, as well as a timeline for navigating and extending the Story.
While the functionality for dealing with a Series is a big part of the application, it is far less important to the primary goal of writing a Story, as is management of Cast and Milieu. This book will focus discussion on the primary Story-related use cases and user interface elements. Remember, our major goal for the first iteration is to create and persist a Story, edit and extend its structure, name any part of the structure, and add descriptions and notes to it.
Now we will examine some of the more important pieces of the user
interface. In addition to the main application and components, we will
define one bubbling event called AppEvent that can carry data, and a class
similar to a Value Object called SelectionContext for sharing information about
the current selection among the View Components.
With regard to collaborations, notice that all of these View
Components basically know only their direct child components, the AppEvent class, the SelectionContext class, Enum and its subclasses, and ValueObject and its subclasses. There are no
PureMVC Facade, Mediator, Command, Proxy, or Notification classes referenced anywhere within
the View Components (with the exception of the main application itself,
which must know the Facade to bootstrap
the startup process). View Components expose properties to receive data,
send events to communicate user intentions, observe and conform to the
shared selection context, and interact only with their direct children and
the data objects they are fed (either from a parent component or from a
Mediator).
In the first view, upon opening the application, you can add or choose a Story or Series and access various functionalities associated with your selection. This is called the Chooser View and is shown in Figure 4-1. Functions like creating and managing the Story will open pop-ups to collect and apply the user input.
When you have created or chosen a Story from the list, then you are taken to the Editor View (see Figure 4-2), where you can immediately begin writing the current draft of the last scene in your Story, however the scenes happen to be grouped. You can also reveal the timeline and details components for navigating the Story and extending and annotating.