Join us for the TUAW Talkcast tonight at 10 PM EDT

It’s been a relatively quiet weekend in the Apple world, with not much to talk about other than the opening of a huge flagship Apple Store in London and the departure of an Apple VP from the executive suites. These newsy items should serve as fodder for an evening of fun chat on the TUAW Talkcast. We start at 10 PM EDT / 7 PM PDT / 4 PM DRT (DocRockTime).

To participate on TalkShoe, you can use the browser-only client, the embedded Facebook app, or the classic TalkShoe Pro Java client; however, for maximum fun, you should call in. For the web UI, just click the “TalkShoe Web” button on our profile page at 10 pm Sunday. To call in on regular phone or VoIP lines (take advantage of your free cellphone weekend minutes if you like): dial (724) 444-7444 and enter our talkcast ID, 45077 — during the call, you can request to talk by keying in *8.

If you’ve got a headset or microphone handy on your Mac, you can connect via the free X-Lite SIP client; basic instructions are here. Of course, the full TalkShoe client includes its own ‘Shoephone’ VoIP tool as well. For MP3 streaming on iPhone or iPad, you can try this link once the show starts (may or may not work).

TUAWJoin us for the TUAW Talkcast tonight at 10 PM EDT originally appeared on The Unofficial Apple Weblog (TUAW) on Sun, 08 Aug 2010 18:00:00 EST. Please see our terms for use of feeds.

Read | Permalink | Email this | Comments

Verizon iPhone, stop us if you’ve heard this before

Hey remember when AT&T’s awkward CEO (then Cingular CEO) joined Steve Jobs in 2007 at Macworld with his awesome notecards and stilted announcement of exclusivity for the iPhone? Yeah, that and thousands of dropped calls later should have been a big, red warning to you conspiracy theorists that some day the iPhone would free itself from the big blue clutches of AT&T. Of course it’ll happen, it’s always been a matter of when. And every site in the tech universe yet again buzzes with the name Verizon this weekend as various tea leaves have been read to suggest January as a date. Maybe. Pencil it in, among the dozens of other rumored days/years/epochs, so you can start queueing up for something that hasn’t even been announced.

Except, not really. TechCrunch makes a rather uneducated guess as to a January launch — except that it’d be months before the usual summer announcement that hovers over WWDC these past few years. That and Apple doesn’t attend Macworld any more (insert world’s biggest eye roll here). Their guess is based on a big rumored order of CDMA chips — although commenters point out this could be for a Chinese carrier. Engadget has a more nebulous date of “maybe someday” given the Q2 earnings report from AT&T which vaguely states that they’ll still be making money once “these exclusivity arrangements end.” I don’t know how many exclusive phones AT&T has (all are highly death-grippable, I’m sure), but let’s think of at least one runaway hit that could potentially ding their bottom line and dream, shall we?

Personally I’m not betting anything until Verizon rolls out their LTE network quite a bit. iPhone on T-Mobile makes more sense at this point. Why? Currently on Verizon’s 3G network you can’t have a phone conversation and use data at the same time. No way is Apple going to downgrade the functionality of their phone just for the sake of “more” customers. In case you haven’t followed the company for 20 years, here’s the deal: they care more about making customers happy than getting more customers. This “secret sauce” that companies like Microsoft, Sony and Dell can’t fathom will play out in this cellular phone market as well. Once Verizon provides a better experience than AT&T, we’ll certainly see a Verizon iPhone. Unless Verizon insists on the bloaty crapware and big honkin’ V they put on all their phones — that could further delay such a deal.

TUAWVerizon iPhone, stop us if you’ve heard this before originally appeared on The Unofficial Apple Weblog (TUAW) on Sun, 08 Aug 2010 17:00:00 EST. Please see our terms for use of feeds.

Read | Permalink | Email this | Comments

Apple senior iPhone exec leaves. Was it all about the iPhone antenna?

Mark Papermaster has left Apple after a year and a half stint that involved work on the new iPhone 4. Papermaster was Apple’s Senior VP of Devices Hardware Engineering.

The New York Times reports no comment from Papermaster, and quotes Apple as saying that Bob Mansfield, Senior Vice President of Macintosh Hardware Engineering, is taking his place.

