-
Notifications
You must be signed in to change notification settings - Fork 56
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
The logic remains mostly the same, except that: 1) nullptr callbacks are simply ignored, not even reported in Debug mode 2) The newly requested size has to exceed that of the existing image on both dimensions, not any of them. This allows to freely request sizes like 32x65535 and then 65535x64 without invalidating the cache. 3) After receiving the image from the network it is stored as is, without immediate scaling to whatever size the request has been initiated with - it is scaled to the requested size before returning the image anyway. 4) Most of request errors except NetworkError and Timeout (think 400, 403, 404 etc.) invalidate the image source entirely now, avoiding repeated attempts to retrieve an image that is not retrievable. The rest is mostly better names (_largestRequestedSize instead of _requestedSize, Invalid instead of Banned, etc.), comments and code readability improvements.
- Loading branch information
1 parent
a313422
commit 9171e7d
Showing
1 changed file
with
71 additions
and
43 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters