<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
		>
<channel>
	<title>Comments on: Targeting 2.x With 3.0 Features. Trouble Ahead.</title>
	<atom:link href="http://gamesfromwithin.com/targeting-2-x-with-3-0-features-trouble-ahead/feed" rel="self" type="application/rss+xml" />
	<link>http://gamesfromwithin.com/targeting-2-x-with-3-0-features-trouble-ahead</link>
	<description>Living the indie life</description>
	<lastBuildDate>Thu, 17 May 2012 17:38:00 +0000</lastBuildDate>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.2.1</generator>
	<item>
		<title>By: Mike</title>
		<link>http://gamesfromwithin.com/targeting-2-x-with-3-0-features-trouble-ahead/comment-page-1#comment-2897</link>
		<dc:creator>Mike</dc:creator>
		<pubDate>Mon, 31 Aug 2009 09:38:08 +0000</pubDate>
		<guid isPermaLink="false">http://gamesfromwithin.com/?p=549#comment-2897</guid>
		<description>I ran into exactly this problem of debugging in 2.2 with the simulator. As mentioned above, you can attach to the process (i just used &#039;ps -x &#124; grep -i appname&#039;). i had to add a sleep when my app initialises as the crash was coming within the first second. hardly an ideal solution, but hey.

turns out my problem was i subclassed UIButton and while it all works fine under 3.0, 2.x didn&#039;t like it one bit. as soon as the derived button was added to a view it would crash. (no doubt i will now discover that it is well known one shouldn&#039;t subclass UIButton :) ).

@edgard - you can&#039;t launch the mail app in the simulator (it doesn&#039;t exist), so the mailcomposer example will only work in 2.x on a device.</description>
		<content:encoded><![CDATA[<p>I ran into exactly this problem of debugging in 2.2 with the simulator. As mentioned above, you can attach to the process (i just used &#8216;ps -x | grep -i appname&#8217;). i had to add a sleep when my app initialises as the crash was coming within the first second. hardly an ideal solution, but hey.</p>
<p>turns out my problem was i subclassed UIButton and while it all works fine under 3.0, 2.x didn&#8217;t like it one bit. as soon as the derived button was added to a view it would crash. (no doubt i will now discover that it is well known one shouldn&#8217;t subclass UIButton <img src='http://gamesfromwithin.com/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' />  ).</p>
<p>@edgard &#8211; you can&#8217;t launch the mail app in the simulator (it doesn&#8217;t exist), so the mailcomposer example will only work in 2.x on a device.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Edgard Rodriguez</title>
		<link>http://gamesfromwithin.com/targeting-2-x-with-3-0-features-trouble-ahead/comment-page-1#comment-2718</link>
		<dc:creator>Edgard Rodriguez</dc:creator>
		<pubDate>Fri, 14 Aug 2009 10:08:09 +0000</pubDate>
		<guid isPermaLink="false">http://gamesfromwithin.com/?p=549#comment-2718</guid>
		<description>I follow your steps but the button send do nothing in 2.2.1 is like doesn&#039;t have the method to show the ComposerEmail. but in 3.0 works fine.

any help

thanks


&lt;code&gt;
- (void)email
{
	//Can send email 
	//if ([MFMailComposeViewController canSendMail])
	Class mailClass = (NSClassFromString(@&quot;MFMailComposeViewController&quot;));
	if (mailClass != nil &amp;&amp; [mailClass canSendMail])
	{
	// the custom icon button was clicked, handle it here
	MFMailComposeViewController *controller = [[MFMailComposeViewController alloc] init];
	controller.mailComposeDelegate = self;
	[controller setSubject:@&quot;In app email...&quot;];
	[controller setMessageBody:@&quot;...a tutorial from mobileorchard.com&quot; isHTML:NO];
	[self presentModalViewController:controller animated:YES];
	[controller release]; 
	}  
	
	/*
	// Attach an image to the email
	NSString *path = [[NSBundle mainBundle] pathForResource:@&quot;Images&quot; ofType:@&quot;plist&quot;];
    NSData *myData = [NSData dataWithContentsOfFile:path];
	[controller addAttachmentData:myData mimeType:@&quot;image/png&quot; fileName:@&quot;rainy&quot;];
	 */
	
}
- (void)mailComposeController:(MFMailComposeViewController*)controller didFinishWithResult:(MFMailComposeResult)result error:(NSError*)error 
{	
	[self becomeFirstResponder];
	[self dismissModalViewControllerAnimated:YES];
}
&lt;/code&gt;</description>
		<content:encoded><![CDATA[<p>I follow your steps but the button send do nothing in 2.2.1 is like doesn&#8217;t have the method to show the ComposerEmail. but in 3.0 works fine.</p>
<p>any help</p>
<p>thanks</p>
<p><code><br />
- (void)email<br />
{<br />
	//Can send email<br />
	//if ([MFMailComposeViewController canSendMail])<br />
	Class mailClass = (NSClassFromString(@"MFMailComposeViewController"));<br />
	if (mailClass != nil &amp;&amp; [mailClass canSendMail])<br />
	{<br />
	// the custom icon button was clicked, handle it here<br />
	MFMailComposeViewController *controller = [[MFMailComposeViewController alloc] init];<br />
	controller.mailComposeDelegate = self;<br />
	[controller setSubject:@"In app email..."];<br />
	[controller setMessageBody:@"...a tutorial from mobileorchard.com" isHTML:NO];<br />
	[self presentModalViewController:controller animated:YES];<br />
	[controller release];<br />
	}  </p>
<p>	/*<br />
	// Attach an image to the email<br />
	NSString *path = [[NSBundle mainBundle] pathForResource:@"Images" ofType:@"plist"];<br />
    NSData *myData = [NSData dataWithContentsOfFile:path];<br />
	[controller addAttachmentData:myData mimeType:@"image/png" fileName:@"rainy"];<br />
	 */</p>
<p>}<br />
- (void)mailComposeController:(MFMailComposeViewController*)controller didFinishWithResult:(MFMailComposeResult)result error:(NSError*)error<br />
{<br />
	[self becomeFirstResponder];<br />
	[self dismissModalViewControllerAnimated:YES];<br />
}<br />
</code></p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Eknath</title>
		<link>http://gamesfromwithin.com/targeting-2-x-with-3-0-features-trouble-ahead/comment-page-1#comment-2554</link>
		<dc:creator>Eknath</dc:creator>
		<pubDate>Mon, 03 Aug 2009 18:31:59 +0000</pubDate>
		<guid isPermaLink="false">http://gamesfromwithin.com/?p=549#comment-2554</guid>
		<description>Guess what, I forgot to put the weak link flag for 3.0 frameworks. And shipped the app. My 2.1 users started shouting as the app would crash just after launching. It was a disastrous situation.</description>
		<content:encoded><![CDATA[<p>Guess what, I forgot to put the weak link flag for 3.0 frameworks. And shipped the app. My 2.1 users started shouting as the app would crash just after launching. It was a disastrous situation.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: links for 2009-08-01 &#171; Blarney Fellow</title>
		<link>http://gamesfromwithin.com/targeting-2-x-with-3-0-features-trouble-ahead/comment-page-1#comment-2514</link>
		<dc:creator>links for 2009-08-01 &#171; Blarney Fellow</dc:creator>
		<pubDate>Sun, 02 Aug 2009 01:06:39 +0000</pubDate>
		<guid isPermaLink="false">http://gamesfromwithin.com/?p=549#comment-2514</guid>
		<description>[...] Games from Within &#124; Targeting 2.x With 3.0 Features. Trouble Ahead. (tags: iphone viapssteam) [...]</description>
		<content:encoded><![CDATA[<p>[...] Games from Within | Targeting 2.x With 3.0 Features. Trouble Ahead. (tags: iphone viapssteam) [...]</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Noel</title>
		<link>http://gamesfromwithin.com/targeting-2-x-with-3-0-features-trouble-ahead/comment-page-1#comment-2510</link>
		<dc:creator>Noel</dc:creator>
		<pubDate>Sat, 01 Aug 2009 07:43:37 +0000</pubDate>
		<guid isPermaLink="false">http://gamesfromwithin.com/?p=549#comment-2510</guid>
		<description>I did try attaching the debugger, but the app didn&#039;t show up in the list, like you mentioned. I&#039;ll try finding the PID and attaching directly and see if that works. Thanks.</description>
		<content:encoded><![CDATA[<p>I did try attaching the debugger, but the app didn&#8217;t show up in the list, like you mentioned. I&#8217;ll try finding the PID and attaching directly and see if that works. Thanks.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Frank Szczerba</title>
		<link>http://gamesfromwithin.com/targeting-2-x-with-3-0-features-trouble-ahead/comment-page-1#comment-2503</link>
		<dc:creator>Frank Szczerba</dc:creator>
		<pubDate>Fri, 31 Jul 2009 21:28:45 +0000</pubDate>
		<guid isPermaLink="false">http://gamesfromwithin.com/?p=549#comment-2503</guid>
		<description>Have you tried launching the app in the 2.2 simulator then connecting to the running instance with the debugger? Just go to Run -&gt; Attach to Process in XCode. If your app doesn&#039;t show in the list, find the PID with ps or Activity Monitor and pick the Process ID... option. XCode will attach (and pause) the process, allowing you to set any breakpoints you need and then continue.</description>
		<content:encoded><![CDATA[<p>Have you tried launching the app in the 2.2 simulator then connecting to the running instance with the debugger? Just go to Run -&gt; Attach to Process in XCode. If your app doesn&#8217;t show in the list, find the PID with ps or Activity Monitor and pick the Process ID&#8230; option. XCode will attach (and pause) the process, allowing you to set any breakpoints you need and then continue.</p>
]]></content:encoded>
	</item>
</channel>
</rss>

