OLD | NEW |
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/tab_applescript.h" | 5 #import "chrome/browser/ui/cocoa/applescript/tab_applescript.h" |
6 | 6 |
7 #include "base/bind.h" | 7 #include "base/bind.h" |
8 #include "base/files/file_path.h" | 8 #include "base/files/file_path.h" |
9 #include "base/logging.h" | 9 #include "base/logging.h" |
10 #import "base/mac/scoped_nsobject.h" | 10 #import "base/mac/scoped_nsobject.h" |
(...skipping 125 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
136 return; | 136 return; |
137 } | 137 } |
138 | 138 |
139 NavigationEntry* entry = webContents_->GetController().GetActiveEntry(); | 139 NavigationEntry* entry = webContents_->GetController().GetActiveEntry(); |
140 if (!entry) | 140 if (!entry) |
141 return; | 141 return; |
142 | 142 |
143 const GURL& previousURL = entry->GetVirtualURL(); | 143 const GURL& previousURL = entry->GetVirtualURL(); |
144 webContents_->OpenURL(OpenURLParams( | 144 webContents_->OpenURL(OpenURLParams( |
145 url, | 145 url, |
146 content::Referrer(previousURL, WebKit::WebReferrerPolicyDefault), | 146 content::Referrer(previousURL, blink::WebReferrerPolicyDefault), |
147 CURRENT_TAB, | 147 CURRENT_TAB, |
148 content::PAGE_TRANSITION_TYPED, | 148 content::PAGE_TRANSITION_TYPED, |
149 false)); | 149 false)); |
150 } | 150 } |
151 | 151 |
152 - (NSString*)title { | 152 - (NSString*)title { |
153 NavigationEntry* entry = webContents_->GetController().GetActiveEntry(); | 153 NavigationEntry* entry = webContents_->GetController().GetActiveEntry(); |
154 if (!entry) | 154 if (!entry) |
155 return nil; | 155 return nil; |
156 | 156 |
(...skipping 173 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
330 string16 script = base::SysNSStringToUTF16( | 330 string16 script = base::SysNSStringToUTF16( |
331 [[command evaluatedArguments] objectForKey:@"javascript"]); | 331 [[command evaluatedArguments] objectForKey:@"javascript"]); |
332 view->ExecuteJavascriptInWebFrameCallbackResult(string16(), // frame_xpath | 332 view->ExecuteJavascriptInWebFrameCallbackResult(string16(), // frame_xpath |
333 script, | 333 script, |
334 callback); | 334 callback); |
335 | 335 |
336 return nil; | 336 return nil; |
337 } | 337 } |
338 | 338 |
339 @end | 339 @end |
OLD | NEW |