December 23, 2010
QuickConnect 1.6.4 Now Available
I have just posted the 1.6.4 version of QC on SourceForge. It includes some defect fixes and some minor additions, and a few big changes. QC 1.6.4 requires the iOS 4.2 SDK.
The big changes are regarding the native application templates. You can now use the same design to create Objective-C iPhone, iPad, and Universal iPhone/iPad apps that you have been using to create your hybrid applications.
These native iOS apps come ‘pre-threaded’. Every time you call handleRequest your command stack is executed on a worker thread. Any of your ViewControlObjects that you create for your control Stack are executed in the main thread since it is the only one that is allowed to update the User Interface. All other behavior is done on a worker thread and you don’t have to worry about how to set it up, make it go, or make it stop.
Just as with the hybrid apps you’ve been creating with QC all of your async calls to HTTP servers, portals, etc. are linearized for you. You never need to write another callback function!
In addition to making your remote HTTP calls easier all of the templates for native QuickConnect applications also include support for both direct SQLite access and CoreData.
With a little time working in Interface Builder and putting together some CoreData objects your app is up and running.
Examples are already in the download for all of these native iOS templates. Check them out and see how easy native iOS apps can be.
The next release will have native multi-threaded Android applications as well.
One other change is that the PHP template has been updated. Take a look at the example in the download.
Lee
September 24, 2009
QuickConnectiPhone 1.6 Beta 1 is now available
QCiPhone 1.6 beta 1 is now available from the sourceForge repository. It includes access to the Contacts API via JavaScript as well as a new way of doing GPS locations and tracking. There are two new examples to show how to use the new functionality, GPSExample and Contacts Example.
The old in-application map functionality has been commented out in anticipation of Beta 2 which will include the access to the new 3.0 Map API and in-application email.
Push from within JavaScript and receiving pushes in JavaScript planned for Beta 3.
August 29, 2009
QuickConnectiPhone 1.5.0 is now available
QCiPhone 1.5.0 has just been uploaded to sourceForge. They are saying that it may take about 15 minutes to become visible as the default download for OS X machines.
A note to 3.0 API users. The dashcode QC template no longer appears as an option. I am looking for ways to get it to show up again.End
Because of the 3.0 Dashcode changes I have not been able to update the Dashcode examples to the latest QC source. All of the Xcode examples are updated.
The release includes examples of how to use the video and audio tags in booth QCiPhone and QCMac applications.
QuickConnectMac 1.0 is also included in this release. It allows you to create hybrid applications that run on Mac machines just like you do for the iPhone and iPod touch.
QuickConnectPHP 1.0 is another template that can be used on the Mac side. It isn’t used to create hybrid applications but is used to create PHP web applications.
Also included, for those interested, is QCErlang 1.0. It is an updated version of an Xcode template for developing erlang applications. It includes auto-completes for most of the commonly used functions.
Defect fixes in this release include:
1. UIWebView no longer ends up with a black background after re-displaying the Default.png file while the page loads.
2. DataAccessObject in-browser database use fixed and updated to new methodology for the retention of which BCF in the stack is to be called next.
3. Updated the embedded map code to use the current data passing scheme from and to Objective-C
4. HTML Elements with touch events inside of Elements made scrollable no longer react to ontouchstart, ontouchmove, and ontouchend unless the event is not due to scrolling
August 28, 2009
HTML 5 Video and Audio in UIWebView and WebView
I have been playing with the video and audio tags in the UIWebView on the iPhone and WebView on the Mac. I tried them in the QT WebView as well on linux. I am pleased to announce that they work great! I have tried it with mp3, mp4, and wmv. All worked on all three platforms.
It looks like this is a good way to display videos for your users to play in your hybrid applications.
Let’s say you have a video called someCrazyMovie.mp4 that you want to display to your users. On the iPhone or the Mac put it in the Resources group of your Xcode project that uses a UIWebView. Point the UIWebView to a local html file, also in the resources file.
In this html file put the following code.
<video src=”someCrazyMovie.mp4>A movie description as an alt</video>
When you run your application you will see the first frame of the video used as a representational image. You can play it by clicking it. On the iPhone and iPod touch the movie player launches to play the movie.
The tag lets you size it, display or not display the video controls, etc.
The audio tag is used much the same way.
I’ll include an example for both the iPhone and the Mac in the 1.5.0 release of QuickConnectiPhone 1.5.0
August 4, 2009
New License
Because of the confusion over the LPGP license of QuickConnectiPhone it is now available under the MIT license. It is still open source and free to use to create either open or closed, free or for-cost applications.
I hope this clears up any licensing issues you may have had.
July 31, 2009
QuickConnect 1.5 Release Candidate 1 now Available!
After many setbacks, like a very major hard drive crash and a bug in sourceForge, I have finally been able to release QC 1.5 Release Candidate 1. It is now the default download for the project on sourceForge.
It includes:
- Transaction handling for native databases from the JavaScript DataAccessObject. The example project, NativeDatabaseTransactions, includes:
- start transaction
- commit
- and rollback
- A fix to the native footers disappearing when the orientation changed
- Synced the Dashcode project with the latest code and fixed the run error caused by the rotating image
- A fix that correctly handles all types of URLs such as mailTo, http, https, maps, youtube, etc.
- A total of 32 QCiPhone examples
- not all of the examples have been updated to the latest code set. That will be completed for the final release. If you are willing to volunteer to help with updating the examples please contact me.
May 1, 2009
Scrolling individual elements in hybrid or web applications
A request has been made to show how individual elements in a hybrid or web application can be scrolled on the iPhone. I have included some code below that has all of the JavaScript requried to accomplish this. It comes from the QCUtilities.js file of QuickConnect iPhone 1.5 release that will be posted within a couple of days.
Because it is from QuickConnect it includes the ability to add request handling for when the user touches the screen in preparation for scrolling, as well as each time the finger is moved and when the scroll action is complete. If you want to use this code outside of QuickConnect then remove everything regarding the startDragCmd, dragCmd, and dropCmd parameters.
If you want to use this within an older version of QuickConnectiPhone place the code in your version of the QCUtilities.js file and it works.
This approach uses the CSS transitions, proposed for HTML 5, available in WebKit instead of the standard JavaScript approach since that approach is much to slow for both the iPhone and iPod touch devices.
To make an element scrollable call the makeScrollable function and pass the element you want to be scrollable as the first parameter. If you want the element to not be scrollable below its original y axis location pass true as the second parameter of makeScrollable. Here is the onload event code from the scrollingElements example of the upcoming QuickConnectiPhone 1.5 release that sets three views in a view stack to be scrollable.
Making elements scrollable
function load()
{
dashcode.setupParts();
makeScrollable(document.getElementById(‘view1′));
makeScrollable(document.getElementById(‘view2′));
makeScrollable(document.getElementById(‘view3′));
}
Scrolling Functions to Add
/*
* Pass any DOM element to this function to make it scroll
* The *Cmd parameters are optional commands to be handled for
* scroll events.
*/
function makeScrollable(anElement, scrollBothUpAndDown, startDragCmd, dragCmd, dropCmd){
anElement.ontouchstart = prepareScroll;
anElement.ontouchmove = scrollIt;
anElement.ontouchend = scrollDone;
anElement.scrollBothUpAndDown = scrollBothUpAndDown;
//do not set or reset the commands if none are passed in.
if(startDragCmd){
anElement.startDragCmd = startDragCmd;
}
if(dragCmd){
anElement.dragCmd = dragCmd;
}
if(dropCmd){
anElement.dropCmd = dropCmd;
}
}
/*
* This function is triggered each time an ontouchmove event is
* fired for an element that has been passed to makeDraggable.
*/
function scrollIt(event)
{
stopDefault(event);
this.y = event.targetTouches[0].clientY – this.offsetY;
if(this.lastY){
this.y += this.lastY;
}
if(this.scrollBothUpAndDown || this.y < 0){
this.style.webkitTransform = ‘translate(0px, ‘ + this.y + ‘px)’;
}
else if(this.y >= 0){
this.style.webkitTransform = ‘translate(0px, 0px)’;
}
if(this.dragCmd){
var params = new Array();
params.push(event);
params.push(this);
handleRequest(this.dragCmd, params);
}
}
/*
* This function is triggered every time an ontouchstart event is
* fired for an element that has been passed to makeDraggable.
*/
function prepareScroll(event)
{
stopDefault(event);
//store off any timing and duration set anywhere else in the app
//and turn them off so they don’t interfere with the scrolling
this.timing = this.style.webkitTransitionTimingFunction;
this.style.webkitTransitionTimingFunction = null;
this.duration = this.style.webkitTransitionDuration;
this.style.webkitTransitionDuration = null;
this.touches = event.targetTouches;
this.offsetY = event.targetTouches[0].clientY;
if(this.startDragCmd){
var params = new Array();
params.push(event);
params.push(this);
handleRequest(this.startDragCmd, params);
}
}
/*
* This function is triggered every time an ontouchend event is
* fired for an element that has been passed to makeDraggable.
*/
function scrollDone(event)
{
//this.ontouchmove = null;
//this.ontouchend = null;
if(this.scrollBothUpAndDown || this.y < 0){
this.lastY = this.y;
}
else{
this.lastY = 0;
}
//restore any timing or duration that was set anywhere else in the app
this.style.webkitTransitionTimingFunction = this.timing;
this.style.webkitTransitionDuration = this.duration;
if(this.dropCmd){
var params = new Array();
params.push(event);
params.push(this);
handleRequest(this.dropCmd, params);
}
}
February 7, 2009
QuickConnectiPhone 1.1.3 now available
QCiPhone version 1.1.3 includes the following changes.
- Example applications updated to 1.1.3
- apostrophes in the data of native databases now handled correctly.
- a stopBounce() function added in the JavaScript. It stops the UIWebView from bouncing when the interface fits in the view. Thanks
to Aarpn for the initial code. I’ll work on getting it to be more
flexible. - A Default.png file added so you can replace it with your own.
If you are interested, QCiPhone 1.5 Beta 1 is now available. The announcement is here
February 4, 2009
QuickConnectLinux Beta 1 is Now available
It took longer than expected, but it is here. QuickConnectLinux 1.0 beta 1 uses the 4.5 version of QT as the support for JavaScript application creation. Since the QT 4.5 library license is LGPL just like QuickConnectLinux, when the release of QT 4.5 is shipped by Nokia your applications can be created for free or you can charge for them without any payments or royalties.
The framework access to SQLite databases shipped with the application or created at runtime are both supported in this first beta.
I used Qt creator from Nokia to write the C++/QT back end code.

The nativeDBAccess example application running on Linux
Just like the other members of the QCFamily you write your application in JavaScript, compile it, and ship it. You users can then install the application and run it without access to the internet. QWebView is the class in QT that contains the WebKit engine and makes all of this possible. I have attached an image of the exact same HTML, CSS, and JavaScript used in the QuickConnectiPhone nativeDBAccess example application running on top of the QT port of the native framework.
I’ll put the Qt Creator project up on SourceForge as QuickConnectLinux 1.0 Beta 1.
I can now move back to working more heavily on QCiPhone 1.5 beta and then moving the QCAndroid and Mac versions from Beta to release. After than I will port QCLinux to Symbian. That should be easy since the Linux Beta now exists.
Progress is being made.

