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

Side by Side Diff: extensions/browser/guest_view/web_view/web_view_guest.h

Issue 1909773002: Convert //extensions/browser from scoped_ptr to std::unique_ptr (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: . Created 4 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 #ifndef EXTENSIONS_BROWSER_GUEST_VIEW_WEB_VIEW_WEB_VIEW_GUEST_H_ 5 #ifndef EXTENSIONS_BROWSER_GUEST_VIEW_WEB_VIEW_WEB_VIEW_GUEST_H_
6 #define EXTENSIONS_BROWSER_GUEST_VIEW_WEB_VIEW_WEB_VIEW_GUEST_H_ 6 #define EXTENSIONS_BROWSER_GUEST_VIEW_WEB_VIEW_WEB_VIEW_GUEST_H_
7 7
8 #include <stdint.h> 8 #include <stdint.h>
9 9
10 #include <vector> 10 #include <vector>
(...skipping 310 matching lines...) Expand 10 before | Expand all | Expand 10 after
321 321
322 void ApplyAttributes(const base::DictionaryValue& params); 322 void ApplyAttributes(const base::DictionaryValue& params);
323 323
324 // Identifies the set of rules registries belonging to this guest. 324 // Identifies the set of rules registries belonging to this guest.
325 int rules_registry_id_; 325 int rules_registry_id_;
326 326
327 // Handles find requests and replies for the webview find API. 327 // Handles find requests and replies for the webview find API.
328 WebViewFindHelper find_helper_; 328 WebViewFindHelper find_helper_;
329 329
330 base::ObserverList<ScriptExecutionObserver> script_observers_; 330 base::ObserverList<ScriptExecutionObserver> script_observers_;
331 scoped_ptr<ScriptExecutor> script_executor_; 331 std::unique_ptr<ScriptExecutor> script_executor_;
332 332
333 content::NotificationRegistrar notification_registrar_; 333 content::NotificationRegistrar notification_registrar_;
334 334
335 // True if the user agent is overridden. 335 // True if the user agent is overridden.
336 bool is_overriding_user_agent_; 336 bool is_overriding_user_agent_;
337 337
338 // Stores the window name of the main frame of the guest. 338 // Stores the window name of the main frame of the guest.
339 std::string name_; 339 std::string name_;
340 340
341 // Stores whether the contents of the guest can be transparent. 341 // Stores whether the contents of the guest can be transparent.
342 bool allow_transparency_; 342 bool allow_transparency_;
343 343
344 // Stores the src URL of the WebView. 344 // Stores the src URL of the WebView.
345 GURL src_; 345 GURL src_;
346 346
347 // Handles the JavaScript dialog requests. 347 // Handles the JavaScript dialog requests.
348 JavaScriptDialogHelper javascript_dialog_helper_; 348 JavaScriptDialogHelper javascript_dialog_helper_;
349 349
350 // Handles permission requests. 350 // Handles permission requests.
351 scoped_ptr<WebViewPermissionHelper> web_view_permission_helper_; 351 std::unique_ptr<WebViewPermissionHelper> web_view_permission_helper_;
352 352
353 scoped_ptr<WebViewGuestDelegate> web_view_guest_delegate_; 353 std::unique_ptr<WebViewGuestDelegate> web_view_guest_delegate_;
354 354
355 // Tracks the name, and target URL of the new window. Once the first 355 // Tracks the name, and target URL of the new window. Once the first
356 // navigation commits, we no longer track this information. 356 // navigation commits, we no longer track this information.
357 struct NewWindowInfo { 357 struct NewWindowInfo {
358 GURL url; 358 GURL url;
359 std::string name; 359 std::string name;
360 bool changed; 360 bool changed;
361 NewWindowInfo(const GURL& url, const std::string& name) : 361 NewWindowInfo(const GURL& url, const std::string& name) :
362 url(url), 362 url(url),
363 name(name), 363 name(name),
(...skipping 16 matching lines...) Expand all
380 // This is used to ensure pending tasks will not fire after this object is 380 // This is used to ensure pending tasks will not fire after this object is
381 // destroyed. 381 // destroyed.
382 base::WeakPtrFactory<WebViewGuest> weak_ptr_factory_; 382 base::WeakPtrFactory<WebViewGuest> weak_ptr_factory_;
383 383
384 DISALLOW_COPY_AND_ASSIGN(WebViewGuest); 384 DISALLOW_COPY_AND_ASSIGN(WebViewGuest);
385 }; 385 };
386 386
387 } // namespace extensions 387 } // namespace extensions
388 388
389 #endif // EXTENSIONS_BROWSER_GUEST_VIEW_WEB_VIEW_WEB_VIEW_GUEST_H_ 389 #endif // EXTENSIONS_BROWSER_GUEST_VIEW_WEB_VIEW_WEB_VIEW_GUEST_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698