Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 4 additions & 1 deletion GoogleTransit/AppDelegate.h
100644 → 100755
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,10 @@

#import <UIKit/UIKit.h>

@interface AppDelegate : UIResponder <UIApplicationDelegate>
@interface AppDelegate : UIResponder <UIApplicationDelegate, UIWebViewDelegate>
{
UIWebView *webView;
}

@property (strong, nonatomic) UIWindow *window;

Expand Down
17 changes: 15 additions & 2 deletions GoogleTransit/AppDelegate.m
100644 → 100755
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,16 @@ - (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(
self.window = [[UIWindow alloc] initWithFrame:[[UIScreen mainScreen] bounds]];
self.window.backgroundColor = [UIColor blackColor];
[self.window makeKeyAndVisible];



UIView *view = [[UIView alloc] initWithFrame:self.window.frame];
[self.window addSubview:view];
NSLog(@"w:%f h:%f",self.window.frame.size.width,self.window.frame.size.height);

webView = [[UIWebView alloc] initWithFrame:self.window.frame];
[webView setDelegate:self];
[view addSubview:webView];

self.locationManager = [[CLLocationManager alloc] init];
self.locationManager.delegate = self;

Expand Down Expand Up @@ -87,7 +96,11 @@ - (void) openTransitDirections
self.currentSource = nil;
self.currentDestination = nil;

[self openURL:directionsURL];
NSLog(@"open url %@",directionsURL);
// [self openURL:directionsURL];


[webView loadRequest:[[NSURLRequest alloc] initWithURL:directionsURL]];
}
}

Expand Down
Empty file modified GoogleTransit/Default-568h@2x.png
100644 → 100755
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Empty file modified GoogleTransit/Default.png
100644 → 100755
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Empty file modified GoogleTransit/Default@2x.png
100644 → 100755
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Empty file modified GoogleTransit/Directions.geojson
100644 → 100755
Empty file.
2 changes: 2 additions & 0 deletions GoogleTransit/GoogleTransit-Info.plist
100644 → 100755
Original file line number Diff line number Diff line change
Expand Up @@ -56,6 +56,8 @@
<array>
<string>armv7</string>
</array>
<key>UIStatusBarHidden</key>
<true/>
<key>UISupportedInterfaceOrientations</key>
<array>
<string>UIInterfaceOrientationPortrait</string>
Expand Down
Empty file modified GoogleTransit/GoogleTransit-Prefix.pch
100644 → 100755
Empty file.
Empty file modified GoogleTransit/en.lproj/InfoPlist.strings
100644 → 100755
Empty file.
Empty file modified GoogleTransit/main.m
100644 → 100755
Empty file.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ Miss transit directions in iOS 6? Want to go back to Google?

This should help. It's a simple app that registers as a routing provider worldwide.

When you choose it as your routing app, Google Maps will open in Safari with the appropriate
When you choose it as your routing app, Google Maps will provide directions within an embedded web view.
directions.

![Screenshot 0](https://github.com/simonmaddox/GoogleTransit-iOS6/blob/master/screenshot0.png?raw=true)
Expand Down