There is a good deal of speculation that the change was due to all the controversy over the iPhone antenna design, but no one except senior Apple executives and Papermaster himself know for sure. Some media reports have quoted Apple insiders as saying the iPhone antenna design was done before Papermaster ever came on board.

Also, Apple has never admitted to an antenna problem, and firing Papermaster could put Apple in a weak position defending the antenna design. One can spin just about any theory about the executive change, but until someone says something official it’s just speculation.

[Via the New York Times]

TUAWApple senior iPhone exec leaves. Was it all about the iPhone antenna? originally appeared on The Unofficial Apple Weblog (TUAW) on Sun, 08 Aug 2010 14:30:00 EST. Please see our terms for use of feeds.

Read | Permalink | Email this | Comments

Found Footage: Apple Store Covent Garden opening in iPhone 4 HD

The Apple Store Covent Garden opened in London this weekend to great crowds and fanfare, and of course we’ve been inundated with photos, video, and personal stories about the opening. We’d love to thank all of you for your input, as we all love Apple Store openings as much as anyone!

Mike Hellers took some wonderful footage of the opening in 720p HD video with his iPhone 4. Not just any iPhone 4 — this one was sitting on a customized Hague Mini Motion-Cam for extra steady camera work. Another short video by drcjep showing Mike and the Motion-cam follows on page 2.

TUAWFound Footage: Apple Store Covent Garden opening in iPhone 4 HD originally appeared on The Unofficial Apple Weblog (TUAW) on Sun, 08 Aug 2010 13:30:00 EST. Please see our terms for use of feeds.

Read | Permalink | Email this | Comments

Does the iPhone 4 hate the AT&T MicroCell?

It just might. AT&T support boards are filling up with reports from unhappy customers saying the MicroCell, designed to provide excellent AT&T 3G reception in a house or office, simply isn’t working well with the iPhone 4.

Users are reporting a good deal of audio breakup on incoming calls, although the person on the other send of the conversation can hear things just fine. Walking toward the device usually helps, and some users saying turning off the iPhone’s cellular data clears up the problem. People are even posting videos demonstrating the issue. It doesn’t seem to be a matter of range. People are getting the audio ‘stuttering’ even with 5 bars of signal strength.

I’ve experienced the problem with my MicroCell as well. AT&T thought the hardware was bad, and cheerfully exchanged it. The problem, although intermittent, remained.

TUAWDoes the iPhone 4 hate the AT&T MicroCell? originally appeared on The Unofficial Apple Weblog (TUAW) on Sun, 08 Aug 2010 12:30:00 EST. Please see our terms for use of feeds.

Read | Permalink | Email this | Comments

Why Apple’s patents might show screens from third-party apps

This is a weird one. FutureTap was surprised to recognize one of their app’s screens in a strange place: a recent Apple patent outlining how a possible travel application could work. The company wasn’t quite sure what to do next — as you can see above, it’s a straightforward copy of the Where To? screen. Without any contact from Apple on the issue, FutureTap was puzzled — the company calls Apple its “primary business partner.” Having your app show up in an Apple patent filing

Not that Apple is above cherry-picking UI and functionality from third-party apps — the iBooks interface was more or less borrowed whole from apps like Delicious Library and Classics, and further back there was the homage of Karelia Software’s Watson reinterpreted as Apple’s revision to Sherlock. In those cases, both developers just sort of shrugged, felt flattered, and let it go. That’s not the situation here — these screenshots probably aren’t illustrations of a product Apple wants to make, they’re explanations of how the patent would work.

As Engadget’s Nilay Patel clarifies for us (so nice to have an attorney around), not only is this merely a patent application (which could possibly still be denied), but Apple isn’t trying to lay claim to the actual screenshot; rather the company is using an example application which illustrates the to-be-patented functionality (in the case of Where To?, the ability of an iPhone to auto-detect when a user has been traveling). As Nilay puts it:

