Fix lint
This commit is contained in:
parent
7c1c8f323c
commit
7df5182901
1 changed files with 4 additions and 4 deletions
|
@ -816,14 +816,14 @@ bool NativeWindowViews::HasShadow() {
|
||||||
|
|
||||||
void NativeWindowViews::SetOpacity(const double opacity) {
|
void NativeWindowViews::SetOpacity(const double opacity) {
|
||||||
#if defined(OS_WIN)
|
#if defined(OS_WIN)
|
||||||
|
HWND hwnd = GetAcceleratedWidget();
|
||||||
if (!layered_) {
|
if (!layered_) {
|
||||||
LONG ex_style = ::GetWindowLong(GetAcceleratedWidget(), GWL_EXSTYLE);
|
LONG ex_style = ::GetWindowLong(hwnd, GWL_EXSTYLE);
|
||||||
ex_style |= WS_EX_LAYERED;
|
ex_style |= WS_EX_LAYERED;
|
||||||
::SetWindowLong(GetAcceleratedWidget(), GWL_EXSTYLE, ex_style);
|
::SetWindowLong(hwnd, GWL_EXSTYLE, ex_style);
|
||||||
layered_ = true;
|
layered_ = true;
|
||||||
}
|
}
|
||||||
|
::SetLayeredWindowAttributes(hwnd, 0, opacity * 255, LWA_ALPHA);
|
||||||
::SetLayeredWindowAttributes(GetAcceleratedWidget(), 0, opacity * 255, LWA_ALPHA);
|
|
||||||
#endif
|
#endif
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue