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

Side by Side Diff: chrome/browser/ui/cocoa/applescript/window_applescript.mm

Issue 1336823003: Move chrome::HostDesktopType to ui::HostDesktopType (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@base_session_service_delegate_impl
Patch Set: Fix build on Mac and CrOS Created 5 years, 3 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 (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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 "chrome/browser/ui/cocoa/applescript/window_applescript.h" 5 #import "chrome/browser/ui/cocoa/applescript/window_applescript.h"
6 6
7 #include "base/logging.h" 7 #include "base/logging.h"
8 #import "base/mac/scoped_nsobject.h" 8 #import "base/mac/scoped_nsobject.h"
9 #include "base/memory/scoped_ptr.h" 9 #include "base/memory/scoped_ptr.h"
10 #include "base/time/time.h" 10 #include "base/time/time.h"
(...skipping 55 matching lines...) Expand 10 before | Expand all | Expand 10 after
66 } 66 }
67 67
68 - (id)initWithProfile:(Profile*)aProfile { 68 - (id)initWithProfile:(Profile*)aProfile {
69 if (!aProfile) { 69 if (!aProfile) {
70 [self release]; 70 [self release];
71 return nil; 71 return nil;
72 } 72 }
73 73
74 if ((self = [super init])) { 74 if ((self = [super init])) {
75 browser_ = new Browser( 75 browser_ = new Browser(
76 Browser::CreateParams(aProfile, chrome::HOST_DESKTOP_TYPE_NATIVE)); 76 Browser::CreateParams(aProfile, ui::HOST_DESKTOP_TYPE_NATIVE));
77 chrome::NewTab(browser_); 77 chrome::NewTab(browser_);
78 browser_->window()->Show(); 78 browser_->window()->Show();
79 base::scoped_nsobject<NSNumber> numID( 79 base::scoped_nsobject<NSNumber> numID(
80 [[NSNumber alloc] initWithInt:browser_->session_id().id()]); 80 [[NSNumber alloc] initWithInt:browser_->session_id().id()]);
81 [self setUniqueID:numID]; 81 [self setUniqueID:numID];
82 } 82 }
83 return self; 83 return self;
84 } 84 }
85 85
86 - (id)initWithBrowser:(Browser*)aBrowser { 86 - (id)initWithBrowser:(Browser*)aBrowser {
(...skipping 186 matching lines...) Expand 10 before | Expand all | Expand 10 after
273 } 273 }
274 274
275 - (void)handlesExitPresentationMode:(NSScriptCommand*)command { 275 - (void)handlesExitPresentationMode:(NSScriptCommand*)command {
276 AppleScript::LogAppleScriptUMA( 276 AppleScript::LogAppleScriptUMA(
277 AppleScript::AppleScriptCommand::WINDOW_EXIT_PRESENTATION_MODE); 277 AppleScript::AppleScriptCommand::WINDOW_EXIT_PRESENTATION_MODE);
278 if (browser_->window()) 278 if (browser_->window())
279 browser_->window()->ExitFullscreen(); 279 browser_->window()->ExitFullscreen();
280 } 280 }
281 281
282 @end 282 @end
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698