Support high dpi icon as window icon.

This commit is contained in:
Cheng Zhao 2014-06-23 22:26:01 +08:00
parent b92e6e97ea
commit ca1d2a32b0
4 changed files with 15 additions and 32 deletions

View file

@ -22,6 +22,7 @@
#include "content/public/browser/web_contents.h"
#include "content/public/browser/web_contents_view.h"
#include "native_mate/dictionary.h"
#include "ui/gfx/image.h"
#include "ui/gfx/path.h"
#include "ui/base/models/simple_menu_model.h"
#include "ui/views/widget/widget.h"
@ -527,10 +528,10 @@ bool NativeWindowWin::ShouldHandleSystemCommands() const {
}
gfx::ImageSkia NativeWindowWin::GetWindowAppIcon() {
if (icon_.IsEmpty())
return gfx::ImageSkia();
if (icon_)
return *(icon_->ToImageSkia());
else
return *icon_.ToImageSkia();
return gfx::ImageSkia();
}
gfx::ImageSkia NativeWindowWin::GetWindowIcon() {