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

Side by Side Diff: chrome/browser/extensions/extension_window_controller.cc

Issue 9428018: Create BaseWindow and ExtensionWindowWrapper for extension API access to Panels (Closed) Base URL: http://git.chromium.org/chromium/src.git@master
Patch Set: Address comments, rename -> ExtensionWindowController Created 8 years, 10 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
(Empty)
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
3 // found in the LICENSE file.
4
5 #include "chrome/browser/extensions/extension_window_controller.h"
6
7 #include "chrome/browser/profiles/profile.h"
8
9 ///////////////////////////////////////////////////////////////////////////////
10 // ExtensionWindowController
11
12 ExtensionWindowController::ExtensionWindowController(BaseWindow* window,
13 Profile* profile) :
14 window_(window),
15 profile_(profile) {
16 }
17
18 bool ExtensionWindowController::MatchesProfile(Profile* match_profile,
19 bool allow_incognito) const {
20 return ((profile_ == match_profile) ||
21 (allow_incognito &&
22 (match_profile->HasOffTheRecordProfile() &&
23 match_profile->GetOffTheRecordProfile() == profile_)));
24 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698