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

Side by Side Diff: chrome/browser/guest_view/guest_view_base.h

Issue 291403002: Remove some RenderProcessHost::IsGuest call sites (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fixed Android build Created 6 years, 7 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 CHROME_BROWSER_GUEST_VIEW_GUEST_VIEW_BASE_H_ 5 #ifndef CHROME_BROWSER_GUEST_VIEW_GUEST_VIEW_BASE_H_
6 #define CHROME_BROWSER_GUEST_VIEW_GUEST_VIEW_BASE_H_ 6 #define CHROME_BROWSER_GUEST_VIEW_GUEST_VIEW_BASE_H_
7 7
8 #include <queue> 8 #include <queue>
9 9
10 #include "base/memory/weak_ptr.h" 10 #include "base/memory/weak_ptr.h"
(...skipping 34 matching lines...) Expand 10 before | Expand all | Expand 10 after
45 45
46 static GuestViewBase* Create(int guest_instance_id, 46 static GuestViewBase* Create(int guest_instance_id,
47 content::WebContents* guest_web_contents, 47 content::WebContents* guest_web_contents,
48 const std::string& embedder_extension_id, 48 const std::string& embedder_extension_id,
49 const std::string& view_type); 49 const std::string& view_type);
50 50
51 static GuestViewBase* FromWebContents(content::WebContents* web_contents); 51 static GuestViewBase* FromWebContents(content::WebContents* web_contents);
52 52
53 static GuestViewBase* From(int embedder_process_id, int instance_id); 53 static GuestViewBase* From(int embedder_process_id, int instance_id);
54 54
55 static bool IsGuest(content::WebContents* web_contents);
56
55 // For GuestViewBases, we create special guest processes, which host the 57 // For GuestViewBases, we create special guest processes, which host the
56 // tag content separately from the main application that embeds the tag. 58 // tag content separately from the main application that embeds the tag.
57 // A GuestViewBase can specify both the partition name and whether the storage 59 // A GuestViewBase can specify both the partition name and whether the storage
58 // for that partition should be persisted. Each tag gets a SiteInstance with 60 // for that partition should be persisted. Each tag gets a SiteInstance with
59 // a specially formatted URL, based on the application it is hosted by and 61 // a specially formatted URL, based on the application it is hosted by and
60 // the partition requested by it. The format for that URL is: 62 // the partition requested by it. The format for that URL is:
61 // chrome-guest://partition_domain/persist?partition_name 63 // chrome-guest://partition_domain/persist?partition_name
62 static bool GetGuestPartitionConfigForSite(const GURL& site, 64 static bool GetGuestPartitionConfigForSite(const GURL& site,
63 std::string* partition_domain, 65 std::string* partition_domain,
64 std::string* partition_name, 66 std::string* partition_name,
(...skipping 106 matching lines...) Expand 10 before | Expand all | Expand 10 after
171 scoped_ptr<base::DictionaryValue> extra_params_; 173 scoped_ptr<base::DictionaryValue> extra_params_;
172 174
173 // This is used to ensure pending tasks will not fire after this object is 175 // This is used to ensure pending tasks will not fire after this object is
174 // destroyed. 176 // destroyed.
175 base::WeakPtrFactory<GuestViewBase> weak_ptr_factory_; 177 base::WeakPtrFactory<GuestViewBase> weak_ptr_factory_;
176 178
177 DISALLOW_COPY_AND_ASSIGN(GuestViewBase); 179 DISALLOW_COPY_AND_ASSIGN(GuestViewBase);
178 }; 180 };
179 181
180 #endif // CHROME_BROWSER_GUEST_VIEW_GUEST_VIEW_BASE_H_ 182 #endif // CHROME_BROWSER_GUEST_VIEW_GUEST_VIEW_BASE_H_
OLDNEW
« no previous file with comments | « chrome/browser/devtools/devtools_targets_ui.cc ('k') | chrome/browser/guest_view/guest_view_base.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698