<?xml version="1.0" encoding="utf-8"?>
<rss xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:pingback="http://madskills.com/public/xml/rss/module/pingback/" xmlns:trackback="http://madskills.com/public/xml/rss/module/trackback/" xmlns:wfw="http://wellformedweb.org/CommentAPI/" xmlns:slash="http://purl.org/rss/1.0/modules/slash/" xmlns:dc="http://purl.org/dc/elements/1.1/" version="2.0">
  <channel>
    <title>John S Blackman</title>
    <link>http://www.johnblackman.com/</link>
    <description>Contribute, look dumb, fear not, repeat.</description>
    <language>en-us</language>
    <copyright>John S Blackman</copyright>
    <lastBuildDate>Thu, 17 Apr 2008 14:40:36 GMT</lastBuildDate>
    <generator>newtelligence dasBlog 2.0.7226.0</generator>
    <managingEditor>johnsblac@gmail.com</managingEditor>
    <webMaster>johnsblac@gmail.com</webMaster>
    <item>
      <trackback:ping>http://www.johnblackman.com/Trackback.aspx?guid=c5257208-0803-4ff3-a8d3-167469276a73</trackback:ping>
      <pingback:server>http://www.johnblackman.com/pingback.aspx</pingback:server>
      <pingback:target>http://www.johnblackman.com/PermaLink,guid,c5257208-0803-4ff3-a8d3-167469276a73.aspx</pingback:target>
      <dc:creator>John S Blackman</dc:creator>
      <wfw:comment>http://www.johnblackman.com/CommentView,guid,c5257208-0803-4ff3-a8d3-167469276a73.aspx</wfw:comment>
      <wfw:commentRss>http://www.johnblackman.com/SyndicationService.asmx/GetEntryCommentsRss?guid=c5257208-0803-4ff3-a8d3-167469276a73</wfw:commentRss>
      <body xmlns="http://www.w3.org/1999/xhtml">Last night I actually sat down and watched
part of the Democratic debate.  I was hoping for some engaging discussion about
how to differentiate Hillary from Obama.  Instead it was a tabloid hash out. 
The <a href="http://www.washingtonpost.com/wp-dyn/content/article/2008/04/17/AR2008041700013_pf.html">Washington
Post</a> was dead on with their assessment.  Instead of probing the candidates
about how they would handle large issues that affect the future of the country like
health care, the budget, Iraq, the falling dollar, immigration, and legislative gridlock,
ABC decided to pander to the Enquirer crowd.  Most of what I could stand to watch
was arguing over sound bites, who said what about whom, who was electable, and which
friend of yours said something nasty about the other side.  All of it useless
and mostly irrelevant to how each potential leader would handle the future of this
country.<br /><br />
However, there is a ray of hope, at least spoken about by some.  Tim Robbins' <a href="http://adage.com/article?article_id=126431">speech</a> at
the National Association of Broadcasters meeting in Las Vegas this month offers a
compelling vision, which is at the heart of why networks run debates like a high school
lunch room instead of a forum for deciding the future of the American nation. 
The speech was considered highly controversial.  After listening to it, the fact
that it was considered controversial is at the root of the problem.<br /><br />
So instead of complaining, create, make something good for others to be inspired by. 
The above is certainly my share of complaint, and Tim's speech is in my opinion something
to be inspired by.<br /><p></p><img width="0" height="0" src="http://www.johnblackman.com/aggbug.ashx?id=c5257208-0803-4ff3-a8d3-167469276a73" /></body>
      <title>The decline of democracy</title>
      <guid isPermaLink="false">http://www.johnblackman.com/PermaLink,guid,c5257208-0803-4ff3-a8d3-167469276a73.aspx</guid>
      <link>http://www.johnblackman.com/2008/04/17/TheDeclineOfDemocracy.aspx</link>
      <pubDate>Thu, 17 Apr 2008 14:40:36 GMT</pubDate>
      <description>Last night I actually sat down and watched part of the Democratic debate.&amp;nbsp; I was hoping for some engaging discussion about how to differentiate Hillary from Obama.&amp;nbsp; Instead it was a tabloid hash out.&amp;nbsp; The &lt;a href="http://www.washingtonpost.com/wp-dyn/content/article/2008/04/17/AR2008041700013_pf.html"&gt;Washington
Post&lt;/a&gt; was dead on with their assessment.&amp;nbsp; Instead of probing the candidates
about how they would handle large issues that affect the future of the country like
health care, the budget, Iraq, the falling dollar, immigration, and legislative gridlock,
ABC decided to pander to the Enquirer crowd.&amp;nbsp; Most of what I could stand to watch
was arguing over sound bites, who said what about whom, who was electable, and which
friend of yours said something nasty about the other side.&amp;nbsp; All of it useless
and mostly irrelevant to how each potential leader would handle the future of this
country.&lt;br&gt;
&lt;br&gt;
However, there is a ray of hope, at least spoken about by some.&amp;nbsp; Tim Robbins' &lt;a href="http://adage.com/article?article_id=126431"&gt;speech&lt;/a&gt; at
the National Association of Broadcasters meeting in Las Vegas this month offers a
compelling vision, which is at the heart of why networks run debates like a high school
lunch room instead of a forum for deciding the future of the American nation.&amp;nbsp;
The speech was considered highly controversial.&amp;nbsp; After listening to it, the fact
that it was considered controversial is at the root of the problem.&lt;br&gt;
&lt;br&gt;
So instead of complaining, create, make something good for others to be inspired by.&amp;nbsp;
The above is certainly my share of complaint, and Tim's speech is in my opinion something
to be inspired by.&lt;br&gt;
&lt;p&gt;
&lt;/p&gt;
&lt;img width="0" height="0" src="http://www.johnblackman.com/aggbug.ashx?id=c5257208-0803-4ff3-a8d3-167469276a73" /&gt;</description>
      <comments>http://www.johnblackman.com/CommentView,guid,c5257208-0803-4ff3-a8d3-167469276a73.aspx</comments>
      <category>Politics</category>
    </item>
    <item>
      <trackback:ping>http://www.johnblackman.com/Trackback.aspx?guid=417c1fad-9851-46da-b897-9eb40008086a</trackback:ping>
      <pingback:server>http://www.johnblackman.com/pingback.aspx</pingback:server>
      <pingback:target>http://www.johnblackman.com/PermaLink,guid,417c1fad-9851-46da-b897-9eb40008086a.aspx</pingback:target>
      <dc:creator>John S Blackman</dc:creator>
      <wfw:comment>http://www.johnblackman.com/CommentView,guid,417c1fad-9851-46da-b897-9eb40008086a.aspx</wfw:comment>
      <wfw:commentRss>http://www.johnblackman.com/SyndicationService.asmx/GetEntryCommentsRss?guid=417c1fad-9851-46da-b897-9eb40008086a</wfw:commentRss>
      <body xmlns="http://www.w3.org/1999/xhtml">
        <p>
Got <a href="http://www.dailymail.co.uk/pages/live/articles/news/worldnews.html?in_article_id=559133&amp;in_page_id=1811" target="_blank">this</a> off
the Drudge Report this morning.  It's more writing on the wall, but it sets the
context very well for what is coming.  There's no need to fight it, so we'd better
get used to embracing China as the world's next super power.  Let's just hope
it's a peaceful transition.  Their rise is affecting manufacturing job markets
the most right now.  Software and IT services still hold an edge in experience
because kids getting out of Chinese universities just haven't shipped software yet. 
This will change though.  Right now most companies have a hard time getting the
value out of overseas development houses that cost less.  I suspect the US and
Silicon Valley have maybe 15 to 20 years before anyone working in those markets can
be easily outsourced to very reliable, highly experienced developers in China or India. 
So save up now, and start looking for property in less expensive regions where your
VISA is valid, and the money you save now will go further, as income pressure for
American IT workers will force real wages lower.
</p>
        <img width="0" height="0" src="http://www.johnblackman.com/aggbug.ashx?id=417c1fad-9851-46da-b897-9eb40008086a" />
      </body>
      <title>Reality Check</title>
      <guid isPermaLink="false">http://www.johnblackman.com/PermaLink,guid,417c1fad-9851-46da-b897-9eb40008086a.aspx</guid>
      <link>http://www.johnblackman.com/2008/04/12/RealityCheck.aspx</link>
      <pubDate>Sat, 12 Apr 2008 18:18:23 GMT</pubDate>
      <description>&lt;p&gt;
Got &lt;a href="http://www.dailymail.co.uk/pages/live/articles/news/worldnews.html?in_article_id=559133&amp;amp;in_page_id=1811" target="_blank"&gt;this&lt;/a&gt; off
the Drudge Report this morning.&amp;#160; It's more writing on the wall, but it sets the
context very well for what is coming.&amp;#160; There's no need to fight it, so we'd better
get used to embracing China as the world's next super power.&amp;#160; Let's just hope
it's a peaceful transition.&amp;#160; Their rise is affecting manufacturing job markets
the most right now.&amp;#160; Software and IT services still hold an edge in experience
because kids getting out of Chinese universities just haven't shipped software yet.&amp;#160;
This will change though.&amp;#160; Right now most companies have a hard time getting the
value out of overseas development houses that cost less.&amp;#160; I suspect the US and
Silicon Valley have maybe 15 to 20 years before anyone working in those markets can
be easily outsourced to very reliable, highly experienced developers in China or India.&amp;#160;
So save up now, and start looking for property in less expensive regions where your
VISA is valid, and the money you save now will go further, as income pressure for
American IT workers will force real wages lower.
&lt;/p&gt;
&lt;img width="0" height="0" src="http://www.johnblackman.com/aggbug.ashx?id=417c1fad-9851-46da-b897-9eb40008086a" /&gt;</description>
      <comments>http://www.johnblackman.com/CommentView,guid,417c1fad-9851-46da-b897-9eb40008086a.aspx</comments>
    </item>
    <item>
      <trackback:ping>http://www.johnblackman.com/Trackback.aspx?guid=d346525c-918e-4928-a99d-c56f1187432f</trackback:ping>
      <pingback:server>http://www.johnblackman.com/pingback.aspx</pingback:server>
      <pingback:target>http://www.johnblackman.com/PermaLink,guid,d346525c-918e-4928-a99d-c56f1187432f.aspx</pingback:target>
      <dc:creator>John S Blackman</dc:creator>
      <wfw:comment>http://www.johnblackman.com/CommentView,guid,d346525c-918e-4928-a99d-c56f1187432f.aspx</wfw:comment>
      <wfw:commentRss>http://www.johnblackman.com/SyndicationService.asmx/GetEntryCommentsRss?guid=d346525c-918e-4928-a99d-c56f1187432f</wfw:commentRss>
      <title>Test Driven Development, no wait Domain Driven Design.</title>
      <guid isPermaLink="false">http://www.johnblackman.com/PermaLink,guid,d346525c-918e-4928-a99d-c56f1187432f.aspx</guid>
      <link>http://www.johnblackman.com/2008/04/10/TestDrivenDevelopmentNoWaitDomainDrivenDesign.aspx</link>
      <pubDate>Thu, 10 Apr 2008 06:52:50 GMT</pubDate>
      <description>