the only operative parts of a patent are the claims — not the drawings, and not the description, which are technically known as the “specification.” (We’ve now repeated this basic axiom of patent interpretation so many times we’re considering making T-shirts.) The only reason the drawings and description are there is to explain the claimed invention in sufficient detail so that someone else can make it. Remember, patents are a trade: in order to get protection, you have to give up the full details of how your invention works. (The other option is to keep your invention a trade secret, but then you can’t prevent anyone else from figuring it out and using it if it gets out.) Bottom line? If it’s not in the claims, it’s not in the patent.

We’ll have to see what FutureTap does — the company might request that Apple remove the Where To? screenshot from the patent application, but at this point it’s not clear that Apple wants to lay claim to that particular app. What is clear is that Apple could have avoided a lot of hassle and furor if it had simply sent FutureTap an email asking to use a screenshot in a patent filing. In the meantime, FutureTap execs are huddled with their lawyers, trying to make sure they understand what’s going on.

TUAWWhy Apple’s patents might show screens from third-party apps originally appeared on The Unofficial Apple Weblog (TUAW) on Sat, 07 Aug 2010 11:00:00 EST. Please see our terms for use of feeds.

Read | Permalink | Email this | Comments

Picasa find: Finder icon gets a new job on Canon digicam

That poor Finder icon. The Rodney Dangerfield of Apple products, he gets no respect. Heck, he’s nowhere to be found on the iPhone or the iPad, and he just sits down in the Dock of the Mac, getting little or no work from anybody.

It’s apparent that Mr. Finder has had his fill of Apple and the Mac, as he’s now finding work elsewhere. TUAW reader Aleksander found Mr. Finder hanging out on the back of a new Canon A3000IS digital camera, where he’s apparently used to enable a face detection function. Sure, the FInder icon has tried to cover up his face by putting on a little makeup to get rid of that two-tone blue tan, and it looks like he may have also gotten a little rhinoplasty, but it’s him.

We’re wondering just how widespread Mr. Finder’s disloyalty to Apple really is. If you happen to find him anywhere else, snap a photo of him, send it to Flickr, and tag it with TUAW so the world will know.

TUAWPicasa find: Finder icon gets a new job on Canon digicam originally appeared on The Unofficial Apple Weblog (TUAW) on Sat, 07 Aug 2010 08:00:00 EST. Please see our terms for use of feeds.

Read | Permalink | Email this | Comments

Five freaking awesome FaceTime hacks — and a few handy tips

We’ve all been using FaceTime like crazy here at TUAW central — it’s really great to be able to conference with friends in real time without having to arrange things in advance. Nearly all of us have been video-conferencing-ready for years. But with the iPhone 4, there’s no more “Do you have iChat set up?” (or Skype) or “Can I call you now?” time-wasting prologues.

Instead, we can just call. Knowing that your friends have iPhone 4s makes video calling much easier. You don’t have to call or text to arrange the call, you just place it and you’re immediately good to go. We may have already had webcam equipment on hand but it’s only with the iPhone 4 that, at least here at TUAW, we’re actually using video calling.

With that in mind, we’ve been seeing how far we can push the technology. We’ve put together a list of the coolest techniques that we’ve actually tried out and tested and can confirm as working. In no particular order, here they are.

TUAWFive freaking awesome FaceTime hacks — and a few handy tips originally appeared on The Unofficial Apple Weblog (TUAW) on Fri, 06 Aug 2010 20:00:00 EST. Please see our terms for use of feeds.

Read | Permalink | Email this | Comments

Valve talks gaming on the Mac, says best is yet to come

Valve’s Jason Holtman and Doug Lombardi recently sat down with GamesIndustry.biz to discuss their big release of Steam on the Mac, and not only do they reiterate that great stat that games released on the Mac see a nice bump in sales, but they say that the best days of Mac gaming are yet to come. They can’t share numbers yet on just how many Mac vs. PC players there are (though they say the response has been great, and you can see Mac players in games often), but Holtman and Lombardi both say that from small game developers to big game publishers, Steam on Mac has helped everyone see just how active and important the Mac gaming scene is. There are international users on Macs, and the amount of player interest in games for the platform has made developers rethink their old plans of releasing a Mac port when they get to it rather than day and date with the PC title.

