WidgetFactory 5.0 Release
As you've probably guessed, WidgetFactory 5's main feature is that it fully supports Captivate 5 and all the new widgety features that come with it (see below). However, the good news is that it is still fully compatible with Captivate 4. In fact, many of the new features in WidgetFactory 5 work with Captivate 4 as well.
If you're too excited to read further, and just have to download it right now, here's the link:
Download WidgetFactory from Google Code!
New Features
Captivate 5 introduced some great new features to widgets, and we've included support for all of them in WF5. For example, you can now:
- Set the size of the Properties Dialog (formerly Widget Parameters tab) with propertiesDialogWidth and propertiesDialogHeight.
- Tell Captivate when it is safe to take a snap shot of the widget to display on the stage with the isReadyForStageSnapShot property.
- Make the background of the widget appear to be the same colour as the Properties Dialog with the drawPropertiesDialogBackground() method.
- Disable the Properties Dialog with the disablePropertiesDialog() method (if your widget has no properties for the Captivate Author to set).
- Use the WidgetEvent.ENTER_MOVIE event to know when your widget is at the start of the movie.
- Use the WidgetEvent.MOVIE_ENDED event to know when the Captivate Movie is on its last frame.
- Use the WidgetEvent.ENTER_SLIDE event to know when your widget is on the first frame of a new slide.
- Use the WidgetEvent.EXIT_SLIDE event to know when your widget is on the last frame of a slide.
- Use the WidgetEvent.INTERACTIVE_ITEM_SUBMITTED event to know when an interactive item (e.g a button or click box) sends information back to Captivate.
- Use the WidgetEvent.PAUSE event to know when the Captivate Movie is paused.
- Use the WidgetEvent.RESUME event to know when the Captivate Movie is resumed after it was paused.
- Use the QuestionWidgetEvent.QUESTION_SUBMITTED event to know when a question's answer is submitted to Captivate.
However, that's not all of it. There are also a lot of new features that work with both Captivate 5 and Captivate 4. For example, you can now:
- Detect when you're in Captivate 5 or Captivate 4 with the isCaptivate5 and isCaptivate4 properties.
- Define whether the ENTER_RUNTIME event gets dispatched again when the user rewinds the Captivate movie with the dispatchRuntimeAfterRewind property.
- Access the Question Widget's Clear, Back, Skip, and Submit buttons with the clearButton, backButton, skipButton, and submitButton properties
- Access the Question Widget's Question Title and Text with the questionTitle and questionText properties.
- Trigger the Question Widget's submit process with the triggerSubmitProcess() method.
- Strongly type your properties (parameters) using the new BaseProperties class.
- And now a Captivate 4 only feature! Listen to the WidgeEvent.ENTER_PROPERTIES_DIALOG_PREVIEW to detect when your widget is being displayed in the Captivae 4 properties dialog preview window.
We've also incorporated ActionScript 3 Template Methods into WidgetFactory. These methods are alternatives to events. Instead of listening for the WidgetEvent.ENTER_RUNTIME event, you can override the enterRuntime() Template Method, which is called at the same time as the ENTER_RUNTIME event is dispatched. There are corresponding template methods for many of the events in the WidgetEvent and QuestionWidgetEvent classes, such as:
- enterMovie()
- enterPropertiesDialog()
- enterPropertiesDialogPreview()
- enterRuntime()
- enterStage()
- enterWidgetPanelPreview()
- saveProperties()
- clearAnswers()
- disableAnswers()
- enableAnswers()
- setQuestionState()
- compareAnswers()
- submit()
WidgetFactory's online documentation has been updated with loads of detail to teach you all about the new features. Check out the documentation now.
Renames
Along with the new features, a couple of the old ones have had a bit of a face lift. We've decided to go through and rename many of the properties and methods in the API to make them easier to understand, and adhere more closely to Adobe's AS3 coding standards.
This table lists the changes:
| Old Name | New Name |
|---|---|
| varHand | cpVariables |
| movieHandle | movieVariables |
| widgetMode | currentWidgetMode |
| parameters | properties |
| widgetParams | widgetPropertiesRawData |
| slide | widgetSlide |
| answerCorrect | isCorrectAnswer |
| answerComplete | isCompleteAnswer |
| widgetQuestionState | questionState |
| ENTER_EDIT | ENTER_PROPERTIES_DIALOG |
| APPLY_PARAMETERS | SAVE_PROPERTIES |
| RESET_ANSWERS | COMPARE_ANSWERS |
| QUESION_STATE_SET | SET_QUESTION_STATE |
The Widget King Commeth!
Are you frustrated with the lack of information on the web about widgets? Then frustrate no longer. Behold, the Widget King blog! My own blog about everything widget. I shall be updating it regularly with posts to help you start building your own widgets, and squeeze all the functionality you can out of WidgetFactory.
Over the course of the next five weeks, I will be blogging about my top 5 new features in WidgetFactory 5.
Check out the Widget King blog!
Donate to WidgetFactory
If you would like to donate, just click the button below.
It is a good day to be a widget developer.
