From: sullivan@apple.com Date: Tue, 18 Dec 2007 17:07:55 +0000 (+0000) Subject: Reviewed by Brady X-Git-Url: https://git.webkit.org/?p=WebKit-https.git;a=commitdiff_plain;h=f923f55c6b32272782a1caf0a7f67e52f7b01395;ds=inline Reviewed by Brady - fixed Initial prompt shows "" for databases with no user-visible name * storage/DatabaseTracker.cpp: (WebCore::DatabaseTracker::canEstablishDatabase): pass "name" instead of "displayName" if there's no displayName git-svn-id: https://svn.webkit.org/repository/webkit/trunk@28829 268f45cc-cd09-0410-ab3c-d52691b4dbfc --- diff --git a/WebCore/ChangeLog b/WebCore/ChangeLog index 05adf3713daf..36eb3907a409 100644 --- a/WebCore/ChangeLog +++ b/WebCore/ChangeLog @@ -1,3 +1,13 @@ +2007-12-18 John Sullivan + + Reviewed by Brady + + - fixed Initial prompt shows "" for databases with no user-visible name + + * storage/DatabaseTracker.cpp: + (WebCore::DatabaseTracker::canEstablishDatabase): + pass "name" instead of "displayName" if there's no displayName + 2007-12-17 Dan Bernstein Reviewed by Maciej Stachowiak. diff --git a/WebCore/storage/DatabaseTracker.cpp b/WebCore/storage/DatabaseTracker.cpp index 6af1dfc475c0..399c7832071b 100644 --- a/WebCore/storage/DatabaseTracker.cpp +++ b/WebCore/storage/DatabaseTracker.cpp @@ -145,7 +145,8 @@ bool DatabaseTracker::canEstablishDatabase(Document* document, const String& nam if (!(page = document->page())) return false; - unsigned long long newQuota = page->chrome()->requestQuotaIncreaseForNewDatabase(document->frame(), originData, displayName, estimatedSize); + // If no displayName was specified, pass the standard (required) name instead + unsigned long long newQuota = page->chrome()->requestQuotaIncreaseForNewDatabase(document->frame(), originData, displayName.length() > 0 ? displayName : name, estimatedSize); setQuota(originData, newQuota); return usage + estimatedSize <= newQuota;