That is, in a word, awesome. And Lombardi says now that publishers are interested in the platform as whole, we’ll see some “different types of experiment on pricing and promotion and all that stuff on Mac titles,” as companies try to figure out how to make the most of this market they’ve been neglecting for so long.

Valve has already said that bringing Steam to the Mac was the most significant decision they’ve made with the service, but I’d argue that even this early in the process (even Valve admits that it doesn’t have a lot of data yet on how people use the two platforms), it was a seismic event for Mac gaming as well.

TUAWValve talks gaming on the Mac, says best is yet to come originally appeared on The Unofficial Apple Weblog (TUAW) on Fri, 06 Aug 2010 19:00:00 EST. Please see our terms for use of feeds.

Read | Permalink | Email this | Comments

iPhone-controlled marble prototype from GearBox

This is wild — a new startup called GearBox is working on making “smart toys,” and one of their first products is a prototype rolling ball that’s controlled with your iPhone (or other smartphone, of course). Not only can you move the ball around on the ground with your phone’s touchscreen, but the ball has gadgetry inside that can affect and monitor its motion, so you can do things like play “Office Golf” (and the ball can notify you when it’s reached the hole), try some virtual curling, or play a multi-ball game. There’s lots of gadgetry inside, too, so the ball could be made to travel slower or in a strange pattern, or even glow with ambient information. It’s also wirelessly connected to the iPhone (and thus to the Internet), so you could have it monitor online resources like Facebook or Twitter, and then react to that data as well.

Unfortunately, this is still just a prototype — there’s no information about a price or release date at all. But it’s obviously a really intriguing idea, and depending on actual implementation, it could be a really amazing product. We’ll have to keep an eye out for how GearBox eventually decides to put this together in the future.

[via TouchArcade]

TUAWiPhone-controlled marble prototype from GearBox originally appeared on The Unofficial Apple Weblog (TUAW) on Fri, 06 Aug 2010 18:00:00 EST. Please see our terms for use of feeds.

Read | Permalink | Email this | Comments

A Delta Airlines app is on the way

delta iphone iconRather recently, American Airlines released an iPhone app that offers quite a few nice features for the AA traveler, including flight status, boarding pass access and … Soduku. With the exception of that last feature, travel app Kayak offers many of these features already, though it’s not stopping other airlines from following suit.

Just the other day, a Delta executive mentioned in a short interview that a Delta iPhone app is on the horizon. It’s not clear yet what kinds of services and features the app will provide, though it’s a safe bet the American Airlines app will give you a decent guess.

What kinds of services and features would you want to see in an airline-dedicated iPhone app that’s not already present in current offerings?

TUAWA Delta Airlines app is on the way originally appeared on The Unofficial Apple Weblog (TUAW) on Fri, 06 Aug 2010 17:00:00 EST. Please see our terms for use of feeds.

Read | Permalink | Email this | Comments

TUAW Review: Filemaker Go for iPad

Filemaker has brought its flagship product to a whole new level of portability with Filemaker Go for iPad (US$39.99) and iPhone/iPod touch ($19.99). Years ago I used Filemaker Mobile with a Palm, and this is a far cry from those early days. Here’s what I found while testing Filemaker Go on the iPad.

Design

When FileMaker Go is first launched, you’re presented with two columns: stored files on the left and remote files and hosts on the right. Configuring a remote host is easy and will be immediately familiar to anyone who’s done it before with the desktop version of FileMaker Pro. In the upper right-hand corner you’ll find two familiar icons: add a host and search for a host.

If you choose to add a host, a slip will flip into view (nice bit of eye candy there) and ask for its IP address or domain name. Optionally, you can enter the host’s name, which is helpful if you have multiple servers to keep track of (“Corporate Office” and “School Building,” for example). Note that FileMaker Go connects to databases hosted by FileMaker Server/Server Advanced 11 and 10 and FileMaker Pro/Pro Advanced 11 and 10.

TUAWTUAW Review: Filemaker Go for iPad originally appeared on The Unofficial Apple Weblog (TUAW) on Fri, 06 Aug 2010 16:00:00 EST. Please see our terms for use of feeds.

Read | Permalink | Email this | Comments

Guy moving to New York wants a roomie who doesn’t have an iPhone