&lt;p class="MsoNormal" style="margin-bottom: 0.0001pt; line-height: normal;"&gt;
&lt;span style="font-size: 12pt; font-family: &amp;quot;Times New Roman&amp;quot;,&amp;quot;serif&amp;quot;;"&gt;Today
I had the opportunity to practice some more test driven development with a resident
expert in the field, &lt;a href="http://www.bellware.net/"&gt;&lt;span style="color: blue;"&gt;Scott
Bellware&lt;/span&gt;&lt;/a&gt;.&amp;nbsp; Scott is a really excited and engaging guy to be around.&amp;nbsp;
He's really taken on Domain Driven Design, he believes in it, and he can teach it
like you would teach someone to tie their shoes.&amp;nbsp; It's simply second nature for
him.&amp;nbsp; I consider myself a relatively accomplish IT professional.&amp;nbsp; I know
my way around all flavors of C code, object oriented design, and implementation.&amp;nbsp;
Typically I come from the school of thought that you plan what you are going to build
before building it.&amp;nbsp; Write it all down, figure out the hard problems, chop them
into smaller, more manageable ones.&amp;nbsp; Show your solution to someone else, let
them tear it up, and before you start writing any code you have a pretty good idea
of how version 1.0 of what you are creating will look like.&amp;nbsp; Now this is an abbreviated
summary of development, but that being said you can push it into waterfall with milestones,
or agile with a backlog and sprints.&amp;nbsp; 
&lt;br&gt;
&lt;br&gt;
Milestones and sprints are both organizational process.&amp;nbsp; They have very little
to do with actual development.&amp;nbsp; &lt;a href="http://www.amazon.com/Domain-Driven-Design-Tackling-Complexity-Software/dp/0321125215/ref=pd_bbs_sr_1?ie=UTF8&amp;amp;s=books&amp;amp;qid=1207809450&amp;amp;sr=8-1"&gt;&lt;span style="color: blue;"&gt;Domain
Driven Design&lt;/span&gt;&lt;/a&gt; is the bible for this style of development, and we got to
experience a little piece of it implementing just a few straightforward rules in part
of a hypothetical system.&amp;nbsp; I have not read the book, although it is now on the
top of my list.&amp;nbsp; 
&lt;br&gt;
&lt;br&gt;
The paradigm as experienced in an afternoon is code to the test, and isolate your
functionality into 'domains.'&amp;nbsp; Coding to the test is essentially writing your
tests first, simple ones.&amp;nbsp; Write a test, then write the code to get just that
test to work.&amp;nbsp; As you make more tests work, you add more functionality without
adding anything extra.&amp;nbsp; It goes against my grain because you see extensibilities
and optimizations you want to make for future expansion or features you 'know' are
coming simply because you've seen them done that way so many times before.&amp;nbsp; This
is a lot like taking your past out of your coding future, and only writing what is
necessary even if it feels incomplete.&amp;nbsp; If you come to a new feature, write it
down, present it to the client, or whoever is writing the check before writing something
no one may want.&lt;br&gt;
&lt;br&gt;
The domain side of the coin revolves around setting rules for what to and not to write
for given domains.&amp;nbsp; At the core of this is interoperability.&amp;nbsp; Make no piece
of code dependent upon another.&amp;nbsp; If you add an include or a using, that is all
it should take.&amp;nbsp; Everyone who has written software has gone through a project
where they tried to get one little API or feature to work which required just one
include.&amp;nbsp; That one begat another, which begat another, and another until you've
written a state machine for Judges in the Old Testament.&amp;nbsp; Adhering to strict
domains eliminates this.&lt;br&gt;
&lt;br&gt;
Now I am not about to call myself an expert on DDD, but I did like what I saw.&amp;nbsp;
For the purposes of our example, it worked very well and I can envision it to work
well for large projects.&amp;nbsp; One thing is for sure, I will definitely be giving
this new approach a few more cycles.&amp;nbsp; I'll just need the discipline to stick
to it and not jump into coding before testing which is oh so tempting.&lt;o:p&gt;&lt;/o:p&gt;
&lt;/span&gt;
&lt;/p&gt;
&lt;img width="0" height="0" src="http://www.johnblackman.com/aggbug.ashx?id=d346525c-918e-4928-a99d-c56f1187432f" /&gt;</description>
      <comments>http://www.johnblackman.com/CommentView,guid,d346525c-918e-4928-a99d-c56f1187432f.aspx</comments>
      <category>Code</category>
    </item>
    <item>
      <trackback:ping>http://www.johnblackman.com/Trackback.aspx?guid=dc9ae8d2-6676-478b-ad2b-14780e0b9bcb</trackback:ping>
      <pingback:server>http://www.johnblackman.com/pingback.aspx</pingback:server>
      <pingback:target>http://www.johnblackman.com/PermaLink,guid,dc9ae8d2-6676-478b-ad2b-14780e0b9bcb.aspx</pingback:target>
      <dc:creator>John S Blackman</dc:creator>
      <wfw:comment>http://www.johnblackman.com/CommentView,guid,dc9ae8d2-6676-478b-ad2b-14780e0b9bcb.aspx</wfw:comment>
      <wfw:commentRss>http://www.johnblackman.com/SyndicationService.asmx/GetEntryCommentsRss?guid=dc9ae8d2-6676-478b-ad2b-14780e0b9bcb</wfw:commentRss>
      <body xmlns="http://www.w3.org/1999/xhtml">
        <p>
Last week I was in Seattle and Portland to visit friends, family, and business associates.
The weekend turned out to be a marathon of meetings and traveling which produced a
lot of results. Part of the trip was talking to potential employers in the area where
I could work remotely from Texas.
</p>
        <p>
My good friend Jason Herre has recently come under the employment of Microsoft working
on a new team at Microsoft called 'Velocity.' He's been there for just a few months,
and extols the virtues of the group and what they do regularly. Like many groups in
Microsoft, they are expanding and therefore hiring. Jason felt I may be a fit for
one of their heads, so I spent some time with their group on Friday finding out what
they do.
</p>
        <p>
Essentially they encourage and inspire OEM partners to make their machines faster
and reduce the impact of their native software. When you first buy a new computer,
that is as fast as it will ever be. Past day one, your machine gets slower and slower
until you reformat and reinstall it. It's a terrible solution to hear from your tech
savvy relative or support person, "Oh, you should just reinstall." The Velocity team
tackles this with a very cool tool called Xperf. It's a diagnostic tool that hooks
up to Microsoft's remote symbol server and analyzes everything that is using up system
resources on your computer over a given period of time.
</p>
        <p>
This might sound mundane, but there are key periods of computer use which infuriate
consumers and myself alike. They are, 
</p>
        <p>
          <strong>Startup</strong>; "I'm going to go get a cup of coffee or waste some time
for a few minutes because I know that even though I can see the desktop, it's not
going to respond to my inputs until the disk IO light goes off who knows how many
minutes later."
</p>
        <p>
          <strong>Shutdown</strong>: "I swear I'm headed out the door as soon as this computer
turns off. Get your keys. Where's my wallet? Do I have my phone? Do you have the directions
to where we're going? Why hasn't this thing turned off yet?"
</p>
        <p>
          <strong>Sleep/Hibernate</strong>: "Why do you carry your laptop around open? Oh, it
never really shuts off when I close the lid. It just heats up my bag and wastes battery.
If I closed it, by the time I got to the meeting room, it would take longer to come
out of sleep than if I just hard cycled the power."
</p>
        <p>
Anyone who has used a laptop in a business environment has likely run into one or
all of the above. Xperf shows the exact process, the exact driver responsible for
taking up CPU, Disk IO, network, and a myriad of other resources. The tools is not
discriminatory either. It points the finger at OEM software as well as Microsoft processes.
It's the UV light at the crime scene that is your start up experience.
</p>
        <p>
Looking at just one example OEM machine, I could easily tell symptoms like waiting
for a network response, or waiting to detect a piece of hardware that isn't connected,
or a piece of start up software that uses a lot of disk. In many cases there are layers
of offenses that if addressed can shave 15-30 seconds from each of the above scenarios. 
The best part is you can <a href="http://www.microsoft.com/whdc/system/sysperf/perftools.mspx" target="_blank">download</a> the
tools for free to find out where your machine is slow.
</p>
        <img width="0" height="0" src="http://www.johnblackman.com/aggbug.ashx?id=dc9ae8d2-6676-478b-ad2b-14780e0b9bcb" />
      </body>
      <title>Xperf!</title>
      <guid isPermaLink="false">http://www.johnblackman.com/PermaLink,guid,dc9ae8d2-6676-478b-ad2b-14780e0b9bcb.aspx</guid>
      <link>http://www.johnblackman.com/2008/04/08/Xperf.aspx</link>
      <pubDate>Tue, 08 Apr 2008 20:48:57 GMT</pubDate>
      <description>&lt;p&gt;
Last week I was in Seattle and Portland to visit friends, family, and business associates.
The weekend turned out to be a marathon of meetings and traveling which produced a
lot of results. Part of the trip was talking to potential employers in the area where
I could work remotely from Texas.
&lt;/p&gt;
&lt;p&gt;
My good friend Jason Herre has recently come under the employment of Microsoft working
on a new team at Microsoft called 'Velocity.' He's been there for just a few months,
and extols the virtues of the group and what they do regularly. Like many groups in
Microsoft, they are expanding and therefore hiring. Jason felt I may be a fit for
one of their heads, so I spent some time with their group on Friday finding out what
they do.
&lt;/p&gt;
&lt;p&gt;
Essentially they encourage and inspire OEM partners to make their machines faster
and reduce the impact of their native software. When you first buy a new computer,
that is as fast as it will ever be. Past day one, your machine gets slower and slower
until you reformat and reinstall it. It's a terrible solution to hear from your tech
savvy relative or support person, "Oh, you should just reinstall." The Velocity team
tackles this with a very cool tool called Xperf. It's a diagnostic tool that hooks
up to Microsoft's remote symbol server and analyzes everything that is using up system
resources on your computer over a given period of time.
&lt;/p&gt;
&lt;p&gt;
This might sound mundane, but there are key periods of computer use which infuriate
consumers and myself alike. They are, 
&lt;/p&gt;
&lt;p&gt;
&lt;strong&gt;Startup&lt;/strong&gt;; "I'm going to go get a cup of coffee or waste some time
for a few minutes because I know that even though I can see the desktop, it's not
going to respond to my inputs until the disk IO light goes off who knows how many
minutes later."
&lt;/p&gt;
&lt;p&gt;
&lt;strong&gt;Shutdown&lt;/strong&gt;: "I swear I'm headed out the door as soon as this computer
turns off. Get your keys. Where's my wallet? Do I have my phone? Do you have the directions
to where we're going? Why hasn't this thing turned off yet?"
&lt;/p&gt;
&lt;p&gt;
&lt;strong&gt;Sleep/Hibernate&lt;/strong&gt;: "Why do you carry your laptop around open? Oh, it
never really shuts off when I close the lid. It just heats up my bag and wastes battery.
If I closed it, by the time I got to the meeting room, it would take longer to come
out of sleep than if I just hard cycled the power."
&lt;/p&gt;
&lt;p&gt;
Anyone who has used a laptop in a business environment has likely run into one or
all of the above. Xperf shows the exact process, the exact driver responsible for
taking up CPU, Disk IO, network, and a myriad of other resources. The tools is not
discriminatory either. It points the finger at OEM software as well as Microsoft processes.
It's the UV light at the crime scene that is your start up experience.
&lt;/p&gt;
&lt;p&gt;
Looking at just one example OEM machine, I could easily tell symptoms like waiting
for a network response, or waiting to detect a piece of hardware that isn't connected,
or a piece of start up software that uses a lot of disk. In many cases there are layers
of offenses that if addressed can shave 15-30 seconds from each of the above scenarios.&amp;nbsp;
The best part is you can &lt;a href="http://www.microsoft.com/whdc/system/sysperf/perftools.mspx" target="_blank"&gt;download&lt;/a&gt; the
tools for free to find out where your machine is slow.
&lt;/p&gt;
&lt;img width="0" height="0" src="http://www.johnblackman.com/aggbug.ashx?id=dc9ae8d2-6676-478b-ad2b-14780e0b9bcb" /&gt;</description>
      <comments>http://www.johnblackman.com/CommentView,guid,dc9ae8d2-6676-478b-ad2b-14780e0b9bcb.aspx</comments>
      <category>Performance</category>
    </item>
    <item>
      <trackback:ping>http://www.johnblackman.com/Trackback.aspx?guid=5a6719ee-f7d9-4955-87f8-de5dfdad6af8</trackback:ping>
      <pingback:server>http://www.johnblackman.com/pingback.aspx</pingback:server>
      <pingback:target>http://www.johnblackman.com/PermaLink,guid,5a6719ee-f7d9-4955-87f8-de5dfdad6af8.aspx</pingback:target>
      <dc:creator>John S Blackman</dc:creator>
      <wfw:comment>http://www.johnblackman.com/CommentView,guid,5a6719ee-f7d9-4955-87f8-de5dfdad6af8.aspx</wfw:comment>
      <wfw:commentRss>http://www.johnblackman.com/SyndicationService.asmx/GetEntryCommentsRss?guid=5a6719ee-f7d9-4955-87f8-de5dfdad6af8</wfw:commentRss>
      <body xmlns="http://www.w3.org/1999/xhtml">After spending some time with the iPhone
SDK, I've discovered that it is designed in a very Apple sort of way.  Duh. 
The SDK is geared around using specific interface tools they give you.  In my
case I was trying to find a video buffer I could just write to.  This sort of
coding behavior has become frowned upon lately and for good reason.  Writing
to video buffers outside of a sandbox is what brought us exploitable code, viruses,
and crashing software.  This has given rise to the likes of managed code, .NET,
Cocoa, take your pick of sandboxed safe coding environments.  The iPhone SDK
is no different.  You can programatically create image objects (UIView) at instantiation
time, after which they are read only.  There are all sorts of ways, actually
one very striaght forward way of animating them, moving them, and intercepting clicks
on them.  However if you have  a graphics engine that generates a game state
essentially by bit-blt-ing to a video buffer, it looks like the only possibility for
doing this is going to be through OpenGL/ES which doesn't work on the simulator. 
So if I want to take this project any further I'm going to need to buy an iPhone....
drat.<br /><p></p><img width="0" height="0" src="http://www.johnblackman.com/aggbug.ashx?id=5a6719ee-f7d9-4955-87f8-de5dfdad6af8" /></body>
      <title>Keep it simple stupid</title>
      <guid isPermaLink="false">http://www.johnblackman.com/PermaLink,guid,5a6719ee-f7d9-4955-87f8-de5dfdad6af8.aspx</guid>
      <link>http://www.johnblackman.com/2008/03/30/KeepItSimpleStupid.aspx</link>
      <pubDate>Sun, 30 Mar 2008 18:41:33 GMT</pubDate>
      <description>After spending some time with the iPhone SDK, I've discovered that it is designed in a very Apple sort of way.&amp;nbsp; Duh.&amp;nbsp; The SDK is geared around using specific interface tools they give you.&amp;nbsp; In my case I was trying to find a video buffer I could just write to.&amp;nbsp; This sort of coding behavior has become frowned upon lately and for good reason.&amp;nbsp; Writing to video buffers outside of a sandbox is what brought us exploitable code, viruses, and crashing software.&amp;nbsp; This has given rise to the likes of managed code, .NET, Cocoa, take your pick of sandboxed safe coding environments.&amp;nbsp; The iPhone SDK is no different.&amp;nbsp; You can programatically create image objects (UIView) at instantiation time, after which they are read only.&amp;nbsp; There are all sorts of ways, actually one very striaght forward way of animating them, moving them, and intercepting clicks on them.&amp;nbsp; However if you have&amp;nbsp; a graphics engine that generates a game state essentially by bit-blt-ing to a video buffer, it looks like the only possibility for doing this is going to be through OpenGL/ES which doesn't work on the simulator.&amp;nbsp; So if I want to take this project any further I'm going to need to buy an iPhone.... drat.&lt;br&gt;
&lt;p&gt;
&lt;/p&gt;
&lt;img width="0" height="0" src="http://www.johnblackman.com/aggbug.ashx?id=5a6719ee-f7d9-4955-87f8-de5dfdad6af8" /&gt;</description>
      <comments>http://www.johnblackman.com/CommentView,guid,5a6719ee-f7d9-4955-87f8-de5dfdad6af8.aspx</comments>
      <category>Code</category>
      <category>iPhone</category>
    </item>
    <item>
      <trackback:ping>http://www.johnblackman.com/Trackback.aspx?guid=b4dec636-40e7-4b3a-a1ec-e9eb40d75ac0</trackback:ping>
      <pingback:server>http://www.johnblackman.com/pingback.aspx</pingback:server>
      <pingback:target>http://www.johnblackman.com/PermaLink,guid,b4dec636-40e7-4b3a-a1ec-e9eb40d75ac0.aspx</pingback:target>
      <dc:creator>John S Blackman</dc:creator>
      <wfw:comment>http://www.johnblackman.com/CommentView,guid,b4dec636-40e7-4b3a-a1ec-e9eb40d75ac0.aspx</wfw:comment>
      <wfw:commentRss>http://www.johnblackman.com/SyndicationService.asmx/GetEntryCommentsRss?guid=b4dec636-40e7-4b3a-a1ec-e9eb40d75ac0</wfw:commentRss>
      <body xmlns="http://www.w3.org/1999/xhtml">
        <p>
Eureka!  Well it's not that much of a victory, but on a new platform, and one
with a super shiny screen it's fun to see your code work.  So far developing
for the iPhone is remarkably easy.  There are lots of framework objects and samples
to get you started with simple applications.  The first thing I wanted to do
was use the screen to interpret finger swipes.  You would think this would be
built in, and according to the documentation, it is.  However I couldn't get
it to work in the emulator.  Here is the sample code Apple provided to intercept
swipes.
</p>
        <div style="BORDER-RIGHT: gray 1px solid; PADDING-RIGHT: 4px; BORDER-TOP: gray 1px solid; PADDING-LEFT: 4px; FONT-SIZE: 8pt; PADDING-BOTTOM: 4px; MARGIN: 20px 0px 10px; OVERFLOW: auto; BORDER-LEFT: gray 1px solid; WIDTH: 97.5%; CURSOR: text; MAX-HEIGHT: 200px; LINE-HEIGHT: 12pt; PADDING-TOP: 4px; BORDER-BOTTOM: gray 1px solid; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BACKGROUND-COLOR: #f4f4f4">
          <div style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: #f4f4f4; BORDER-BOTTOM-STYLE: none">
            <pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: white; BORDER-BOTTOM-STYLE: none">
              <span style="COLOR: #008000">//
Handles the continuation of a touch.</span>
            </pre>
            <pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: #f4f4f4; BORDER-BOTTOM-STYLE: none">- (<span style="COLOR: #0000ff">void</span>)touchesMoved:(NSSet
*)touches withEvent:(UIEvent *)<span style="COLOR: #0000ff">event</span></pre>
            <pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: white; BORDER-BOTTOM-STYLE: none">{  </pre>
            <pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: #f4f4f4; BORDER-BOTTOM-STYLE: none">
              <span style="COLOR: #008000">//
