mirror of
https://github.com/Garhoogin/NitroPaint.git
synced 2025-06-18 14:25:31 -04:00
Glyph cache refreshes lifetimes
This commit is contained in:
parent
8366bdea21
commit
a047b6c0e0
@ -171,7 +171,12 @@ static int NftrViewerCacheGetByCP(NFTRVIEWERDATA *data, uint16_t cp) {
|
||||
NftrViewerCacheEntry *ent = StListGetPtr(&data->glyphCache, i);
|
||||
if (ent->cp == cp) {
|
||||
//found
|
||||
return ent->image;
|
||||
int iImage = ent->image;
|
||||
NftrViewerCacheEntry cpy;
|
||||
StListGet(&data->glyphCache, i, &cpy);
|
||||
StListRemove(&data->glyphCache, i);
|
||||
StListAdd(&data->glyphCache, &cpy);
|
||||
return iImage;
|
||||
}
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user