Chromium Code Reviews| OLD | NEW |
|---|---|
| (Empty) | |
| 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 | |
| 3 // found in the LICENSE file. | |
| 4 | |
| 5 #include "ios/web/web_state/blocked_popup_info.h" | |
| 6 | |
| 7 namespace web { | |
| 8 | |
| 9 BlockedPopupInfo::BlockedPopupInfo(const GURL& url, | |
| 10 const Referrer& referrer, | |
| 11 NSString* window_name, | |
| 12 ProceduralBlock show_popup_handler) | |
| 13 : url_(url), | |
| 14 referrer_(referrer), | |
| 15 window_name_([window_name copy]), | |
| 16 show_popup_handler_([show_popup_handler copy]){ | |
|
Eugene But (OOO till 7-30)
2015/03/09 16:17:43
NIT: space before {
| |
| 17 } | |
| 18 | |
| 19 BlockedPopupInfo::BlockedPopupInfo(const BlockedPopupInfo& blocked_popup_info) | |
| 20 : url_(blocked_popup_info.url_), | |
| 21 referrer_(blocked_popup_info.referrer_), | |
| 22 window_name_([blocked_popup_info.window_name_ copy]), | |
| 23 show_popup_handler_([blocked_popup_info.show_popup_handler_ copy]) { | |
| 24 } | |
| 25 | |
| 26 BlockedPopupInfo::~BlockedPopupInfo() {} | |
| 27 | |
| 28 void BlockedPopupInfo::ShowPopup() const { | |
| 29 show_popup_handler_(); | |
| 30 } | |
| 31 | |
| 32 void BlockedPopupInfo::operator=(const BlockedPopupInfo& blocked_popup_info) { | |
| 33 url_ = blocked_popup_info.url_; | |
| 34 referrer_ = blocked_popup_info.referrer_; | |
| 35 window_name_.reset([blocked_popup_info.window_name_ copy]); | |
| 36 show_popup_handler_ = [blocked_popup_info.show_popup_handler_ copy]; | |
| 37 } | |
| 38 | |
| 39 } // namespace web | |
| OLD | NEW |