Here's the new prototype.

 This is a static prototype showing what the interface will look like.

The UI was constructed using dashcode , the code was then exported and compressed using the compressor classes provided in the icefaces bundle. The java script is loaded via custom icefaces component. A lot more functionality needs to be added to the component, so far only the loading of the supporting javascript is coded.

Here' some photos of the prototype. And if you have an Iphone you can give it a try yourself. here

public class IphoneHelper extends UIInput {

 

public static final String COMPONENET_TYPE = "com.icesoft.faces.IphoneHelper";

public static final String DEFAULT_RENDERER_TYPE =

"com.icesoft.faces.IphoneHelper";

public static final String COMPONENT_FAMILY =

"javax.faces.IphoneHelper";

 

public IphoneHelper() {super();

McvJavascriptContext.includeLib(McvJavascriptContext.PARTS_EXTRAS,

FacesContext.getCurrentInstance());

System.
out.println("mcv context loaded");

}

 

public String getFamily() {return COMPONENT_FAMILY;

}

 

public String getRendererType() {return DEFAULT_RENDERER_TYPE;

}

 

 

 

}

Apple has lifted the non disclosure agreement on us developers, so we can actually start talking about developing on the iphone. DashCode is a module of the xcode development ide. Dashcode is used to create web applications. DashCode uses an extensive helper library of js functions, exposing the most of the iphone UI . But parts is comprised of many small js files in a "parts" directory, this makes it difficult to use it in a custom icefaces control. But there is a way to easily add parts or other libraries like yahoo to an icefaces components project. Combine and compress it like icefaces does with the bridge.

if you look in the bridge directory you will see a compressor.jar file and build.xml

Whats not apparent is that you can substitute your own javascript files and create your own parts-extra file.

<target name="build.bridge" depends="copy, compress" description="Collate bridge code">

<delete file="${script}"/>

<concat destfile="${script}" append="yes" fixlastline="yes" force="no">

<filelist dir="${build.dir}/lib/extras">

<file name="List.js"/>

<file name="setup.js"/>

<file name="Text.js"/>

<file name="ActivityIndicator.js" />

<file name="Transitions.js"/>

<file name="ButtonHandler.js"/>

<file name="StackLayout.js"/>

<file name="Transitions.css"/>

<file name="utilities.js"/>

</filelist>

<filelist dir="${build.dir}/component">

<file name="menu.js"/>

</filelist>

</concat>

</target>

 

Now from a teminal window in os X or the command prompt in windows. Execute : ant in the directory with the build.xml file. If you did this correctly you now have all the helper js fiiles in one compressed files. parts-extras you can add this to the javascriptContext located in your componets jar file. Like described here.

http://web.mac.com/cannonwc/component_writing/Blog/Entries/2008/6/2_Loading_background_javascript.html

In reviewing our plans to do a tutorial on building the listviewTab control we realized that that particular component may be to complex for a beginning tutorial. There will be a tutorial on the listviewTab , just not yet.

 The developement team just uploaded to our svn repository the latest source for listviewTab but in additon they uploaded the first source files for iphonehelper.

Let me explain.

 The common way to build an iphone application is to use a really nice javascript template built on prototype, called IUI by Joe Hewit . However you still need to handcode all the ajax, ie. the xmlhttrequest, at least the prototype versions of those.

The team wanted to create a direct to dom icefaces component that encapsulates that interface. For this we are building our own version of the datatable called appropriately listviewData. But we realized that we would need an additonal component that acted as container component for multiple listviewData components and that's what iphonehelper does. eventually it will encapsulate everything IUI does and more.

IphoneHelper is a fairly simple component, and a nice starting point for a tutorial on writing components.

The lastest source for iphoneHelper have been uploaded to the mooncatventures svn. Incomplete or test versions will always flow from the mooncatventures svn repository to the sourceforge repository, once the source has completed its initial phase.

 

Now on to the tutorial, Keep in mind that the tutorial is a living document and will evolve over time, the initial tutorial should be completed the week of June 9, 2008

 

.............click here to go to the tutorial page.

Icefaces (www.icefaces.org) is a Canadian company that offers a set of jsf components which encapsulate most of the backend that is needed to do proper ajax applications. Including server Push .

It seems natual to use this very rich library to develop custom applications for the apple iphone. The icefaces components are open source under an lgpl license.

 In this series of articles the mooncatventures development team will show you how to leverage two powerful icefaces components the panelTabSet and the DataTable tags to build a web enabled uI for our streaming server. The final application will execute under an objective C written webkit browser. To keep our version of the component distinct from the panelTabSet and the DataTable we will superclass these as new components that extend the former. This is so PanelTabSet , DataTables can be used in the same application as the extended iphone version. This article will focus on the custom tab control

 

Here is the prototype so far.

 

of course  it looks far different on the iphone. If you own an iphone try the above link on it.

 

Welcome to the developers Journal
More Posts