An ad posted to Craigslist yesterday is from an open-minded sort of guy who wants a roommate for an apartment in Soho. Sounds typical, right? Here’s the catch: He insists that prospective roommates not have an iPhone or an iPad.

The ad states that “I refuse to live with anyone that has sold their immortal soul to Steve Jobs.” He’s also looking for a guy with Starcraft II experience, and wants any potential live-ins to post a link to their battle.net profile and to prove to him that they don’t own an iPhone.

The New York Observer found the guy, Vince Thomas, and he said he currently lives with another fellow who is a Mac fan, and Vince says he “just can’t take it anymore.” Vince has a Droid phone from Motorola, and apparently he’d rather talk about that instead.

Vince has a point. Some of us love our iPhones. In social situations I don’t bring it up unless someone asks. I’m even feeling a bit guilty about the ‘Sent from my iPhone’ tag on my mail. If I write Vince I’ll be sure to change it to ‘Sent from my wonderful Droid, which is so much better than the iPhone I ditched.’

On the other hand, I’ve been around a few Droid owners, and let me tell you, that’s no picnic either. Good luck Vince. May you find a roommate just like you.

[Via The New York Observer]

TUAWGuy moving to New York wants a roomie who doesn’t have an iPhone originally appeared on The Unofficial Apple Weblog (TUAW) on Fri, 06 Aug 2010 15:00:00 EST. Please see our terms for use of feeds.

Read | Permalink | Email this | Comments

iPad app store gains genius section

ipad genius app storeSometime early this morning, Apple quietly unleashed the genius section of the iPad app store, something that’s been in the iPhone app store for quite some time. It’s interesting how Apple is always “quietly” releasing new things, while making a big to-do about others. What’s also interesting is how a new feature in the app store can be made without a software update.

Not only does the new genius section of the iPad app store provide the same type of recommendations as with the iPhone, there’s a new tab titled “iPad Upgrades,” which shows you all of the iPad (aka, “HD”) versions of the iPhone apps you already have. This is a great new feature for both consumers and app developers because, previously, there was no easy way to know.

Thanks for everyone who sent this in!

TUAWiPad app store gains genius section originally appeared on The Unofficial Apple Weblog (TUAW) on Fri, 06 Aug 2010 14:00:00 EST. Please see our terms for use of feeds.

Read | Permalink | Email this | Comments

Drill down table view with a detail view

Since I published my drill down table view tutorial, I got a lot of positive feedback but with one common request. How do I load a different detail view for an item or how do I load a UITabBarController in the detail view. In this tutorial I will show how to load a different detail view.

Introduction
Using a drill down table view we can display hierarchical data where the last view is responsible of displaying some detail information. This view in which the detail information is displayed can be the same for all the data in the table view (like my last tutorial) or it can be different based on the path that the user took. In this tutorial I will show you how to add a different detail view based on the path the user took to get to the last item. This tutorial is based on the UITableView – Drill down table view tutorial and borrows its source code.

This is how one of the detail view looks like
Loading a detail view
Let’s take a step back and think about the browser and the HTML it renders. The browser doesn’t know what it is going to display and it does not even know the style it should set for the HTML. All that information is present in the HTML and the browser simply renders everything on the screen.

Does this mean that to display different data, I need different views even though the view looks the same? No, if the view looks the same you can reuse the same view again to display different data.

Let us think about the navigation controller as the browser and the data in the plist file as the HTML. If we want to tell the browser to style certain elements of the page, we would put that information in the HTML. In a similar fashion, we can put the detail view information in the plist file which the navigation controller will display. You only need to set this information in the last node of the plist file. When it is time to display the detail view, the code can look at this field and show the right detail view to the user.

Let us change the plist file from the last tutorial to include some information about the detail view.

Changing the plist file
Here we will add a new item to the last child; the title that gets displayed before the detail view is shown. The item will have a title of “View”, type will be number and the value will be 1, 2, or 3. Where 1 = display a UITabBarController in the detail view, 2 = display a detail view with an image in it, and 3 = display a simple detail view.

Your plist file should look like this for the four items

