Correctly set window icon from ICO
This commit is contained in:
parent
ea2807c890
commit
d26480b74e
6 changed files with 34 additions and 13 deletions
|
@ -73,6 +73,14 @@ const char* AppCommandToString(int command_id) {
|
|||
|
||||
} // namespace
|
||||
|
||||
void NativeWindowViews::SetIcon(HICON small_icon, HICON app_icon) {
|
||||
HWND hwnd = GetAcceleratedWidget();
|
||||
SendMessage(hwnd, WM_SETICON, ICON_SMALL,
|
||||
reinterpret_cast<LPARAM>(small_icon));
|
||||
SendMessage(hwnd, WM_SETICON, ICON_BIG,
|
||||
reinterpret_cast<LPARAM>(app_icon));
|
||||
}
|
||||
|
||||
bool NativeWindowViews::ExecuteWindowsCommand(int command_id) {
|
||||
std::string command = AppCommandToString(command_id);
|
||||
NotifyWindowExecuteWindowsCommand(command);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue