WebKit Bugzilla
New
Browse
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
RESOLVED FIXED
76004
Use the [Supplemental] IDL in SQLDatabase
https://bugs.webkit.org/show_bug.cgi?id=76004
Summary
Use the [Supplemental] IDL in SQLDatabase
Kentaro Hara
Reported
2012-01-10 16:06:02 PST
We've been working on WebKit modularization. By using the [Supplemental] IDL, we can move SQLDatabase related code from WebCore/page/DOMWindow.{h,cpp,idl} to WebCore/storage/DOMWindowSQLDatabase.{h,cpp,idl}.
Attachments
Patch
(23.25 KB, patch)
2012-01-10 16:16 PST
,
Kentaro Hara
no flags
Details
Formatted Diff
Diff
patch for commit
(23.33 KB, patch)
2012-01-10 16:39 PST
,
Kentaro Hara
no flags
Details
Formatted Diff
Diff
View All
Add attachment
proposed patch, testcase, etc.
Kentaro Hara
Comment 1
2012-01-10 16:16:04 PST
Created
attachment 121932
[details]
Patch
Adam Barth
Comment 2
2012-01-10 16:26:19 PST
Comment on
attachment 121932
[details]
Patch View in context:
https://bugs.webkit.org/attachment.cgi?id=121932&action=review
> Source/WebCore/storage/DOMWindowSQLDatabase.cpp:46 > +PassRefPtr<Database> DOMWindowSQLDatabase::openDatabase(DOMWindow* imp, const String& name, const String& version, const String& displayName, unsigned long estimatedSize, PassRefPtr<DatabaseCallback> creationCallback, ExceptionCode& ec)
Maybe |imp| should be |window| ? We like to use more specific names outside of the bindings.
> Source/WebCore/storage/DOMWindowSQLDatabase.cpp:52 > + if (imp->frame() && AbstractDatabase::isAvailable() && imp->frame()->document()->securityOrigin()->canAccessDatabase())
imp->frame() will always be true when imp->isCurrentlyDisplayedInFrame() is true. imp->frame()->document() can just be imp->document() (there's no reason to indirect through the frame) Feel free to leave the code as-is since you're just moving it. Maybe we should just add FIXME comments about these nits?
> Source/WebCore/storage/DOMWindowSQLDatabase.h:51 > +};
Can you make the constructor and destructor private?
Kentaro Hara
Comment 3
2012-01-10 16:39:58 PST
Created
attachment 121938
[details]
patch for commit
Kentaro Hara
Comment 4
2012-01-10 16:40:41 PST
(In reply to
comment #2
)
> (From update of
attachment 121932
[details]
) > View in context:
https://bugs.webkit.org/attachment.cgi?id=121932&action=review
> > > Source/WebCore/storage/DOMWindowSQLDatabase.cpp:46 > > +PassRefPtr<Database> DOMWindowSQLDatabase::openDatabase(DOMWindow* imp, const String& name, const String& version, const String& displayName, unsigned long estimatedSize, PassRefPtr<DatabaseCallback> creationCallback, ExceptionCode& ec) > > Maybe |imp| should be |window| ? We like to use more specific names outside of the bindings.
Done.
> > Source/WebCore/storage/DOMWindowSQLDatabase.cpp:52 > > + if (imp->frame() && AbstractDatabase::isAvailable() && imp->frame()->document()->securityOrigin()->canAccessDatabase()) > > imp->frame() will always be true when imp->isCurrentlyDisplayedInFrame() is true. > > imp->frame()->document() can just be imp->document() (there's no reason to indirect through the frame) > > Feel free to leave the code as-is since you're just moving it. Maybe we should just add FIXME comments about these nits?
OK, then I'll leave it as-is in this patch and write a follow-up patch.
> > Source/WebCore/storage/DOMWindowSQLDatabase.h:51 > > +}; > > Can you make the constructor and destructor private?
Done. Committed. Thanks!
WebKit Review Bot
Comment 5
2012-01-10 17:12:38 PST
Comment on
attachment 121938
[details]
patch for commit Clearing flags on attachment: 121938 Committed
r104654
: <
http://trac.webkit.org/changeset/104654
>
Adam Barth
Comment 6
2012-02-24 10:18:26 PST
I think this has been fixed.
Note
You need to
log in
before you can comment on or make changes to this bug.
Top of Page
Format For Printing
XML
Clone This Bug