Enumerates through all touch objects</span>
            </pre>
            <pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: white; BORDER-BOTTOM-STYLE: none">
              <span style="COLOR: #0000ff">for</span> (UITouch
*touch <span style="COLOR: #0000ff">in</span> touches){</pre>
            <pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: #f4f4f4; BORDER-BOTTOM-STYLE: none">
              <span style="COLOR: #0000ff">if</span> (touch.info
&amp; UITouchInfoSwipedDown) {</pre>
            <pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: white; BORDER-BOTTOM-STYLE: none">            touchInfoText.text = <span style="COLOR: #006080">@"Swipe
down"</span>;</pre>
            <pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: #f4f4f4; BORDER-BOTTOM-STYLE: none">        } <span style="COLOR: #0000ff">else</span><span style="COLOR: #0000ff">if</span> (touch.info
&amp; UITouchInfoSwipedUp) {</pre>
            <pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: white; BORDER-BOTTOM-STYLE: none">            touchInfoText.text = <span style="COLOR: #006080">@"Swipe
up"</span>;</pre>
            <pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: #f4f4f4; BORDER-BOTTOM-STYLE: none">        } <span style="COLOR: #0000ff">else</span><span style="COLOR: #0000ff">if</span> (touch.info
&amp; UITouchInfoSwipedRight) {</pre>
            <pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: white; BORDER-BOTTOM-STYLE: none">            touchInfoText.text = <span style="COLOR: #006080">@"Swipe
right"</span>;</pre>
            <pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: #f4f4f4; BORDER-BOTTOM-STYLE: none">        } <span style="COLOR: #0000ff">else</span><span style="COLOR: #0000ff">if</span> (touch.info
&amp; UITouchInfoSwipedLeft) {</pre>
            <pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: white; BORDER-BOTTOM-STYLE: none">            touchInfoText.text = <span style="COLOR: #006080">@"Swipe
left"</span>;</pre>
            <pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: #f4f4f4; BORDER-BOTTOM-STYLE: none">        } </pre>
            <pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: white; BORDER-BOTTOM-STYLE: none">
              <span style="COLOR: #008000">//
Send to the dispatch method, which will make sure the appropriate subview is acted
upon</span>
            </pre>
            <pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: #f4f4f4; BORDER-BOTTOM-STYLE: none">        [self dispatchTouchEvent:[touch view] toPosition:[touch locationInView:self]];</pre>
            <pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: white; BORDER-BOTTOM-STYLE: none">    }</pre>
            <pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: #f4f4f4; BORDER-BOTTOM-STYLE: none">}</pre>
          </div>
        </div>
        <p>
          <a href="http://developer.apple.com/iphone/library/documentation/iPhone/Conceptual/iPhoneOSProgrammingGuide/EventHandling/chapter_9_section_2.html#//apple_ref/doc/uid/TP40007072-CH9-SW8" target="_blank">touchesMoved</a> is
a call back that gets executed while your finger is still moving across the screen. 
Checking the .info member variable against an enumerated bit mask should do the trick. 
In my simulator I could never get these events to fire while dragging across the screen,
so I rolled my own.  It's pretty straight forward, but it works and I get all
of the expected outputs on my cool little app.
</p>
        <div style="BORDER-RIGHT: gray 1px solid; PADDING-RIGHT: 4px; BORDER-TOP: gray 1px solid; PADDING-LEFT: 4px; FONT-SIZE: 8pt; PADDING-BOTTOM: 4px; MARGIN: 20px 0px 10px; OVERFLOW: auto; BORDER-LEFT: gray 1px solid; WIDTH: 97.5%; CURSOR: text; MAX-HEIGHT: 200px; LINE-HEIGHT: 12pt; PADDING-TOP: 4px; BORDER-BOTTOM: gray 1px solid; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BACKGROUND-COLOR: #f4f4f4">
          <div style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: #f4f4f4; BORDER-BOTTOM-STYLE: none">
            <pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: white; BORDER-BOTTOM-STYLE: none">
              <span style="COLOR: #cc6633">#pragma</span> mark
-</pre>
            <pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: #f4f4f4; BORDER-BOTTOM-STYLE: none">
              <span style="COLOR: #cc6633">#pragma</span> mark
=== Touch handling ===</pre>
            <pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: white; BORDER-BOTTOM-STYLE: none">
              <span style="COLOR: #cc6633">#pragma</span> mark</pre>
            <pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: #f4f4f4; BORDER-BOTTOM-STYLE: none"> </pre>
            <pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: white; BORDER-BOTTOM-STYLE: none">- (<span style="COLOR: #0000ff">void</span>)touchesBegan:(NSSet
*)touches withEvent:(UIEvent *)<span style="COLOR: #0000ff">event</span></pre>
            <pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: #f4f4f4; BORDER-BOTTOM-STYLE: none">{</pre>
            <pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: white; BORDER-BOTTOM-STYLE: none">    _labelDirection.text = <span style="COLOR: #006080">@""</span>;</pre>
            <pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: #f4f4f4; BORDER-BOTTOM-STYLE: none"> </pre>
            <pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: white; BORDER-BOTTOM-STYLE: none">
              <span style="COLOR: #008000">//
Save the position</span>
            </pre>
            <pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: #f4f4f4; BORDER-BOTTOM-STYLE: none">
              <span style="COLOR: #0000ff">for</span> (UITouch
*touch <span style="COLOR: #0000ff">in</span> touches) {</pre>
            <pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: white; BORDER-BOTTOM-STYLE: none">
              <span style="COLOR: #008000">//
Send to the dispatch method, which will make sure the appropriate subview is acted
upon</span>
            </pre>
            <pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: #f4f4f4; BORDER-BOTTOM-STYLE: none">        [self dispatchFirstTouchAtPoint:[touch locationInView:self] forEvent:nil];</pre>
            <pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: white; BORDER-BOTTOM-STYLE: none">    }</pre>
            <pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: #f4f4f4; BORDER-BOTTOM-STYLE: none">}</pre>
            <pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: white; BORDER-BOTTOM-STYLE: none"> </pre>
            <pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: #f4f4f4; BORDER-BOTTOM-STYLE: none">
              <span style="COLOR: #008000">//
Saves the first position for reference when the user lets go.</span>
            </pre>
            <pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: white; BORDER-BOTTOM-STYLE: none">-(<span style="COLOR: #0000ff">void</span>)
dispatchFirstTouchAtPoint:(CGPoint)touchPoint forEvent:(UIEvent *)<span style="COLOR: #0000ff">event</span></pre>
            <pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: #f4f4f4; BORDER-BOTTOM-STYLE: none">{</pre>
            <pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: white; BORDER-BOTTOM-STYLE: none">    _myTouchPoint = touchPoint;</pre>
            <pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: #f4f4f4; BORDER-BOTTOM-STYLE: none">}</pre>
            <pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: white; BORDER-BOTTOM-STYLE: none"> </pre>
            <pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: #f4f4f4; BORDER-BOTTOM-STYLE: none">
              <span style="COLOR: #008000">//
Handles the continuation of a touch.</span>
            </pre>
            <pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: white; BORDER-BOTTOM-STYLE: none">- (<span style="COLOR: #0000ff">void</span>)touchesEnded:(NSSet
*)touches withEvent:(UIEvent *)<span style="COLOR: #0000ff">event</span></pre>
            <pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: #f4f4f4; BORDER-BOTTOM-STYLE: none">{  </pre>
            <pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: white; BORDER-BOTTOM-STYLE: none">
              <span style="COLOR: #0000ff">for</span> (UITouch
*touch <span style="COLOR: #0000ff">in</span> touches) {</pre>
            <pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: #f4f4f4; BORDER-BOTTOM-STYLE: none">
              <span style="COLOR: #008000">//
Send to the dispatch method, which will make sure the appropriate subview is acted
upon</span>
            </pre>
            <pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: white; BORDER-BOTTOM-STYLE: none">        [self dispatchTouchEndEvent:[touch view] toPosition:[touch locationInView:self]];</pre>
            <pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: #f4f4f4; BORDER-BOTTOM-STYLE: none">    }</pre>
            <pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: white; BORDER-BOTTOM-STYLE: none">}</pre>
            <pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: #f4f4f4; BORDER-BOTTOM-STYLE: none"> </pre>
            <pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: white; BORDER-BOTTOM-STYLE: none">
              <span style="COLOR: #cc6633">#define</span> MIN_SWIPE_DISTANCE
10</pre>
            <pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: #f4f4f4; BORDER-BOTTOM-STYLE: none"> </pre>
          </div>
          <pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: white; BORDER-BOTTOM-STYLE: none">
            <span style="COLOR: #008000">//
Diffs the start and end points of the swipe to determine direction</span>
          </pre>
          <div style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: #f4f4f4; BORDER-BOTTOM-STYLE: none">
            <pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: white; BORDER-BOTTOM-STYLE: none">-(<span style="COLOR: #0000ff">void</span>)
dispatchTouchEndEvent:(UIView *)theView toPosition:(CGPoint)position</pre>
            <pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: #f4f4f4; BORDER-BOTTOM-STYLE: none">{   </pre>
            <pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: white; BORDER-BOTTOM-STYLE: none">    CGFloat xDelta = position.x - _myTouchPoint.x;</pre>
            <pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: #f4f4f4; BORDER-BOTTOM-STYLE: none">    CGFloat yDelta = position.y - _myTouchPoint.y;</pre>
            <pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: white; BORDER-BOTTOM-STYLE: none"> </pre>
            <pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: #f4f4f4; BORDER-BOTTOM-STYLE: none">
              <span style="COLOR: #008000">//
We only want to see large strokes</span>
            </pre>
            <pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: white; BORDER-BOTTOM-STYLE: none">
              <span style="COLOR: #0000ff">if</span>(abs(xDelta)
&gt; MIN_SWIPE_DISTANCE || abs(yDelta) &gt; MIN_SWIPE_DISTANCE)</pre>
            <pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: #f4f4f4; BORDER-BOTTOM-STYLE: none">    {</pre>
            <pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: white; BORDER-BOTTOM-STYLE: none">
              <span style="COLOR: #008000">//
See which way the stroke went</span>
            </pre>
            <pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: #f4f4f4; BORDER-BOTTOM-STYLE: none">
              <span style="COLOR: #0000ff">if</span>(abs(xDelta)
&gt; abs(yDelta)) {</pre>
            <pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: white; BORDER-BOTTOM-STYLE: none">
              <span style="COLOR: #0000ff">if</span>(xDelta
&gt; 0) {</pre>
            <pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: #f4f4f4; BORDER-BOTTOM-STYLE: none">                _labelDirection.text = <span style="COLOR: #006080">@"Right"</span>;</pre>
            <pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: white; BORDER-BOTTOM-STYLE: none">            }</pre>
            <pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: #f4f4f4; BORDER-BOTTOM-STYLE: none">
              <span style="COLOR: #0000ff">else</span> {</pre>
            <pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: white; BORDER-BOTTOM-STYLE: none">                _labelDirection.text = <span style="COLOR: #006080">@"Left"</span>; </pre>
            <pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: #f4f4f4; BORDER-BOTTOM-STYLE: none">            }</pre>
            <pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: white; BORDER-BOTTOM-STYLE: none">        }</pre>
            <pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: #f4f4f4; BORDER-BOTTOM-STYLE: none">
              <span style="COLOR: #0000ff">else</span>
            </pre>
            <pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: white; BORDER-BOTTOM-STYLE: none">        {</pre>
            <pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: #f4f4f4; BORDER-BOTTOM-STYLE: none">
              <span style="COLOR: #0000ff">if</span>(yDelta
&gt; 0) {</pre>
            <pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: white; BORDER-BOTTOM-STYLE: none">                _labelDirection.text = <span style="COLOR: #006080">@"Down"</span>;</pre>
            <pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: #f4f4f4; BORDER-BOTTOM-STYLE: none">            }</pre>
            <pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: white; BORDER-BOTTOM-STYLE: none">
              <span style="COLOR: #0000ff">else</span> {</pre>
            <pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: #f4f4f4; BORDER-BOTTOM-STYLE: none">                _labelDirection.text = <span style="COLOR: #006080">@"Up"</span>;</pre>
            <pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: white; BORDER-BOTTOM-STYLE: none">            }</pre>
            <pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: #f4f4f4; BORDER-BOTTOM-STYLE: none">        }</pre>
            <pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: white; BORDER-BOTTOM-STYLE: none">    }</pre>
            <pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: #f4f4f4; BORDER-BOTTOM-STYLE: none">
              <span style="COLOR: #008000">//
Short distances are considered clicks</span>
            </pre>
            <pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: white; BORDER-BOTTOM-STYLE: none">
              <span style="COLOR: #0000ff">else</span>
            </pre>
            <pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: #f4f4f4; BORDER-BOTTOM-STYLE: none">    {</pre>
            <pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: white; BORDER-BOTTOM-STYLE: none">        _labelDirection.text = <span style="COLOR: #006080">@"Click"</span>; </pre>
            <pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: #f4f4f4; BORDER-BOTTOM-STYLE: none">    }</pre>
            <pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: white; BORDER-BOTTOM-STYLE: none">}</pre>
          </div>
        </div>
        <p>
          <a href="http://developer.apple.com/iphone/library/documentation/iPhone/Conceptual/iPhoneOSProgrammingGuide/EventHandling/chapter_9_section_2.html#//apple_ref/doc/uid/TP40007072-CH9-SW8" target="_blank">touchesBegan</a> and <a href="http://developer.apple.com/iphone/library/documentation/iPhone/Conceptual/iPhoneOSProgrammingGuide/EventHandling/chapter_9_section_2.html#//apple_ref/doc/uid/TP40007072-CH9-SW8" target="_blank">touchesEnded</a> are
also call backs that get executed when you think they would, when your finger touches
and then leaves the screen.  I use a little subtraction and the magic of absolute
value to determine the drag direction.  Small drags are considered clicks. 
Now I'm ready to plug any code into my directions.  This doesn't use the delta
or the accelerometer that are available, but for my purposes I just need a direction
at this point.
</p>
        <img width="0" height="0" src="http://www.johnblackman.com/aggbug.ashx?id=b4dec636-40e7-4b3a-a1ec-e9eb40d75ac0" />
      </body>
      <title>iPhone directional swipe handler</title>
      <guid isPermaLink="false">http://www.johnblackman.com/PermaLink,guid,b4dec636-40e7-4b3a-a1ec-e9eb40d75ac0.aspx</guid>
      <link>http://www.johnblackman.com/2008/03/29/iPhoneDirectionalSwipeHandler.aspx</link>
      <pubDate>Sat, 29 Mar 2008 00:15:18 GMT</pubDate>
      <description>&lt;p&gt;
Eureka!&amp;nbsp; Well it's not that much of a victory, but on a new platform, and one
with a super shiny screen it's fun to see your code work.&amp;nbsp; So far developing
for the iPhone is remarkably easy.&amp;nbsp; There are lots of framework objects and samples
to get you started with simple applications.&amp;nbsp; The first thing I wanted to do
was use the screen to interpret finger swipes.&amp;nbsp; You would think this would be
built in, and according to the documentation, it is.&amp;nbsp; However I couldn't get
it to work in the emulator.&amp;nbsp; Here is the sample code Apple provided to intercept
swipes.
&lt;/p&gt;
&lt;div style="BORDER-RIGHT: gray 1px solid; PADDING-RIGHT: 4px; BORDER-TOP: gray 1px solid; PADDING-LEFT: 4px; FONT-SIZE: 8pt; PADDING-BOTTOM: 4px; MARGIN: 20px 0px 10px; OVERFLOW: auto; BORDER-LEFT: gray 1px solid; WIDTH: 97.5%; CURSOR: text; MAX-HEIGHT: 200px; LINE-HEIGHT: 12pt; PADDING-TOP: 4px; BORDER-BOTTOM: gray 1px solid; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BACKGROUND-COLOR: #f4f4f4"&gt;
&lt;div style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: #f4f4f4; BORDER-BOTTOM-STYLE: none"&gt;&lt;pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: white; BORDER-BOTTOM-STYLE: none"&gt;&lt;span style="COLOR: #008000"&gt;//
Handles the continuation of a touch.&lt;/span&gt;&lt;/pre&gt;
&lt;pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: #f4f4f4; BORDER-BOTTOM-STYLE: none"&gt;- (&lt;span style="COLOR: #0000ff"&gt;void&lt;/span&gt;)touchesMoved:(NSSet
*)touches withEvent:(UIEvent *)&lt;span style="COLOR: #0000ff"&gt;event&lt;/span&gt;&lt;/pre&gt;
&lt;pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: white; BORDER-BOTTOM-STYLE: none"&gt;{  &lt;/pre&gt;
&lt;pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: #f4f4f4; BORDER-BOTTOM-STYLE: none"&gt;    &lt;span style="COLOR: #008000"&gt;//
Enumerates through all touch objects&lt;/span&gt;&lt;/pre&gt;
&lt;pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: white; BORDER-BOTTOM-STYLE: none"&gt;    &lt;span style="COLOR: #0000ff"&gt;for&lt;/span&gt; (UITouch
*touch &lt;span style="COLOR: #0000ff"&gt;in&lt;/span&gt; touches){&lt;/pre&gt;
&lt;pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: #f4f4f4; BORDER-BOTTOM-STYLE: none"&gt;        &lt;span style="COLOR: #0000ff"&gt;if&lt;/span&gt; (touch.info
&amp;amp; UITouchInfoSwipedDown) {&lt;/pre&gt;
&lt;pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: white; BORDER-BOTTOM-STYLE: none"&gt;            touchInfoText.text = &lt;span style="COLOR: #006080"&gt;@"Swipe
down"&lt;/span&gt;;&lt;/pre&gt;
&lt;pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: #f4f4f4; BORDER-BOTTOM-STYLE: none"&gt;        } &lt;span style="COLOR: #0000ff"&gt;else&lt;/span&gt; &lt;span style="COLOR: #0000ff"&gt;if&lt;/span&gt; (touch.info
&amp;amp; UITouchInfoSwipedUp) {&lt;/pre&gt;
&lt;pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: white; BORDER-BOTTOM-STYLE: none"&gt;            touchInfoText.text = &lt;span style="COLOR: #006080"&gt;@"Swipe
up"&lt;/span&gt;;&lt;/pre&gt;
&lt;pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: #f4f4f4; BORDER-BOTTOM-STYLE: none"&gt;        } &lt;span style="COLOR: #0000ff"&gt;else&lt;/span&gt; &lt;span style="COLOR: #0000ff"&gt;if&lt;/span&gt; (touch.info
&amp;amp; UITouchInfoSwipedRight) {&lt;/pre&gt;
&lt;pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: white; BORDER-BOTTOM-STYLE: none"&gt;            touchInfoText.text = &lt;span style="COLOR: #006080"&gt;@"Swipe
right"&lt;/span&gt;;&lt;/pre&gt;
&lt;pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: #f4f4f4; BORDER-BOTTOM-STYLE: none"&gt;        } &lt;span style="COLOR: #0000ff"&gt;else&lt;/span&gt; &lt;span style="COLOR: #0000ff"&gt;if&lt;/span&gt; (touch.info
&amp;amp; UITouchInfoSwipedLeft) {&lt;/pre&gt;
&lt;pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: white; BORDER-BOTTOM-STYLE: none"&gt;            touchInfoText.text = &lt;span style="COLOR: #006080"&gt;@"Swipe
left"&lt;/span&gt;;&lt;/pre&gt;
&lt;pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: #f4f4f4; BORDER-BOTTOM-STYLE: none"&gt;        } &lt;/pre&gt;
&lt;pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: white; BORDER-BOTTOM-STYLE: none"&gt;        &lt;span style="COLOR: #008000"&gt;//
Send to the dispatch method, which will make sure the appropriate subview is acted
upon&lt;/span&gt;&lt;/pre&gt;
&lt;pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: #f4f4f4; BORDER-BOTTOM-STYLE: none"&gt;        [self dispatchTouchEvent:[touch view] toPosition:[touch locationInView:self]];&lt;/pre&gt;
&lt;pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: white; BORDER-BOTTOM-STYLE: none"&gt;    }&lt;/pre&gt;
&lt;pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: #f4f4f4; BORDER-BOTTOM-STYLE: none"&gt;}&lt;/pre&gt;
&lt;/div&gt;
&lt;/div&gt;
&lt;p&gt;
&lt;a href="http://developer.apple.com/iphone/library/documentation/iPhone/Conceptual/iPhoneOSProgrammingGuide/EventHandling/chapter_9_section_2.html#//apple_ref/doc/uid/TP40007072-CH9-SW8" target=_blank&gt;touchesMoved&lt;/a&gt; is
a call back that gets executed while your finger is still moving across the screen.&amp;nbsp;
Checking the .info member variable against an enumerated bit mask should do the trick.&amp;nbsp;
In my simulator I could never get these events to fire while dragging across the screen,
so I rolled my own.&amp;nbsp; It's pretty straight forward, but it works and I get all
of the expected outputs on my cool little app.
&lt;/p&gt;
&lt;div style="BORDER-RIGHT: gray 1px solid; PADDING-RIGHT: 4px; BORDER-TOP: gray 1px solid; PADDING-LEFT: 4px; FONT-SIZE: 8pt; PADDING-BOTTOM: 4px; MARGIN: 20px 0px 10px; OVERFLOW: auto; BORDER-LEFT: gray 1px solid; WIDTH: 97.5%; CURSOR: text; MAX-HEIGHT: 200px; LINE-HEIGHT: 12pt; PADDING-TOP: 4px; BORDER-BOTTOM: gray 1px solid; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BACKGROUND-COLOR: #f4f4f4"&gt;
&lt;div style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: #f4f4f4; BORDER-BOTTOM-STYLE: none"&gt;&lt;pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: white; BORDER-BOTTOM-STYLE: none"&gt;&lt;span style="COLOR: #cc6633"&gt;#pragma&lt;/span&gt; mark
-&lt;/pre&gt;
&lt;pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: #f4f4f4; BORDER-BOTTOM-STYLE: none"&gt;&lt;span style="COLOR: #cc6633"&gt;#pragma&lt;/span&gt; mark
=== Touch handling ===&lt;/pre&gt;
&lt;pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: white; BORDER-BOTTOM-STYLE: none"&gt;&lt;span style="COLOR: #cc6633"&gt;#pragma&lt;/span&gt; mark&lt;/pre&gt;
&lt;pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: #f4f4f4; BORDER-BOTTOM-STYLE: none"&gt;&amp;nbsp;&lt;/pre&gt;
&lt;pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: white; BORDER-BOTTOM-STYLE: none"&gt;- (&lt;span style="COLOR: #0000ff"&gt;void&lt;/span&gt;)touchesBegan:(NSSet
*)touches withEvent:(UIEvent *)&lt;span style="COLOR: #0000ff"&gt;event&lt;/span&gt;&lt;/pre&gt;
&lt;pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: #f4f4f4; BORDER-BOTTOM-STYLE: none"&gt;{&lt;/pre&gt;
&lt;pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: white; BORDER-BOTTOM-STYLE: none"&gt;    _labelDirection.text = &lt;span style="COLOR: #006080"&gt;@""&lt;/span&gt;;&lt;/pre&gt;
&lt;pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: #f4f4f4; BORDER-BOTTOM-STYLE: none"&gt;&amp;nbsp;&lt;/pre&gt;
&lt;pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: white; BORDER-BOTTOM-STYLE: none"&gt;    &lt;span style="COLOR: #008000"&gt;//
Save the position&lt;/span&gt;&lt;/pre&gt;
&lt;pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: #f4f4f4; BORDER-BOTTOM-STYLE: none"&gt;    &lt;span style="COLOR: #0000ff"&gt;for&lt;/span&gt; (UITouch
*touch &lt;span style="COLOR: #0000ff"&gt;in&lt;/span&gt; touches) {&lt;/pre&gt;
&lt;pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: white; BORDER-BOTTOM-STYLE: none"&gt;        &lt;span style="COLOR: #008000"&gt;//
Send to the dispatch method, which will make sure the appropriate subview is acted
upon&lt;/span&gt;&lt;/pre&gt;
&lt;pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: #f4f4f4; BORDER-BOTTOM-STYLE: none"&gt;        [self dispatchFirstTouchAtPoint:[touch locationInView:self] forEvent:nil];&lt;/pre&gt;
&lt;pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: white; BORDER-BOTTOM-STYLE: none"&gt;    }&lt;/pre&gt;
&lt;pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: #f4f4f4; BORDER-BOTTOM-STYLE: none"&gt;}&lt;/pre&gt;
&lt;pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: white; BORDER-BOTTOM-STYLE: none"&gt;&amp;nbsp;&lt;/pre&gt;
&lt;pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: #f4f4f4; BORDER-BOTTOM-STYLE: none"&gt;&lt;span style="COLOR: #008000"&gt;//
Saves the first position for reference when the user lets go.&lt;/span&gt;&lt;/pre&gt;
&lt;pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: white; BORDER-BOTTOM-STYLE: none"&gt;-(&lt;span style="COLOR: #0000ff"&gt;void&lt;/span&gt;)
dispatchFirstTouchAtPoint:(CGPoint)touchPoint forEvent:(UIEvent *)&lt;span style="COLOR: #0000ff"&gt;event&lt;/span&gt;&lt;/pre&gt;
&lt;pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: #f4f4f4; BORDER-BOTTOM-STYLE: none"&gt;{&lt;/pre&gt;
&lt;pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: white; BORDER-BOTTOM-STYLE: none"&gt;    _myTouchPoint = touchPoint;&lt;/pre&gt;
&lt;pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: #f4f4f4; BORDER-BOTTOM-STYLE: none"&gt;}&lt;/pre&gt;
&lt;pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: white; BORDER-BOTTOM-STYLE: none"&gt;&amp;nbsp;&lt;/pre&gt;
&lt;pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: #f4f4f4; BORDER-BOTTOM-STYLE: none"&gt;&lt;span style="COLOR: #008000"&gt;//
Handles the continuation of a touch.&lt;/span&gt;&lt;/pre&gt;
&lt;pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: white; BORDER-BOTTOM-STYLE: none"&gt;- (&lt;span style="COLOR: #0000ff"&gt;void&lt;/span&gt;)touchesEnded:(NSSet
*)touches withEvent:(UIEvent *)&lt;span style="COLOR: #0000ff"&gt;event&lt;/span&gt;&lt;/pre&gt;
&lt;pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: #f4f4f4; BORDER-BOTTOM-STYLE: none"&gt;{  &lt;/pre&gt;
&lt;pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: white; BORDER-BOTTOM-STYLE: none"&gt;    &lt;span style="COLOR: #0000ff"&gt;for&lt;/span&gt; (UITouch
*touch &lt;span style="COLOR: #0000ff"&gt;in&lt;/span&gt; touches) {&lt;/pre&gt;
&lt;pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: #f4f4f4; BORDER-BOTTOM-STYLE: none"&gt;        &lt;span style="COLOR: #008000"&gt;//
Send to the dispatch method, which will make sure the appropriate subview is acted
upon&lt;/span&gt;&lt;/pre&gt;
&lt;pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: white; BORDER-BOTTOM-STYLE: none"&gt;        [self dispatchTouchEndEvent:[touch view] toPosition:[touch locationInView:self]];&lt;/pre&gt;
&lt;pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: #f4f4f4; BORDER-BOTTOM-STYLE: none"&gt;    }&lt;/pre&gt;
&lt;pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: white; BORDER-BOTTOM-STYLE: none"&gt;}&lt;/pre&gt;
&lt;pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: #f4f4f4; BORDER-BOTTOM-STYLE: none"&gt;&amp;nbsp;&lt;/pre&gt;
&lt;pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: white; BORDER-BOTTOM-STYLE: none"&gt;&lt;span style="COLOR: #cc6633"&gt;#define&lt;/span&gt; MIN_SWIPE_DISTANCE
10&lt;/pre&gt;
&lt;pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: #f4f4f4; BORDER-BOTTOM-STYLE: none"&gt;&amp;nbsp;&lt;/pre&gt;
&lt;/div&gt;
&lt;pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: white; BORDER-BOTTOM-STYLE: none"&gt;&lt;span style="COLOR: #008000"&gt;//
Diffs the start and end points of the swipe to determine direction&lt;/span&gt;&lt;/pre&gt;
&lt;div style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: #f4f4f4; BORDER-BOTTOM-STYLE: none"&gt;&lt;pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: white; BORDER-BOTTOM-STYLE: none"&gt;-(&lt;span style="COLOR: #0000ff"&gt;void&lt;/span&gt;)
dispatchTouchEndEvent:(UIView *)theView toPosition:(CGPoint)position&lt;/pre&gt;
&lt;pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: #f4f4f4; BORDER-BOTTOM-STYLE: none"&gt;{   &lt;/pre&gt;
&lt;pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: white; BORDER-BOTTOM-STYLE: none"&gt;    CGFloat xDelta = position.x - _myTouchPoint.x;&lt;/pre&gt;
&lt;pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: #f4f4f4; BORDER-BOTTOM-STYLE: none"&gt;    CGFloat yDelta = position.y - _myTouchPoint.y;&lt;/pre&gt;
&lt;pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: white; BORDER-BOTTOM-STYLE: none"&gt;&amp;nbsp;&lt;/pre&gt;
&lt;pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: #f4f4f4; BORDER-BOTTOM-STYLE: none"&gt;    &lt;span style="COLOR: #008000"&gt;//
We only want to see large strokes&lt;/span&gt;&lt;/pre&gt;
&lt;pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: white; BORDER-BOTTOM-STYLE: none"&gt;    &lt;span style="COLOR: #0000ff"&gt;if&lt;/span&gt;(abs(xDelta)
&amp;gt; MIN_SWIPE_DISTANCE || abs(yDelta) &amp;gt; MIN_SWIPE_DISTANCE)&lt;/pre&gt;
&lt;pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: #f4f4f4; BORDER-BOTTOM-STYLE: none"&gt;    {&lt;/pre&gt;
&lt;pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: white; BORDER-BOTTOM-STYLE: none"&gt;        &lt;span style="COLOR: #008000"&gt;//
See which way the stroke went&lt;/span&gt;&lt;/pre&gt;
&lt;pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: #f4f4f4; BORDER-BOTTOM-STYLE: none"&gt;        &lt;span style="COLOR: #0000ff"&gt;if&lt;/span&gt;(abs(xDelta)
&amp;gt; abs(yDelta)) {&lt;/pre&gt;
&lt;pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: white; BORDER-BOTTOM-STYLE: none"&gt;            &lt;span style="COLOR: #0000ff"&gt;if&lt;/span&gt;(xDelta
&amp;gt; 0) {&lt;/pre&gt;
&lt;pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: #f4f4f4; BORDER-BOTTOM-STYLE: none"&gt;                _labelDirection.text = &lt;span style="COLOR: #006080"&gt;@"Right"&lt;/span&gt;;&lt;/pre&gt;
&lt;pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: white; BORDER-BOTTOM-STYLE: none"&gt;            }&lt;/pre&gt;
&lt;pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: #f4f4f4; BORDER-BOTTOM-STYLE: none"&gt;            &lt;span style="COLOR: #0000ff"&gt;else&lt;/span&gt; {&lt;/pre&gt;
&lt;pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: white; BORDER-BOTTOM-STYLE: none"&gt;                _labelDirection.text = &lt;span style="COLOR: #006080"&gt;@"Left"&lt;/span&gt;; &lt;/pre&gt;
&lt;pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: #f4f4f4; BORDER-BOTTOM-STYLE: none"&gt;            }&lt;/pre&gt;
&lt;pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: white; BORDER-BOTTOM-STYLE: none"&gt;        }&lt;/pre&gt;
&lt;pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: #f4f4f4; BORDER-BOTTOM-STYLE: none"&gt;        &lt;span style="COLOR: #0000ff"&gt;else&lt;/span&gt;&lt;/pre&gt;
&lt;pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: white; BORDER-BOTTOM-STYLE: none"&gt;        {&lt;/pre&gt;
&lt;pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: #f4f4f4; BORDER-BOTTOM-STYLE: none"&gt;            &lt;span style="COLOR: #0000ff"&gt;if&lt;/span&gt;(yDelta
&amp;gt; 0) {&lt;/pre&gt;
&lt;pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: white; BORDER-BOTTOM-STYLE: none"&gt;                _labelDirection.text = &lt;span style="COLOR: #006080"&gt;@"Down"&lt;/span&gt;;&lt;/pre&gt;
&lt;pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: #f4f4f4; BORDER-BOTTOM-STYLE: none"&gt;            }&lt;/pre&gt;
&lt;pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: white; BORDER-BOTTOM-STYLE: none"&gt;            &lt;span style="COLOR: #0000ff"&gt;else&lt;/span&gt; {&lt;/pre&gt;
&lt;pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: #f4f4f4; BORDER-BOTTOM-STYLE: none"&gt;                _labelDirection.text = &lt;span style="COLOR: #006080"&gt;@"Up"&lt;/span&gt;;&lt;/pre&gt;
&lt;pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: white; BORDER-BOTTOM-STYLE: none"&gt;            }&lt;/pre&gt;
&lt;pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: #f4f4f4; BORDER-BOTTOM-STYLE: none"&gt;        }&lt;/pre&gt;
&lt;pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: white; BORDER-BOTTOM-STYLE: none"&gt;    }&lt;/pre&gt;
&lt;pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: #f4f4f4; BORDER-BOTTOM-STYLE: none"&gt;    &lt;span style="COLOR: #008000"&gt;//
Short distances are considered clicks&lt;/span&gt;&lt;/pre&gt;
&lt;pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: white; BORDER-BOTTOM-STYLE: none"&gt;    &lt;span style="COLOR: #0000ff"&gt;else&lt;/span&gt;&lt;/pre&gt;
&lt;pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: #f4f4f4; BORDER-BOTTOM-STYLE: none"&gt;    {&lt;/pre&gt;
&lt;pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: white; BORDER-BOTTOM-STYLE: none"&gt;        _labelDirection.text = &lt;span style="COLOR: #006080"&gt;@"Click"&lt;/span&gt;; &lt;/pre&gt;
&lt;pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: #f4f4f4; BORDER-BOTTOM-STYLE: none"&gt;    }&lt;/pre&gt;
&lt;pre style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 8pt; PADDING-BOTTOM: 0px; MARGIN: 0em; OVERFLOW: visible; WIDTH: 100%; COLOR: black; BORDER-TOP-STYLE: none; LINE-HEIGHT: 12pt; PADDING-TOP: 0px; FONT-FAMILY: consolas, 'Courier New', courier, monospace; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BACKGROUND-COLOR: white; BORDER-BOTTOM-STYLE: none"&gt;}&lt;/pre&gt;
&lt;/div&gt;
&lt;/div&gt;
&lt;p&gt;
&lt;a href="http://developer.apple.com/iphone/library/documentation/iPhone/Conceptual/iPhoneOSProgrammingGuide/EventHandling/chapter_9_section_2.html#//apple_ref/doc/uid/TP40007072-CH9-SW8" target=_blank&gt;touchesBegan&lt;/a&gt; and &lt;a href="http://developer.apple.com/iphone/library/documentation/iPhone/Conceptual/iPhoneOSProgrammingGuide/EventHandling/chapter_9_section_2.html#//apple_ref/doc/uid/TP40007072-CH9-SW8" target=_blank&gt;touchesEnded&lt;/a&gt; are
also call backs that get executed when you think they would, when your finger touches
and then leaves the screen.&amp;nbsp; I use a little subtraction and the magic of absolute
value to determine the drag direction.&amp;nbsp; Small drags are considered clicks.&amp;nbsp;
Now I'm ready to plug any code into my directions.&amp;nbsp; This doesn't use the delta
or the accelerometer that are available, but for my purposes I just need a direction
at this point.
&lt;/p&gt;
&lt;img width="0" height="0" src="http://www.johnblackman.com/aggbug.ashx?id=b4dec636-40e7-4b3a-a1ec-e9eb40d75ac0" /&gt;</description>
      <comments>http://www.johnblackman.com/CommentView,guid,b4dec636-40e7-4b3a-a1ec-e9eb40d75ac0.aspx</comments>
      <category>Code</category>
      <category>iPhone</category>
    </item>
    <item>
      <trackback:ping>http://www.johnblackman.com/Trackback.aspx?guid=14574cb2-4274-407c-bfea-04153c81fced</trackback:ping>
      <pingback:server>http://www.johnblackman.com/pingback.aspx</pingback:server>
      <pingback:target>http://www.johnblackman.com/PermaLink,guid,14574cb2-4274-407c-bfea-04153c81fced.aspx</pingback:target>
      <dc:creator>John S Blackman</dc:creator>
      <wfw:comment>http://www.johnblackman.com/CommentView,guid,14574cb2-4274-407c-bfea-04153c81fced.aspx</wfw:comment>
      <wfw:commentRss>http://www.johnblackman.com/SyndicationService.asmx/GetEntryCommentsRss?guid=14574cb2-4274-407c-bfea-04153c81fced</wfw:commentRss>
      <body xmlns="http://www.w3.org/1999/xhtml">So I am trying my hand at writing code
on the Mac for the first time ever.  My wife (an artist, and therefore Mac owner)
has been kind enough to lend me her laptop so that I might install Xcode and the iPhone
SDK upon it.  Laden with this new power, I now dive into documentation and the
Xcode development environment.<br /><br />
I've only been at it for a single day, but so far I am a fish out of water. 
I find the tools to be very lacking compared to Visual Studio.  I do realize
this is likely to my lack of understanding of the tools, but there isn't intelli-sense 
for the Xcode SDK.  This feature for the .NET envoironment is a huge time saver. 
I'm sure there is a coca equivelant, but I have yet to find it.  I don't know
all the shortcuts yet so it's taking me a lot longer to write code.  The largest
obstacle of course is the fact that everything is based on BSD which I haven't used
since college.  The other side of the fence is a fascinating and difficult place
to navigate.  All of those shinny candy buttons compell me to forge on!<br /><br />
I am currently trying to port some file IO code written by my friend <a href="http://www.jrepp.com">Jacob
Repp</a> to do the same thing in OS X.  Jacob is an excellent engineer and most
of his code is already entirely portable, so by the end of this I'm hoping to have
a how to guide for writing OS X equivelant file IO.  Surprisingly I couldn't
find much on porting in this direction on the web.  There's plenty in each column,
but not much for going between them.<br /><br />
I just found this in the Xcode development guide.  This highlights the context
in which Apple does software development.  Notice that revenue stream is not
in this list.<br /><br /><ul><li>
What do you expect to be the user’s motivation for using the application?</li><li>
What do you intend to be the user’s experience while using the application?</li><li>
What is the goal or focus of your application?</li><li>
How does your application organize and display the information people care about?
Is there a natural organization associated with the main task of the application?</li></ul><br />
These are all afterthoughts in most development cycles.  The business objective
is usually much higher up, which is important as you need money to pay developers. 
However these human questions will lead to software that is simply more enjoyable
to use.<br /><p></p><img width="0" height="0" src="http://www.johnblackman.com/aggbug.ashx?id=14574cb2-4274-407c-bfea-04153c81fced" /></body>
      <title>Going over to the gray side...</title>
      <guid isPermaLink="false">http://www.johnblackman.com/PermaLink,guid,14574cb2-4274-407c-bfea-04153c81fced.aspx</guid>
      <link>http://www.johnblackman.com/2008/03/27/GoingOverToTheGraySide.aspx</link>
      <pubDate>Thu, 27 Mar 2008 04:04:57 GMT</pubDate>
      <description>So I am trying my hand at writing code on the Mac for the first time ever.&amp;nbsp; My wife (an artist, and therefore Mac owner) has been kind enough to lend me her laptop so that I might install Xcode and the iPhone SDK upon it.&amp;nbsp; Laden with this new power, I now dive into documentation and the Xcode development environment.&lt;br&gt;
&lt;br&gt;
I've only been at it for a single day, but so far I am a fish out of water.&amp;nbsp;
I find the tools to be very lacking compared to Visual Studio.&amp;nbsp; I do realize
this is likely to my lack of understanding of the tools, but there isn't intelli-sense&amp;nbsp;
for the Xcode SDK.&amp;nbsp; This feature for the .NET envoironment is a huge time saver.&amp;nbsp;
I'm sure there is a coca equivelant, but I have yet to find it.&amp;nbsp; I don't know
all the shortcuts yet so it's taking me a lot longer to write code.&amp;nbsp; The largest
obstacle of course is the fact that everything is based on BSD which I haven't used
since college.&amp;nbsp; The other side of the fence is a fascinating and difficult place
to navigate.&amp;nbsp; All of those shinny candy buttons compell me to forge on!&lt;br&gt;
&lt;br&gt;
I am currently trying to port some file IO code written by my friend &lt;a href="http://www.jrepp.com"&gt;Jacob
Repp&lt;/a&gt; to do the same thing in OS X.&amp;nbsp; Jacob is an excellent engineer and most
of his code is already entirely portable, so by the end of this I'm hoping to have
a how to guide for writing OS X equivelant file IO.&amp;nbsp; Surprisingly I couldn't
find much on porting in this direction on the web.&amp;nbsp; There's plenty in each column,
but not much for going between them.&lt;br&gt;
&lt;br&gt;
I just found this in the Xcode development guide.&amp;nbsp; This highlights the context
in which Apple does software development.&amp;nbsp; Notice that revenue stream is not
in this list.&lt;br&gt;
&lt;br&gt;
&lt;ul&gt;
&lt;li&gt;
What do you expect to be the user’s motivation for using the application?&lt;/li&gt;
&lt;li&gt;
What do you intend to be the user’s experience while using the application?&lt;/li&gt;
&lt;li&gt;
What is the goal or focus of your application?&lt;/li&gt;
&lt;li&gt;
How does your application organize and display the information people care about?
Is there a natural organization associated with the main task of the application?&lt;/li&gt;
&lt;/ul&gt;
&lt;br&gt;
These are all afterthoughts in most development cycles.&amp;nbsp; The business objective
is usually much higher up, which is important as you need money to pay developers.&amp;nbsp;
However these human questions will lead to software that is simply more enjoyable
to use.&lt;br&gt;
&lt;p&gt;
&lt;/p&gt;
&lt;img width="0" height="0" src="http://www.johnblackman.com/aggbug.ashx?id=14574cb2-4274-407c-bfea-04153c81fced" /&gt;</description>
      <comments>http://www.johnblackman.com/CommentView,guid,14574cb2-4274-407c-bfea-04153c81fced.aspx</comments>
      <category>Code</category>
      <category>Mac</category>
    </item>
    <item>
      <trackback:ping>http://www.johnblackman.com/Trackback.aspx?guid=9f79319f-608f-45d6-a39c-3afbdc4524e0</trackback:ping>
      <pingback:server>http://www.johnblackman.com/pingback.aspx</pingback:server>
      <pingback:target>http://www.johnblackman.com/PermaLink,guid,9f79319f-608f-45d6-a39c-3afbdc4524e0.aspx</pingback:target>
      <dc:creator>John S Blackman</dc:creator>
      <wfw:comment>http://www.johnblackman.com/CommentView,guid,9f79319f-608f-45d6-a39c-3afbdc4524e0.aspx</wfw:comment>
      <wfw:commentRss>http://www.johnblackman.com/SyndicationService.asmx/GetEntryCommentsRss?guid=9f79319f-608f-45d6-a39c-3afbdc4524e0</wfw:commentRss>
      <slash:comments>1</slash:comments>
      <body xmlns="http://www.w3.org/1999/xhtml">
        <p>
I am an avid reader of <a href="http://www.foreignpolicy.com">Foreign Policy</a>,
and there is an awakening article in the March|April issue titled Iraq's 100 - Year
Mortgage.  Healthcare is the leading category on our checks in the United States
for a lot of reasons which I won't go into here.  It's no surprise that heath
care costs for Veterans are a contributing portion of that pie.  Currently the
US spends approximately $280 Billion per year funding the Iraq war.  I'm not
here to judge whether that expense is justified or not.  There are good reasons
on both sides of the argument for that expense.  The long term cost however goes
unnoticed by most I believe.
</p>
        <p>
According to <a href="http://www.foreignpolicy.com/story/cms.php?story_id=4175">Linda
J. Bilmes research</a>, medical technology has allowed the wounded to killed (US troops
only) in Iraq to achieve a 7:1 ratio, up from 2:1 in WWII, and 2.6 in Vietnam. 
More surviving troops is a great thing.  The cost associated with their long
term medical care is something that is not often considered.  The medical costs
for the 1991 invasion in terms of all the care that veterans of that war will expend
is sighted as five times more than the cost of moving the gear, pulling the triggers,
and moving it back.  Iraq, like most American military actions after WWII will
end for lack of money.  Congress will run out of patience and money eventually. 
As soon as there is a politician giving America a choice between war and lower healthcare
costs, and those affected by such healthcare outnumber those that don't, that candidate
will win.  It may already be happening now.  November will tell.
</p>
        <p>
Regan era economists after the cold war came to the conclusion that 'deficits don't
matter.'  As a means to an end of the Cold War, maybe they didn't.  However
we are going to be in for a deficit that's even worse than the one Regan created. 
So maybe they don't matter up to a point that we haven't reached yet.  I do not
know what that point is.  Ultimately the US will get the rest of the world, well
actually nations that lend money to the US, to pay for the Iraq war for us. 
This is some consolation for the credit bill that is due to our future.  Seeing
has how the Federal Reserve has been lowering rates to ease panic on Wall Street,
it has chosen one of two poor routes to travel.  In this case it has chosen inflation
over slowing economic growth, even though we may end up with both.  Inflation
will continue to weaken the dollar and the US will pay back it's debts over the coming
decades, but at a nice discount since the dollars it will pay them back in are up
to 50% weaker than the ones it borrowed;  thank you China!  I used to argue
that the Fed should suck it up and stick or even raise rates to save the dollar and
hold inflation at bay as an amateur economist.  If this were one big game of <a href="http://www.2kgames.com/civ4/home.htm">Civilization
IV</a>, I'd do what they are doing now.  It's national self interest, everyone
is doing it.
</p>
        <img width="0" height="0" src="http://www.johnblackman.com/aggbug.ashx?id=9f79319f-608f-45d6-a39c-3afbdc4524e0" />
      </body>
      <title>The other mortgage crisis.</title>
      <guid isPermaLink="false">http://www.johnblackman.com/PermaLink,guid,9f79319f-608f-45d6-a39c-3afbdc4524e0.aspx</guid>
      <link>http://www.johnblackman.com/2008/03/23/TheOtherMortgageCrisis.aspx</link>
      <pubDate>Sun, 23 Mar 2008 22:32:30 GMT</pubDate>
      <description>&lt;p&gt;
I am an avid reader of &lt;a href="http://www.foreignpolicy.com"&gt;Foreign Policy&lt;/a&gt;,
and there is an awakening article in the March|April issue titled Iraq's 100 - Year
Mortgage.&amp;#160; Healthcare is the leading category on our checks in the United States
for a lot of reasons which I won't go into here.&amp;#160; It's no surprise that heath
care costs for Veterans are a contributing portion of that pie.&amp;#160; Currently the
US spends approximately $280 Billion per year funding the Iraq war.&amp;#160; I'm not
here to judge whether that expense is justified or not.&amp;#160; There are good reasons
on both sides of the argument for that expense.&amp;#160; The long term cost however goes
unnoticed by most I believe.
&lt;/p&gt;
&lt;p&gt;
According to &lt;a href="http://www.foreignpolicy.com/story/cms.php?story_id=4175"&gt;Linda
J. Bilmes research&lt;/a&gt;, medical technology has allowed the wounded to killed (US troops
only) in Iraq to achieve a 7:1 ratio, up from 2:1 in WWII, and 2.6 in Vietnam.&amp;#160;
More surviving troops is a great thing.&amp;#160; The cost associated with their long
term medical care is something that is not often considered.&amp;#160; The medical costs
for the 1991 invasion in terms of all the care that veterans of that war will expend
is sighted as five times more than the cost of moving the gear, pulling the triggers,
and moving it back.&amp;#160; Iraq, like most American military actions after WWII will
end for lack of money.&amp;#160; Congress will run out of patience and money eventually.&amp;#160;
As soon as there is a politician giving America a choice between war and lower healthcare
costs, and those affected by such healthcare outnumber those that don't, that candidate
will win.&amp;#160; It may already be happening now.&amp;#160; November will tell.
&lt;/p&gt;
&lt;p&gt;
Regan era economists after the cold war came to the conclusion that 'deficits don't
matter.'&amp;#160; As a means to an end of the Cold War, maybe they didn't.&amp;#160; However
we are going to be in for a deficit that's even worse than the one Regan created.&amp;#160;
So maybe they don't matter up to a point that we haven't reached yet.&amp;#160; I do not
know what that point is.&amp;#160; Ultimately the US will get the rest of the world, well
actually nations that lend money to the US, to pay for the Iraq war for us.&amp;#160;
This is some consolation for the credit bill that is due to our future.&amp;#160; Seeing
has how the Federal Reserve has been lowering rates to ease panic on Wall Street,
it has chosen one of two poor routes to travel.&amp;#160; In this case it has chosen inflation
over slowing economic growth, even though we may end up with both.&amp;#160; Inflation
will continue to weaken the dollar and the US will pay back it's debts over the coming
decades, but at a nice discount since the dollars it will pay them back in are up
to 50% weaker than the ones it borrowed;&amp;#160; thank you China!&amp;#160; I used to argue
that the Fed should suck it up and stick or even raise rates to save the dollar and
hold inflation at bay as an amateur economist.&amp;#160; If this were one big game of &lt;a href="http://www.2kgames.com/civ4/home.htm"&gt;Civilization
IV&lt;/a&gt;, I'd do what they are doing now.&amp;#160; It's national self interest, everyone
is doing it.
&lt;/p&gt;
&lt;img width="0" height="0" src="http://www.johnblackman.com/aggbug.ashx?id=9f79319f-608f-45d6-a39c-3afbdc4524e0" /&gt;</description>
      <comments>http://www.johnblackman.com/CommentView,guid,9f79319f-608f-45d6-a39c-3afbdc4524e0.aspx</comments>
      <category>Finance</category>
      <category>Politics</category>
    </item>
    <item>
      <trackback:ping>http://www.johnblackman.com/Trackback.aspx?guid=6167bc24-0ca5-481f-b3b8-e51e42dc5ff7</trackback:ping>
      <pingback:server>http://www.johnblackman.com/pingback.aspx</pingback:server>
      <pingback:target>http://www.johnblackman.com/PermaLink,guid,6167bc24-0ca5-481f-b3b8-e51e42dc5ff7.aspx</pingback:target>
      <dc:creator>John S Blackman</dc:creator>
      <wfw:comment>http://www.johnblackman.com/CommentView,guid,6167bc24-0ca5-481f-b3b8-e51e42dc5ff7.aspx</wfw:comment>
      <wfw:commentRss>http://www.johnblackman.com/SyndicationService.asmx/GetEntryCommentsRss?guid=6167bc24-0ca5-481f-b3b8-e51e42dc5ff7</wfw:commentRss>
      <title>Migrating Entourage to Outlook</title>
      <guid isPermaLink="false">http://www.johnblackman.com/PermaLink,guid,6167bc24-0ca5-481f-b3b8-e51e42dc5ff7.aspx</guid>
      <link>http://www.johnblackman.com/2008/03/21/MigratingEntourageToOutlook.aspx</link>
      <pubDate>Fri, 21 Mar 2008 19:25:28 GMT</pubDate>
      <description>&lt;p&gt;
&lt;span style="FONT-SIZE: 10pt; COLOR: #003300; FONT-FAMILY: 'Verdana','sans-serif'"&gt;&lt;?xml:namespace prefix = o ns = "urn:schemas-microsoft-com:office:office" /&gt;You
may be asking yourself, why would anyone be going from a Mac back to a PC.&amp;nbsp; I
mean that's going back into the big market share.&amp;nbsp; Maybe it's for the artists
who gave up, but not many are doing it.&amp;nbsp; I could not find a tool that would import
an Entourage .rge file into Microsoft Outlook 2007.&amp;nbsp; I found some tools to read
.rge files on a mac.&amp;nbsp; Oh and you can transfer your contacts via a tab delimited
text file.&amp;nbsp; What about e-mail?&amp;nbsp; Oh you can copy it to the file system and
loose all you formatting.&amp;nbsp; I guess this just goes to show that the market for
users converting their e-mail 