Sybase Unwired Platform comes with PhoneGap 1.4.1 libraries linked in; to upgrade to a later version of the PhoneGap library for use by the Hybrid Web Container, there are a few steps you must perform.
The PhoneGap library that is included with the Hybrid Web Container has been slightly modified to support title bars and loading URLs using binary.
getWindow().requestFeature(Window.FEATURE_NO_TITLE)
public void spinnerStop() {
if (this.spinnerDialog != null) {
try
{
this.spinnerDialog.dismiss();
}
catch( Exception e )
{
// an exception occurs if the activity this dialog is associated with is closed
// before this dialog
LOG.d( TAG, "Tried to dismiss a dialog of an activity that no longer exists." );
}
finally
{
this.spinnerDialog = null;
}
}
}
public void loadUrlWithData(String url, byte[] abData)
{
this.loadUrlIntoView(url, abData);
}
private void loadUrlIntoView(final String url) {
loadUrlIntoView( url, null);
}
private void loadUrlIntoView(final String url, final byte[] abData)
if ( abData == null) me.appView.loadUrl(url); else me.appView.loadDataWithBaseURL( url, new String( abData ), null, "utf-8", null );
To change the PhoneGap version for other platforms as well, replace the phonegap-1.4.1.javascript for each platform, for example, for iOS, replace \html\js\ios\phonegap-1.4.1.javascript.