Recap
We have added an extra item at the end of called “View” whose type is integer and value is either 1, 2, or 3. Where 1 = load a detail view UITabBarController, 2 = load a detail view with an image and 3 = load a simple detail view. Let’s see how to add a detail view with a UITabBarController

Adding a UITabBarController to the detail view
Let’s add a UITabBarController to the detail view. We will need an outlet of type UITabBarController, so lets create that in the header file of RootViewController. The code changes like this

//RootViewController.h
@interface RootViewController : UITableViewController {

NSArray *tableDataSource;
NSString *CurrentTitle;
NSInteger CurrentLevel;
IBOutlet UITabBarController *tbController;
}

@property (nonatomic, retain) NSArray *tableDataSource;
@property (nonatomic, retain) NSString *CurrentTitle;
@property (nonatomic, readwrite) NSInteger CurrentLevel;

@end

The dealloc method changes like this

//RootViewController.m
- (void)dealloc {
[tbController release];
[CurrentTitle release];
[tableDataSource release];
[super dealloc];
}

Launch Interface Builder by double clicking “RootViewController.xib” file and drag and drop a UITabBarController in the nib file. Select File’s Owner and select the outlet “tbController” and drag it over to the UITabBarController and release. Now we have connected the outlet tbController to the UITabBarController. Add two views in the UITabBarController and change the title of the UITabBarItems to say “View One” and “View Two”. Also add a label to both the views which would say “View One” for the first and “View Two” for the second. This is all you have to do in the Interface Builder.

Display the detail view
We now have to display the UITabBarController as a detail view when an item is selected in the UITableView. Before we do that let’s stop for a while and see what we did. We added a UITabBarController in the same nib file as the RootViewController instead of creating a different nib file. When displaying a detail view, normally we would initialize the view controller and push it on top of the navigation controller. If we try to do the same here we would see the same table view again, which we do not want. The trick here is to switch the view of the RootViewController from the table view to the view of the tbController. Let’s see how to do this; the code for tableView:didSelectRowAtIndexPath changes like this

//RootViewController.m
- (void)tableView:(UITableView *)tableView didSelectRowAtIndexPath:(NSIndexPath *)indexPath {

//Get the dictionary of the selected data source.
NSDictionary *dictionary = [self.tableDataSource objectAtIndex:indexPath.row];

//Get the children of the present item.
NSArray *Children = [dictionary objectForKey:@"Children"];

if([Children count] == 0) {
NSInteger ViewNumber = [[dictionary objectForKey:@"View"] integerValue];
switch (ViewNumber) {
case 1: {
RootViewController *rvc = [[RootViewController alloc] initWithNibName:@"RootViewController" bundle:[NSBundle mainBundle]];
//Switch the view here
rvc.view = tbController.view;
[self.navigationController pushViewController:rvc animated:YES];
[rvc release];
}
break;
case 2:
break;
case 3: {
DetailViewController *dvController = [[DetailViewController alloc] initWithNibName:@"DetailView" bundle:[NSBundle mainBundle]];
[self.navigationController pushViewController:dvController animated:YES];
[dvController release];
}
break;
default: {
DetailViewController *dvController = [[DetailViewController alloc] initWithNibName:@"DetailView" bundle:[NSBundle mainBundle]];
[self.navigationController pushViewController:dvController animated:YES];
[dvController release];
}
break;
}
}
else {

//Prepare to tableview.
RootViewController *rvController = [[RootViewController alloc] initWithNibName:@"RootViewController" bundle:[NSBundle mainBundle]];

//Increment the Current View
rvController.CurrentLevel += 1;

//Set the title;
rvController.CurrentTitle = [dictionary objectForKey:@"Title"];

//Push the new table view on the stack
[self.navigationController pushViewController:rvController animated:YES];

rvController.tableDataSource = Children;

[rvController release];
}
}

That is the complete code listing for tableView:didSelectRowAtIndexPath method but it does a lot of things and we only need to concentrate on some of the code, so teh condensed version is listed below

