Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(82)

Side by Side Diff: ios/web_view/shell/shell_app_delegate.m

Issue 2791403005: Remove CWV class and move setting User Agent to CWVWebViewConfiguration. (Closed)
Patch Set: Remove cwv.h import from Framework header. Created 3 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #import "ios/web_view/shell/shell_app_delegate.h" 5 #import "ios/web_view/shell/shell_app_delegate.h"
6 6
7 #import <ChromeWebView/ChromeWebView.h>
8
9 #import "ios/web_view/shell/shell_view_controller.h" 7 #import "ios/web_view/shell/shell_view_controller.h"
10 8
11 #if !defined(__has_feature) || !__has_feature(objc_arc) 9 #if !defined(__has_feature) || !__has_feature(objc_arc)
12 #error "This file requires ARC support." 10 #error "This file requires ARC support."
13 #endif 11 #endif
14 12
15 @implementation ShellAppDelegate 13 @implementation ShellAppDelegate
16 14
17 @synthesize window = _window; 15 @synthesize window = _window;
18 16
19 - (BOOL)application:(UIApplication*)application 17 - (BOOL)application:(UIApplication*)application
20 didFinishLaunchingWithOptions:(NSDictionary*)launchOptions { 18 didFinishLaunchingWithOptions:(NSDictionary*)launchOptions {
21 self.window = [[UIWindow alloc] initWithFrame:[[UIScreen mainScreen] bounds]]; 19 self.window = [[UIWindow alloc] initWithFrame:[[UIScreen mainScreen] bounds]];
22 self.window.backgroundColor = [UIColor whiteColor]; 20 self.window.backgroundColor = [UIColor whiteColor];
23 21
24 [CWV configureWithUserAgentProductName:@"Dummy/1.0"];
25
26 [self.window makeKeyAndVisible]; 22 [self.window makeKeyAndVisible];
27 23
28 ShellViewController* controller = [[ShellViewController alloc] init]; 24 ShellViewController* controller = [[ShellViewController alloc] init];
29 self.window.rootViewController = controller; 25 self.window.rootViewController = controller;
30 26
31 return YES; 27 return YES;
32 } 28 }
33 29
34 - (void)applicationWillResignActive:(UIApplication*)application { 30 - (void)applicationWillResignActive:(UIApplication*)application {
35 } 31 }
36 32
37 - (void)applicationDidEnterBackground:(UIApplication*)application { 33 - (void)applicationDidEnterBackground:(UIApplication*)application {
38 } 34 }
39 35
40 - (void)applicationWillEnterForeground:(UIApplication*)application { 36 - (void)applicationWillEnterForeground:(UIApplication*)application {
41 } 37 }
42 38
43 - (void)applicationDidBecomeActive:(UIApplication*)application { 39 - (void)applicationDidBecomeActive:(UIApplication*)application {
44 } 40 }
45 41
46 - (void)applicationWillTerminate:(UIApplication*)application { 42 - (void)applicationWillTerminate:(UIApplication*)application {
47 } 43 }
48 44
49 @end 45 @end
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698