... application
development.
Adobe Flex 4: Training from the Source is an update to the popular Adobe Flex 3: Training from
the Source. It is our sincere intention that readers of the earlier book, as ... build the Fl exGrocer applica t ion seen here.
From the Library of Wow! eBook
Download from www.eBookTM.com
ptg
xviii
Introduction
Adobe Training from...
... to the top-right edge of the container.
4 Find and select the Label control with the copyright notice. Constrain this Label so that it is
10 pixels above the bottom and 10 pixels away from the ...
<s:Label text=”(c) 2009, FlexGrocer” right= 10 ” bottom= 10 ”/>
<s:HGroup x=”0” y=”0” width= 10 0%” height= 10 0%” id=”bodyGroup”>
<s:VGroup width= 10 0%” he...
... creationComplete event (pages 1 04 10 8)
From the Library of Wow! eBook
Download from www.eBookTM.com
ptg
10 7
Handling System Events
1 Open the FlexGrocer.mxml le that you modied in the previous section.
If ... clicked the
button in the control bar, then the property’s value is btnCartView, which is what you
assigned in the code. If you chose the View Cart but...
... item.quantity;
Remember, whenever the AddToCart button is clicked, a new item is added to the cart
with the quantity value set to 1.
From the Library of Wow! eBook
Download from www.eBookTM.com
ptg
14 6
LESSON : ... with Flex controls to update the
display dynamically.
Adding Items to the Cart
In this exercise you will write the code to add items to the shopping...
... ensure you are in the
Debug perspective.
10 Double-click the Variables view. Expand the event object and the result property. Further
expand the <catalog> node beneath the result to ensure ... change the binding to the product property to use item 1
and item 2, while the original is getting item 0.
<s:VGroup width= 10 0%” height= 10 0%”>
<components:Pr...
... room to show 10
renderers, the application will need to create only 10 instances of the renderers rather than
10 00, greatly reducing the impact on the processor and RAM.
From the Library of ... event.timestamp );
}
10 Debug the EventLab application and click both the Ok and Cancel buttons.
WarningDialog: Accept Sun Feb 7 13 :42 :37 GMT-0600 2 010
EventLab: Accep...
... of the cart and the ability to both update and remove items from the cart.
From the Library of Wow! eBook
Download from www.eBookTM.com
ptg
2 91
Displaying the ShoppingCart with a DataGrid
10 ... functionality.
From the Library of Wow! eBook
Download from www.eBookTM.com
ptg
313
Using the AdvancedDataGrid
9 As the last two lines of the function, use the r...
... in the List.
11 Run the application. When you drag from the DataGrid to List, only the name of the
product appears in the List.
is wraps up our second task in this lesson on drag and drop.
From ...
width= 10 0%” height= 10 0%”/>
<checkout:Review orderInfo=”{orderInfo}”
width= 10 0%” height= 10 0%”/>
</mx:ViewStack>
Next you will need to write the han...
... ProductList.
4 Save this le and run the application.
From the Library of Wow! eBook
Download from www.eBookTM.com
ptg
42 1
Creating a Skin for the Application
4 Find the next Rect in the le, which ... larger than it was, the List component doesn’t t
properly in the screen, so the category list will be constrained to stay 17 1 pixels from the
right edge of...