//RootViewController.m - tableView:didSelectRowAtIndexPath
if([Children count] == 0) {
NSInteger ViewNumber = [[dictionary objectForKey:@"View"] integerValue];
switch (ViewNumber) {
case 1: {
RootViewController *rvc = [[RootViewController alloc] initWithNibName:@"RootViewController" bundle:[NSBundle mainBundle]];
//Switch the view here
rvc.view = tbController.view;
[self.navigationController pushViewController:rvc animated:YES];
[rvc release];
}
break;
case 2:
break;
case 3: {
DetailViewController *dvController = [[DetailViewController alloc] initWithNibName:@"DetailView" bundle:[NSBundle mainBundle]];
[self.navigationController pushViewController:dvController animated:YES];
[dvController release];
}
break;
default: {
DetailViewController *dvController = [[DetailViewController alloc] initWithNibName:@"DetailView" bundle:[NSBundle mainBundle]];
[self.navigationController pushViewController:dvController animated:YES];
[dvController release];
}
break;
}
}

The above code first checks if the present item has any children or not, if it doesn’t then we look for the value of the item “View”. If it is 1, we know that we have to display a detail view with a UITabBarController. As mentioned before we need to switch the view property of the controller to the view of the tab bar controller, which we do after initializing the controller. At last we ask the navigation controller to display our view which is connected to the controller.

Test it out to see how it works.

We also mentioned that if the “View” has a value of 3 then we would display the simple detail view. So drill down Item 3/4 and see the result. Don’t do that with Item 2 yet because it will not work.

Adding a detail view which will display an image.

Hopefully by now you have a clear idea of how to display different detail views when working with a drill down app.

To display a view with an image create a new view and a new view controller and name the view “ImageView” and the view controller “ImageViewController”. Open the ImageView in IB and set the class to be “ImageViewController” and connect the view outlet from the File’s Owner to the view. Drag and drop a UIImageView from the library on the view. We will set the image of this UIImageView when the view loads and the name of the image will be passed from the root view controller. Since we need to display an image in the image view from Xcode we need an outlet of type UIImageView in the Interface Builder. The header file of “ImageViewController” changes like this

//ImageViewController.m
@interface ImageViewController : UIViewController {

IBOutlet UIImageView *imgView;
NSString *ImageName;
}

@property (nonatomic, retain) NSString *ImageName;

@end

We have also declared a property called “ImageName” which the root view controller will use to pass the name of the image to the image view controller and the image view controller will display the image in the image view.

This is how the viewDidLoad method changes

//ImageViewController.m
- (void)viewDidLoad {
[super viewDidLoad];

NSString *Path = [[NSBundle mainBundle] bundlePath];
NSString *ImagePath = [Path stringByAppendingPathComponent:ImageName];
UIImage *tempImg = [[UIImage alloc] initWithContentsOfFile:ImagePath];
[imgView setImage:tempImg];
[tempImg release];
}

The dealloc method looks like this

//ImageViewController.m
- (void)dealloc {
[ImageName release];
[imgView release];
[super dealloc];
}

Displaying the detail view
Let’s go back to the RootViewController.m file and import “ImageViewController.h” file at the top and it should look like this

//RootViewController.m
#import "RootViewController.h"
#import "DrillDownAppAppDelegate.h"
#import "DetailViewController.h"
#import "ImageViewController.h"

@implementation RootViewController
...

In tableView:didSelectRowAtIndexPath we will now display the image detail view when the “ViewNumber” is set to 2. This is how the code looks like

//RootViewController.m - tableView:didSelectRowAtIndexPath method
case 2: {
ImageViewController *ivc = [[ImageViewController alloc] initWithNibName:@"ImageView" bundle:[NSBundle mainBundle]];
ivc.ImageName = @"Image.jpg";
[self.navigationController pushViewController:ivc animated:YES];
[ivc release];
}
break;

In the above code we initialize the “ImageViewController” and set the name of the image that it should display and ask the navigation controller to display it. Do not forget to place an image in the “Resources” folder.

Build and Run to see how it works.

Conclusion
I hope this helps you in some way on how to load a detail view with a UITabBarController. If you have any questions on loading a different detail view please take a look at this tutorial. Comments are most welcome and if you have any questions please send me an email at iphonearticles[@]gmail[dot]com.

Happy Programming,
iPhone SDK Articles


Attachments

Suggested Readings