Showing posts with label html5. Show all posts
Showing posts with label html5. Show all posts

Thursday, October 27, 2011

HTMLApplicationHost Framework Posted to Codeplex

One of my projects has been building an HTML Application framework for phone 7. Basically so I can build HTML5 based applications using HTML, JavaScript and CSS for mobile devices in particular Windows Phone but then being able to use that application on other platforms. Today I uploaded version 4 onto codeplex (http://htmlappwp7.codeplex.com/) which adds HTML Host Application back stack integration with the Phone's application navigation stack. On wp7 that means that when you hit the back button it doesn't just navigate out of the app but just to the last view in HTML making really applications easy to do that will get past the marketplace and into the hands of the public but even more important setting the stage for apps on iPhone and android using similar HTML5 based application frameworks.

The first app using this framework was the JavaScript application but now that test app is in the marketplace I've been working on a new real app called 'SMART Spending Habits', its a simple budgeting application designed to priority and sort your purchases automatically. Its a great little tool and it should be in the market place next week or so.

download the HTMLApplicationHost Framework Source code here:
http://htmlappwp7.codeplex.com/

Wednesday, June 15, 2011

Using HTML App Host Tasks from the ECMA Script Context

Using the task framework (http://htmlappwp7.codeplex.com/ and the taskprocessor are pretty easy. Basically it needs to look like this:

window.external.notify("Email:pieseczek@hotmail.com:Email from JavaScriptFWP7");

the format for calls are:

window.external.notify(" Task Name : Paramter1 : Parameter2 : etc ");

the current supported tasks include:

Email : To Email : Subject
SystemTray : Boolean Value
EnableFrameRateCounter : Boolean Value
alert : message value : message box title
play : sound uri path
vibrate : hours : minutes : seconds
MarketplaceSearchTask : app id
Analytics : Parmeters * n
MarketplaceDetailTask : app id
WebBrowserTask : URL String

There is also a custom event on the AppHostShell called ScriptNotify that allows you to extend what you can do with tasks for example in the code base the sample app does this extension from the custom event:


private void webBrowser1_ScriptNotify(object sender, NotifyEventArgs e)
{
switch (e.Value.ToString())
{
case "task1":
EmailComposeTask emailComposeTask = new EmailComposeTask();
emailComposeTask.To = "pieseczek@hotmail.com";
emailComposeTask.Body = "";
emailComposeTask.Subject = "Email from JSWP7";
emailComposeTask.Show();
break;
case "task2":
NavigationService.Navigate(new Uri("/About.xaml", UriKind.Relative));
break;
}

}

this gets around a limition with calling the navigation service that I'm currently working on.

Wednesday, February 2, 2011

HTML 5 Is Dead!

“gasp” what? How can that be? What can this guy be talking about? What can this blogger possibly know and why would he say something so sacrilegious? I’m aghast…


I’m sure that is the kind of response that many of you are having when reading this article but I wanted to make a point, with all the excitement around HTML 5, not so much that its bad but people seem to be in one camp or the other and few are looking at the big picture. Yes HTML 5 is awesome and all but many of the ‘HTML 5 is awesome’ crowd is saying other RIA technologies are dead and it is just not logical to make a whole sale generalization like that and it drives me nuts. I hear things like ‘Flash is dead’ or ‘Silverlight is dead’ (even from some less then razor sharp micrsoftee’s).


HTML fine is the foundation of all our content on the web and all but a technology whose last major version is 10 years old is not making rich immersive technologies like flash out dated? That’s just crazy. Flash and Silverlight both in particular have proven over and over again that they iterate faster and more importantly ‘innovate’ faster than more open technologies like HTML. Both of those technologies do more, better and faster than HTML 5 and are more cross platform, more tool-able and have better dev/workflow stories across the board. But why do people put these technologies up against each other at all? That’s like saying apples are better than oranges? They are just different.


HTML 5 is a cross platform long term foundation for web based content and web based apps and great it now is more richer then before but RIA technologies such as Flash and Silverlight both are not nor have they ever been dubbed as a replacement for HTML (at least not anyone I know). These technologies both live out of the browser and are ways of delivering on all the promises that Java first made when it came out. Rich cross platform immersive UI experiences on so many platforms from droid phones to xbox to browsers and desktop apps.


HTML is for the rich distributed web stuff and Flash and Silverlight is for immersive experiences that may or may not be on the web at all. HTML in the browser or maybe even an HTA sort of app and Flash/Silverlight is for UX that leaps out of the browser. HTML 5 is cool but that doesn’t mean that more powerful RIA technologies are dead. To each his own and to each problem space its technology; there is room enough for it all. Let’s all be a bit less zealous about things and focus on building better apps regardless of the technology you want to use.


Heck if apple had any since they would get flash on the iphone for building cool apps so we don’t have to use that objective C…