Getting Started Developing Widgets

This section covers the installation and configuration steps required to get up and running with a  development environment suitable for the creation of Community Edition (CE) plugins.

Tools needed: Eclipse IDE, with integrated Flash Builder with Flex SDK 4.5.x

Files needed: Infinit.e Eclipse plugin

In this section:

Downloading and Installing the Eclipse Plugin

 To develop widgets you will need the CE Eclipse plugin.

1. Download the IWD:infinit.e plugin.

2. Drop the file infinit.e.adobe.eclipse.infiniteModule.plugin_x.x.x.x.jar into your eclipse plugin folder

e.g. for windows users: C:\eclipse\plugins

3. Restart or open Eclipse.

4. To test the plugin is working properly, right click on a Project > click New > Other.  Under the wizard list there should be Infinite Module under the Flash Builder folder.

Note that the Infinite Module also has its own folder, which provides the same functionality.

 

Infinit.e Widget Library

To perform a standalone install of the widget library

1. Download the IWD:infinit.e widget library.

Note that you have already performed this step if you installed the Eclipse plugin.

 

2. To create a Flex project in your eclipse workspace, Select Flex Project under the Flash Builder folder.

3. Click on Next.

4. Give the project a name and select Finish.

Note that you can also use an existing Flex project.

 

5. Drag the infinit.e.widget.library.swc file and the flexlib.swc file from the InfinitePluginAndLibrary.zip file and drop them onto the libs folder in your new project

Eclipse should have automatically added the swc library to the build path as you can see in the Referenced Libraries

Creating a Widget Project

To create a widget

1. Right click on the src folder of your Flex Project and select New > Other.

2. Choose Infinite Module from the Flash Builder folder.

3. Give your widget a name and click on Finish.

If the wizard does not pick up the src folder automatically, select Browse and navigate to your projects src folder e.g. /projectname/src)

 

The wizard should automatically add 2 files to your project a sandbox to run your new widget in named InfiniteTestApplication.mxml and your widget which you named in the previous step (e.g. sampleWidget.mxml).

4. To run the example, right click on the InfiniteTestApplication.mxml and select Run As > Web Application.


5. Add your widgets logic into the sampleWidget.mxml file (or whatever you named your widget) and run sample queries by logging in and then searching on a term.

Alternative Method

As an alternative you can import IWD:this pre-made project directly into Eclipse.  

To import the project directly

  1. In eclipse go to File > Import.
  2. Under General choose Existing Projects into Workspace.
  3. Click the radio button for Select archive file.
  4. Click browse and navigate to the zip folder you just downloaded (widgetSampleProject.zip
  5. Click Finish.  

This should open a flex project named widgetSampleProject into your workspace with pre-made files ready to run.