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

Side by Side Diff: chrome/browser/ui/views/chrome_views_delegate_aura.cc

Issue 108193005: Fixing opacity for browser frame window on ASH/Windows. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Code review changes. Created 7 years 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 | Annotate | Revision Log
OLDNEW
(Empty)
1 // Copyright (c) 2013 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/ui/views/chrome_views_delegate.h"
6
7 #include "chrome/browser/ui/ash/ash_util.h"
8
9 views::Widget::InitParams::WindowOpacity
10 ChromeViewsDelegate::GetOpacityForInitParams(
11 const views::Widget::InitParams& params) {
12 gfx::NativeView native_view = params.parent ? params.parent : params.context;
13 // We want translucent windows when either we are in ASH or we are
14 // a top level window which is not of type TYPE_WINDOW.
15 if ((native_view && chrome::IsNativeViewInAsh(native_view)) ||
16 (params.top_level && params.type !=
17 views::Widget::InitParams::TYPE_WINDOW))
18 return views::Widget::InitParams::TRANSLUCENT_WINDOW;
19
20 return views::Widget::InitParams::OPAQUE_WINDOW;
21 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698