https://github.com/wxWidgets/wxWidgets/pull/26003
(2 files)
—
Reply to this email directly, view it on GitHub, or unsubscribe.
You are receiving this because you are subscribed to this thread.![]()
@vadz commented on this pull request.
This looks a bit strange to me, if I used subdirectories, I would have 1.0x and 2.0x and not . and 2.0x as now, but if this is an established convention, I guess why not.
I also wonder if we need to add support for this to wxOSX, I think it was using "@2x" explicitly somewhere...
> @@ -529,6 +529,12 @@ wxBitmapBundle wxBitmapBundle::FromFiles(const wxString& path, const wxString& f
fn.SetName(wxString::Format("%s_%dx", filename, dpiFactor));
}
+ if ( !fn.FileExists() && dpiFactor != 1 )
This is minor, but we're now calling FileExists() twice completely unnecessarily when dpiFactor is 1. Let's use a temp var instead, i.e.
bool found = fn.FileExists(); if ( !found && dpiFactor != 1 ) { fn.AppendDir(...); found = fn.FileExists(); } if ( found )
—
Reply to this email directly, view it on GitHub, or unsubscribe.
You are receiving this because you are subscribed to this thread.![]()
For reference, here is a description:
.../my_icon.png (mdpi baseline)
.../1.5x/my_icon.png (hdpi)
.../2.0x/my_icon.png (xhdpi)
.../3.0x/my_icon.png (xxhdpi)
.../4.0x/my_icon.png (xxxhdpi)
—
Reply to this email directly, view it on GitHub, or unsubscribe.
You are receiving this because you are subscribed to this thread.![]()