Get window icon working in GLFW
Amazingly, this actually works in SDL2, so now they both use this method.
This commit is contained in:
parent
3f4bbc2c5d
commit
ef00bbcdd4
6 changed files with 1 additions and 8 deletions
|
@ -66,8 +66,7 @@ END
|
|||
|
||||
// Icon with lowest ID value placed first to ensure application icon
|
||||
// remains consistent on all systems.
|
||||
101 ICON "ICON/0.ico"
|
||||
102 ICON "ICON/ICON_MINI.ico"
|
||||
GLFW_ICON ICON "ICON/GLFW_ICON.ico"
|
||||
#endif // Japanese resources
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
|
||||
|
|
Binary file not shown.
Before Width: | Height: | Size: 766 B |
BIN
assets/resources/ICON/GLFW_ICON.ico
Normal file
BIN
assets/resources/ICON/GLFW_ICON.ico
Normal file
Binary file not shown.
After Width: | Height: | Size: 1.1 KiB |
Binary file not shown.
Before Width: | Height: | Size: 318 B |
|
@ -27,11 +27,6 @@ void PlatformBackend_Init(void)
|
|||
{
|
||||
SDL_Init(SDL_INIT_EVENTS);
|
||||
|
||||
#ifdef _WIN32 // On Windows, we use native icons instead (so we can give the taskbar and window separate icons, like the original EXE does)
|
||||
SDL_SetHint(SDL_HINT_WINDOWS_INTRESOURCE_ICON, "101");
|
||||
SDL_SetHint(SDL_HINT_WINDOWS_INTRESOURCE_ICON_SMALL, "102");
|
||||
#endif
|
||||
|
||||
SDL_InitSubSystem(SDL_INIT_VIDEO);
|
||||
|
||||
puts("Available SDL2 video drivers:");
|
||||
|
|
|
@ -273,7 +273,6 @@ int main(int argc, char *argv[])
|
|||
#endif
|
||||
|
||||
// Set up window icon
|
||||
// TODO - GLFW_ICON
|
||||
#ifndef _WIN32 // On Windows, we use native icons instead (so we can give the taskbar and window separate icons, like the original EXE does)
|
||||
size_t window_icon_resource_size;
|
||||
const unsigned char *window_icon_resource_data = FindResource("ICON_MINI", "ICON", &window_icon_resource_size);
|
||||
|
|
Loading…
Add table
Reference in a new issue