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

Side by Side Diff: chrome/browser/ui/cocoa/html_dialog_window_controller.mm

Issue 8785004: Change NavigationController::LoadURL to take a Referrer class instead of a GURL as referrer (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: updates Created 9 years 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 | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 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/html_dialog_window_controller.h" 5 #import "chrome/browser/ui/cocoa/html_dialog_window_controller.h"
6 6
7 #include "base/logging.h" 7 #include "base/logging.h"
8 #include "base/memory/scoped_nsobject.h" 8 #include "base/memory/scoped_nsobject.h"
9 #include "base/sys_string_conversions.h" 9 #include "base/sys_string_conversions.h"
10 #include "chrome/browser/profiles/profile.h" 10 #include "chrome/browser/profiles/profile.h"
(...skipping 279 matching lines...) Expand 10 before | Expand all | Expand 10 after
290 delegate_->profile(), NULL, MSG_ROUTING_NONE, NULL, NULL)); 290 delegate_->profile(), NULL, MSG_ROUTING_NONE, NULL, NULL));
291 [[self window] setContentView:tabContents_->GetNativeView()]; 291 [[self window] setContentView:tabContents_->GetNativeView()];
292 tabContents_->set_delegate(delegate_.get()); 292 tabContents_->set_delegate(delegate_.get());
293 293
294 // This must be done before loading the page; see the comments in 294 // This must be done before loading the page; see the comments in
295 // HtmlDialogUI. 295 // HtmlDialogUI.
296 HtmlDialogUI::GetPropertyAccessor().SetProperty(tabContents_->property_bag(), 296 HtmlDialogUI::GetPropertyAccessor().SetProperty(tabContents_->property_bag(),
297 delegate_.get()); 297 delegate_.get());
298 298
299 tabContents_->controller().LoadURL(delegate_->GetDialogContentURL(), 299 tabContents_->controller().LoadURL(delegate_->GetDialogContentURL(),
300 GURL(), 300 content::Referrer(),
301 content::PAGE_TRANSITION_START_PAGE, 301 content::PAGE_TRANSITION_START_PAGE,
302 std::string()); 302 std::string());
303 303
304 // TODO(akalin): add accelerator for ESC to close the dialog box. 304 // TODO(akalin): add accelerator for ESC to close the dialog box.
305 // 305 //
306 // TODO(akalin): Figure out why implementing (void)cancel:(id)sender 306 // TODO(akalin): Figure out why implementing (void)cancel:(id)sender
307 // to do the above doesn't work. 307 // to do the above doesn't work.
308 } 308 }
309 309
310 - (void)windowWillClose:(NSNotification*)notification { 310 - (void)windowWillClose:(NSNotification*)notification {
311 delegate_->WindowControllerClosed(); 311 delegate_->WindowControllerClosed();
312 [self autorelease]; 312 [self autorelease];
313 } 313 }
314 314
315 @end 315 @end
OLDNEW
« no previous file with comments | « chrome/browser/ui/cocoa/constrained_html_delegate_mac.mm ('k') | chrome/browser/ui/cocoa/notifications/balloon_controller.mm » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698