diff options
author | Jaakko Keränen <jaakko.keranen@iki.fi> | 2021-05-11 12:56:14 +0300 |
---|---|---|
committer | Jaakko Keränen <jaakko.keranen@iki.fi> | 2021-05-11 12:56:25 +0300 |
commit | 9f7a9058d3593d09a8fad9cd42b59f8a15873837 (patch) | |
tree | 75efa83e07e2130f45308e9bff627b569086fa3a /src/media.c | |
parent | a13543aa922647ea2f8cc40cb9f3f797df8758df (diff) |
Cache GmDocuments in memory
Navigation history keeps final GmDocuments in memory for quicker restore when navigating; no need to redo layout.
Changed the color escape to Vertical Tab so Carriage Returns can be left in the source, reducing need to normalize spaces.
Diffstat (limited to 'src/media.c')
-rw-r--r-- | src/media.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/src/media.c b/src/media.c index 1313b7da..2ec2109d 100644 --- a/src/media.c +++ b/src/media.c | |||
@@ -261,6 +261,11 @@ void clear_Media(iMedia *d) { | |||
261 | clear_PtrArray(&d->downloads); | 261 | clear_PtrArray(&d->downloads); |
262 | } | 262 | } |
263 | 263 | ||
264 | size_t memorySize_Media(const iMedia *d) { | ||
265 | /* TODO: Calculate the actual memory use. */ | ||
266 | return 0; | ||
267 | } | ||
268 | |||
264 | iBool setDownloadUrl_Media(iMedia *d, iGmLinkId linkId, const iString *url) { | 269 | iBool setDownloadUrl_Media(iMedia *d, iGmLinkId linkId, const iString *url) { |
265 | iGmDownload *dl = NULL; | 270 | iGmDownload *dl = NULL; |
266 | iMediaId existing = findLinkDownload_Media(d, linkId); | 271 | iMediaId existing = findLinkDownload_Media(d, linkId); |