Bug 48194

Summary: [Qt] Add API for managing origin quotas in appcache
Product: WebKit Reporter: Robert Hogan <robert>
Component: WebKit QtAssignee: QtWebKit Unassigned <webkit-qt-unassigned>
Status: RESOLVED DUPLICATE    
Severity: Normal CC: cshu, hausmann, kling, krithigassree.sambamurthy
Priority: P2 Keywords: Qt, QtTriaged
Version: 528+ (Nightly build)   
Hardware: PC   
OS: All   
Attachments:
Description Flags
Patch none

Robert Hogan
Reported 2010-10-23 13:42:48 PDT
Add the following API for managing cases where the application cache quota is exceeded in total or per origin. + \fn void QWebPage::applicationCacheQuotaExceeded(qint64 spaceNeeded); + \since 4.5 + + This signal is emitted whenever a web site is asking to store data + to the application cache and the maximum size allocated to the cache is exceeded. + A slot connected to this signal can decide whether to increase the maximum size + of the application cache with QWebSettings::setOfflineWebApplicationCacheQuota(qint64 maximumSize) + to prevent future failures. + + \sa QWebDatabase +*/ + +/*! + \fn void QWebPage::applicationCacheQuotaPerOriginExceeded(QWebSecurityOrigin* origin); + \since 4.8 + + This signal is emitted whenever the web site from \a origin is asking to store data + to the application cache and the quota allocated to that \a origin is exceeded. + A slot connected to this signal can decide whether to increase the quota allocated + to the application cache for the \a origin with + QWebSecurityOrigin::setOfflineWebApplicationCacheQuota(qint64 quota). + + \sa QWebDatabase +*/ + + Sets the quota for the application cache in the security origin to \a quota bytes. + + If the quota is set to a value less than the current usage, the quota will remain + and no data will be purged to meet the new quota. However, no new data can be added + to application caches with this origin. +*/ +void QWebSecurityOrigin::setOfflineWebApplicationCacheQuota(qint64 quota) + \since 4.8 + + Sets the default maximum size of the cache for an offline web application + used by any given QWebSecurityOrigin to \a maximumSize. +*/ +void QWebSettings::setOfflineWebApplicationCacheQuotaPerOrigin(qint64 maximumSize) + +/*! + \since 4.8 + + Returns the default maximum size of the cache for an offline web application + used by any given QWebSecurityOrigin. +*/ +qint64 QWebSettings::offlineWebApplicationCacheQuotaPerOrigin() Unskip http/tests/appcache/origin-quota.html
Attachments
Patch (14.02 KB, patch)
2010-10-23 14:01 PDT, Robert Hogan
no flags
Robert Hogan
Comment 1 2010-10-23 14:01:48 PDT
krithigassree.sambamurthy
Comment 2 2010-12-14 12:52:05 PST
This bug seems to be a duplicate of bug 43455 which was recently fixed.
Robert Hogan
Comment 3 2010-12-14 13:51:55 PST
*** This bug has been marked as a duplicate of bug 43455 ***
Note You need to log in before you can comment on or make changes to this bug.