Use gfx::Rect::ToRECT
This commit is contained in:
parent
5f2a13d01b
commit
2802d2f3f9
1 changed files with 2 additions and 7 deletions
|
@ -168,13 +168,8 @@ bool TaskbarHost::SetThumbnailClip(HWND window, const gfx::Rect& region) {
|
||||||
if (region.IsEmpty()) {
|
if (region.IsEmpty()) {
|
||||||
return SUCCEEDED(taskbar_->SetThumbnailClip(window, NULL));
|
return SUCCEEDED(taskbar_->SetThumbnailClip(window, NULL));
|
||||||
} else {
|
} else {
|
||||||
gfx::Rect screen_rect = display::win::ScreenWin::DIPToScreenRect(window,
|
RECT rect = display::win::ScreenWin::DIPToScreenRect(window, region)
|
||||||
region);
|
.ToRECT();
|
||||||
RECT rect;
|
|
||||||
rect.left = screen_rect.x();
|
|
||||||
rect.right = screen_rect.right();
|
|
||||||
rect.top = screen_rect.y();
|
|
||||||
rect.bottom = screen_rect.bottom();
|
|
||||||
return SUCCEEDED(taskbar_->SetThumbnailClip(window, &rect));
|
return SUCCEEDED(taskbar_->SetThumbnailClip(window, &rect));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue