<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>dougt&#039;s blog &#187; htc</title>
	<atom:link href="http://dougt.org/wordpress/tag/htc/feed/" rel="self" type="application/rss+xml" />
	<link>http://dougt.org/wordpress</link>
	<description>best. tagline. ever.</description>
	<lastBuildDate>Mon, 26 Jul 2010 03:18:35 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	
		<item>
		<title>Orientation in Firefox and beyond</title>
		<link>http://dougt.org/wordpress/2009/08/orientation/</link>
		<comments>http://dougt.org/wordpress/2009/08/orientation/#comments</comments>
		<pubDate>Mon, 24 Aug 2009 03:24:02 +0000</pubDate>
		<dc:creator>dougt</dc:creator>
				<category><![CDATA[mozilla]]></category>
		<category><![CDATA[accelerometer]]></category>
		<category><![CDATA[device api]]></category>
		<category><![CDATA[htc]]></category>
		<category><![CDATA[mobile]]></category>
		<category><![CDATA[MozOrientation]]></category>
		<category><![CDATA[orientation]]></category>

		<guid isPermaLink="false">http://dougt.org/wordpress/?p=452</guid>
		<description><![CDATA[One of the coolest apps I saw when the iPhone came out was the wooden balance game Labyrinth.  You basically tilt your phone to move a ball around the screen, avoiding holes, and trying to get the ball to a goal.  It made use of a feature of many modern devices &#8212; accelerometers. Obviously clear [...]]]></description>
			<content:encoded><![CDATA[<p>One of the coolest apps I saw when the iPhone came out was the wooden balance game <a href="http://en.wikipedia.org/wiki/Labyrinth_%28game%29">Labyrinth</a>.  You basically tilt your phone to move a ball around the screen, avoiding holes, and trying to get the ball to a goal.  It made use of a feature of many modern devices &#8212; accelerometers.</p>
<p>Obviously clear that there should be a webapp for doing just that.  What was missing was a javascript API.</p>
<p>In recent Mozilla trunk builds, I have added support for an orientation event.  This new event will allow you to build applications and listen for changes in orientation.  (note, the first platform to support such an event is any MacBook Pro.  Others will follow).</p>
<p><strong>Simple Call:</strong></p>
<p>To use this new event, you will add an event listener as you normally would:</p>
<p>window.addEventListener(&#8220;MozOrientation&#8221;, orientationChange, true);</p>
<p>Your callback will be called, when there is a change in acceleration, passing the current orientation:</p>
<p>function orientationChange(o) {</p>
<p>}</p>
<p><strong>Simple Result:</strong></p>
<p>The passed object has 3 attributes &#8211; &#8220;x&#8221;, &#8220;y&#8221; and &#8220;z&#8221;.  Each value is between -1 and 1 where zero is the &#8220;balance point&#8221;.  For example, suppose you device is a MacBook Pro and it is sitting on a desk that is perfectly level, you would expect to see:</p>
<p>x = 0<br />
y = 0<br />
z = 1</p>
<p>x is the axis in the direction from the left side of the keyboard to the right side of the keyboard (basically the axis that is along the home row keys) is level.  If I lift up the left side of the keyboard, x will increase.  if I lift up the right side, x will decrease.</p>
<p>y is the axis in the direction from the front of the laptop (where the mouse is) to the back of the laptop.  If I lift up the front of the laptop (the side closest to me), y will decrease.  If I left the back towards the front, y will increase.</p>
<p>Got that?  Yeah, physics is pretty hard. <img src='http://dougt.org/wordpress/wp-includes/images/smilies/icon_sad.gif' alt=':-(' class='wp-smiley' /> </p>
<p>x and y can easily be visualized.  If you have a recent trunk build for the Mac, try loading this demo page:</p>
<p><a href="http://people.mozilla.org/~dougt/ball.html">http://people.mozilla.org/~dougt/ball.html</a></p>
<p>z basically will tell you that the laptop is sitting right side up.  if z was -1, you would know that the laptop (probably closed) and is sitting on its screen.  Of course the value will change as you rotate the laptop / device in this direction.</p>
<p>Right now, there is only support for the Macbook Pro.  It is pretty easy to add support for different OSs.  We have code for Samsung Windows Mobile devices, and for the HTC Windows Mobile devices.  We still need support for linux and for Windows.  If you are interested in adding support file a bug and start looking at <a href="http://mxr.mozilla.org/mozilla-central/source/widget/public/nsIAccelerometer.idl">http://mxr.mozilla.org/mozilla-central/source/widget/public/nsIAccelerometer.idl</a></p>
<p>The API isn&#8217;t fixed and may change.  I do invite you to comment.  Keep in mind that we want a really simple and straight forward API to expose orientation events to web developers.  If your response has either &#8220;RDF&#8221; or &#8220;DCCI&#8221; in it, please reread the last sentence.  <img src='http://dougt.org/wordpress/wp-includes/images/smilies/icon_smile.gif' alt=':-)' class='wp-smiley' /> </p>
<p>Thanks again and hope you enjoy.</p>
]]></content:encoded>
			<wfw:commentRss>http://dougt.org/wordpress/2009/08/orientation/feed/</wfw:commentRss>
		<slash:comments>40</slash:comments>
		</item>
		<item>
		<title>Device Orientation</title>
		<link>http://dougt.org/wordpress/2009/03/device-orientation/</link>
		<comments>http://dougt.org/wordpress/2009/03/device-orientation/#comments</comments>
		<pubDate>Tue, 31 Mar 2009 02:47:51 +0000</pubDate>
		<dc:creator>dougt</dc:creator>
				<category><![CDATA[mozilla]]></category>
		<category><![CDATA[browser]]></category>
		<category><![CDATA[device api]]></category>
		<category><![CDATA[htc]]></category>
		<category><![CDATA[mobile]]></category>
		<category><![CDATA[orientation]]></category>
		<category><![CDATA[wince]]></category>
		<category><![CDATA[windows mobile]]></category>

		<guid isPermaLink="false">http://dougt.wordpress.com/?p=360</guid>
		<description><![CDATA[I have a proposal for exposing device orientation in the browser. It is a pretty simple api that allows you to monitor motion changes from Javascript. For example: navigator.orientation.watchOrientation(draw); function draw(o) { // o.x, o.y, o.z } o in function draw is a vector in three dimensional space in meters / (seconds^2) units. This allows [...]]]></description>
			<content:encoded><![CDATA[<p>I have a proposal for exposing device orientation in the browser.  It is a pretty simple api that allows you to monitor motion changes from Javascript.</p>
<p>For example:</p>
<p><code><br />
navigator.orientation.watchOrientation(draw);</code></p>
<p>function draw(o) {<br />
// o.x, o.y, o.z<br />
}</p>
<p><em>o</em> in function <em>draw</em> is a vector in three dimensional space in meters /<br />
(seconds^2) units.</p>
<p>This allows you to do some revolutionary stuff on the web.  This is a simple test web page that <a href="http://people.mozilla.org/~dougt/ball.html">moves a ball around a web page</a>.  I am just loading this web page directly with <a href="https://developer.mozilla.org/en/XULRunner_1.9_Release_Notes">XUL Runner</a> on Windows Mobile Professional 6.</p>
<p><a href="http://www.youtube.com/watch?v=WYGEZreI_LU">Device Orientation on YouTube</a></p>
<p>This only supports exists on HTC devices but i do expect other devices that have accelerometers to have implementations.</p>
<p>I am tracking this feature in <a href="https://bugzilla.mozilla.org/show_bug.cgi?id=485943">bug 485943</a>.  Please check it out and let me know what you think.</p>
]]></content:encoded>
			<wfw:commentRss>http://dougt.org/wordpress/2009/03/device-orientation/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>A Short History of Mozilla on Windows Mobile</title>
		<link>http://dougt.org/wordpress/2009/02/a-short-history-of-mozilla-on-windows-mobile/</link>
		<comments>http://dougt.org/wordpress/2009/02/a-short-history-of-mozilla-on-windows-mobile/#comments</comments>
		<pubDate>Wed, 11 Feb 2009 01:49:32 +0000</pubDate>
		<dc:creator>dougt</dc:creator>
				<category><![CDATA[mozilla]]></category>
		<category><![CDATA[fennec]]></category>
		<category><![CDATA[htc]]></category>
		<category><![CDATA[minimo]]></category>
		<category><![CDATA[mobile]]></category>
		<category><![CDATA[windows mobile]]></category>

		<guid isPermaLink="false">http://dougt.wordpress.com/2009/02/10/a-short-history-of-mozilla-on-windows-mobile/</guid>
		<description><![CDATA[I thought it might be nice to reflect on my involvement in porting the Mozilla to Windows Mobile. In 2004 we had a project called Minimo &#8212; it was meant as a lighter weight build-time configuration of Mozilla for GTK. To showcase the build options, we had an application called TestGtkEmbed that developers could use [...]]]></description>
			<content:encoded><![CDATA[<p>I thought it might be nice to reflect on my involvement in porting the Mozilla to Windows Mobile.</p>
<p>In 2004 we had a project called Minimo &#8212; it was meant as a lighter weight build-time configuration of Mozilla for GTK.   To showcase the build options, we had an application called TestGtkEmbed that developers could use to test against benchmarks, etc.  As the name implies, it was just a testing application &#8212; it didn&#8217;t have browser features like bookmarks, session history, preference management, etc.</p>
<p>At the end of 2004, I was hired by the Mozilla Foundation working for <a href="http://weblogs.mozillazine.org/chofmann/">Chris Hofmann</a>, who was the director of engineering.  I started on porting this set of build options to Windows Mobile.  At this point, there was no real desire to build an application &#8212; I was happy to just continue building a browser engine that could be part of another application.</p>
<p>I really had no desire to do Windows Mobile development.  However, at the time, it was really the only devices available that people could by off the street and run very large applications on (think: a modern web browser).  The idea was that you could do direct-to-consumer development.</p>
<p>We found that there was some work done by <a href="http://home.mcom.com/people/blythe/">Garrett Blythe</a> (i don&#8217;t have a better link, sorry) at Netscape in 2002 which we could leverage &#8212; there was a partial patch to NSPR for windows mobile.  Garrett was responsible for an effort to port Netscape to Windows CE.  His basic approach to porting from Win32 -&gt; WinCE is is what I continued using (and we still use most of it today).</p>
<p>At the beginning of 2005, <a href="http://blog.mozilla.com/blassey/">Brad Lassey</a> started helping and around March 2005 we had much of the platform ported over.  Below is the picture of the first time mozilla rendered google windows mobile phone:</p>
<p><a href="http://dougt.files.wordpress.com/2009/02/200902090914.jpg"><img src="http://dougt.files.wordpress.com/2009/02/200902090914-tm.jpg" height="200" width="150" border="1" hspace="4" vspace="4" alt="200902090914" /></a></p>
<p>If you want to see other pictures, check out <a href="http://rebron.org/blogarchives/2005/03/minimozilla_com.html">rebron&#8217;s</a> <a href="http://rebron.org/blogarchives/2005/07/mo_minimozilla.html">posts</a> from way back when.</p>
<p>At some point, we needed to branch away from using WinEmbed (basically the same thing as TestGtkEmbed i mentioned above, but for windows) and decided it was a good idea to build a UI for Minimo on Windows Mobile that end users could use.  Looking at something we might be able to share between the linux/gtk version of Minimo and Window Mobile, we decided to write the UI in XUL.  The size/space measurement for using XUL were very small compared to the flexibility you got (we were thinking extensions).</p>
<p><a href="http://dougt.files.wordpress.com/2009/02/200902091038.jpg"><img src="http://dougt.files.wordpress.com/2009/02/200902091038-tm.jpg" height="200" width="150" border="1" hspace="4" vspace="4" alt="200902091038" /></a></p>
<p>Working from Brazil, <a href="http://www.taboca.com/">Marcio Galli</a> was basically responsible for the front end.  We experimented with a bunch of things like social bookmarking, geolocation, device API, and widgets.  We learned alot, and some of this ended up being the basis for a <a href="http://www.w3.org/TR/geolocation-API/">draft spec</a>.</p>
<p>In April 2006, I stopped working on Minimo full time and started other mobile work for Mozilla.  The Minimo project continued.  I tried to work fix the occasional bug, but development basically ended.</p>
<p>At the end of 2007, I blogged about the <a href="http://dougt.wordpress.com/2007/11/13/minimo-and-mobile/">end of Minimo</a> (the windows mobile mozilla browser) and a new effort called <a href="https://wiki.mozilla.org/Mobile/FennecVision">Fennec</a>.  Our team now is much larger than the original effort; we have people in QA, Press, IT, UX, Marketing all thinking about Mobile.<br />
<a href="http://dougt.files.wordpress.com/2009/02/2009020908581.jpg"><img src="http://dougt.files.wordpress.com/2009/02/200902090858-tm1.jpg" height="100" width="161" border="1" hspace="4" vspace="4" alt="200902090858" /></a></p>
<p>Now, we have our first public milestone release.  A completely new font backend, cairo support, extension support, and basically everything that Firefox has.</p>
<p>Today is the rebirth of this browser: Better, stronger, faster.  We have a way to go before we declare a &#8220;1.0&#8243; release, but hope you come with us and participate in open source, mozilla, and Fennec &#8211; our mobile browser.<br />
<a href="http://dougt.files.wordpress.com/2009/02/200902091049.jpg"><img src="http://dougt.files.wordpress.com/2009/02/200902091049-tm.jpg" height="200" width="150" border="1" hspace="4" vspace="4" alt="200902091049" /></a></p>
]]></content:encoded>
			<wfw:commentRss>http://dougt.org/wordpress/2009/02/a-short-history-of-mozilla-on-windows-mobile/feed/</wfw:commentRss>
		<slash:comments>6</slash:comments>
		</item>
		<item>
		<title>Milestone 1: Fennec for Windows Mobile</title>
		<link>http://dougt.org/wordpress/2009/02/milestone-1-fennec-for-windows-mobile/</link>
		<comments>http://dougt.org/wordpress/2009/02/milestone-1-fennec-for-windows-mobile/#comments</comments>
		<pubDate>Wed, 11 Feb 2009 00:45:16 +0000</pubDate>
		<dc:creator>dougt</dc:creator>
				<category><![CDATA[mozilla]]></category>
		<category><![CDATA[fennec]]></category>
		<category><![CDATA[htc]]></category>
		<category><![CDATA[wince]]></category>
		<category><![CDATA[windows mobile]]></category>

		<guid isPermaLink="false">http://dougt.wordpress.com/2009/02/10/milestone-1-fennec-for-windows-mobile/</guid>
		<description><![CDATA[Today we are releasing a pre-alpha version of Fennec for Windows Mobile. This release is pre-alpha. Did I say pre-alpha? Yes, this is pre-alpha and has a way to go in both stability and performance before we release this as &#8220;1.0&#8243;. Please try out and give us feedback! Please file bugs at bugzilla.mozilla.org. Download link: [...]]]></description>
			<content:encoded><![CDATA[<p><a href="http://dougt.org/wordpress/wp-content/uploads/200907141613-1.jpg" onclick="window.open('http://dougt.org/wordpress/wp-content/uploads/200907141613-1.jpg','popup','width=161,height=100,scrollbars=no,resizable=yes,toolbar=no,directories=no,location=no,menubar=no,status=yes,left=0,top=0');return false"><img src="http://dougt.org/wordpress/wp-content/uploads/200907141613-1-tm.jpg" height="100" width="161" border="1" hspace="4" vspace="4" alt="200907141613-1" /></a></p>
<p>Today we are releasing a pre-alpha version of Fennec for Windows Mobile.   This release is pre-alpha.  Did I say pre-alpha?  Yes, this is pre-alpha and has a way to go in both stability and performance before we release this as &#8220;1.0&#8243;.</p>
<p>Please try out and give us feedback!  Please file bugs at <a href="https://bugzilla.mozilla.org/enter_bug.cgi?product=Fennec">bugzilla.mozilla.org</a>.</p>
<p>Download link:<br />
<a href="http://ftp.mozilla.org/pub/mozilla.org/mobile/fennec-0.11.en-US.wince-arm.cab">http://ftp.mozilla.org/pub/mozilla.org/mobile/fennec-0.11.en-US.wince-arm.cab</a><a href="http://people.mozilla.org/~blassey/fennec-m1-rc2.cab"><br />
</a></p>
<p>Brad has instructions here and a great overview:</p>
<p><a href="http://blog.mozilla.com/blassey/2009/02/10/fennec-milestone-release-for-windows-mobile/">http://blog.mozilla.com/blassey/2009/02/10/fennec-milestone-release-for-windows-mobile/</a></p>
<p>Developers:</p>
<p>Get involved.  If you are a windows mobile hacker, we would love your help making Fennec better.  Find us on irc.mozilla.org #wince.</p>
]]></content:encoded>
			<wfw:commentRss>http://dougt.org/wordpress/2009/02/milestone-1-fennec-for-windows-mobile/feed/</wfw:commentRss>
		<slash:comments>5</slash:comments>
		</item>
	</channel>
</rss>
