Changeset 54085 in webkit
- Timestamp:
- Jan 29, 2010 4:18:49 PM (14 years ago)
- Location:
- trunk
- Files:
-
- 12 added
- 23 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/ChangeLog
r53935 r54085 1 2010-01-29 Jeremy Orlow <jorlow@chromium.org> 2 3 Reviewed by Dimitri Glazkov. 4 5 A first step towards the Indexed Database API 6 https://bugs.webkit.org/show_bug.cgi?id=34342 7 8 Add Indexed Database API 9 10 * configure.ac: 11 1 12 2010-01-27 Simon Hausmann <simon.hausmann@nokia.com> 2 13 -
trunk/WebCore/ChangeLog
r54083 r54085 1 2010-01-29 Jeremy Orlow <jorlow@chromium.org> 2 3 Reviewed by Dimitri Glazkov. 4 5 A first step towards the Indexed Database API 6 https://bugs.webkit.org/show_bug.cgi?id=34342 7 8 Flesh out the first part of Indexed Database API. 9 Currently only compiles with v8 + chromium for now. 10 Completely non-functional, but it seems best to do 11 this in chunks. 12 13 No tests because nothing works yet. 14 15 * Configurations/FeatureDefines.xcconfig: 16 * WebCore.gypi: 17 * bindings/scripts/CodeGeneratorV8.pm: 18 * bindings/v8/DOMObjectsInclude.h: 19 * bindings/v8/DerivedSourcesAllInOne.cpp: 20 * bindings/v8/RuntimeEnabledFeatures.cpp: 21 * bindings/v8/RuntimeEnabledFeatures.h: 22 (WebCore::RuntimeEnabledFeatures::setIndexedDatabaseEnabled): 23 (WebCore::RuntimeEnabledFeatures::indexedDatabaseEnabled): 24 * bindings/v8/V8Index.cpp: 25 * bindings/v8/V8Index.h: 26 * bindings/v8/custom/V8DOMWindowCustom.cpp: 27 (WebCore::V8DOMWindow::IndexedDBEnabled): 28 * bindings/v8/custom/V8IDBRequestCustom.cpp: Added. 29 (WebCore::V8IDBRequest::resultAccessorGetter): 30 * bindings/v8/custom/V8IndexedDatabaseRequestCustom.cpp: Added. 31 (WebCore::V8IndexedDatabaseRequest::openCallback): 32 * dom/EventNames.h: 33 * page/DOMWindow.cpp: 34 (WebCore::DOMWindow::indexedDB): 35 * page/DOMWindow.h: 36 * page/DOMWindow.idl: 37 * storage/IDBDatabaseError.h: Added. 38 (WebCore::IDBDatabaseError::create): 39 (WebCore::IDBDatabaseError::~IDBDatabaseError): 40 (WebCore::IDBDatabaseError::code): 41 (WebCore::IDBDatabaseError::setCode): 42 (WebCore::IDBDatabaseError::message): 43 (WebCore::IDBDatabaseError::setMessage): 44 (WebCore::IDBDatabaseError::IDBDatabaseError): 45 * storage/IDBDatabaseError.idl: Added. 46 * storage/IDBDatabaseException.h: Added. 47 (WebCore::IDBDatabaseException::create): 48 (WebCore::IDBDatabaseException::~IDBDatabaseException): 49 (WebCore::IDBDatabaseException::code): 50 (WebCore::IDBDatabaseException::setCode): 51 (WebCore::IDBDatabaseException::message): 52 (WebCore::IDBDatabaseException::setMessage): 53 (WebCore::IDBDatabaseException::IDBDatabaseException): 54 * storage/IDBDatabaseException.idl: Added. 55 * storage/IDBRequest.cpp: Added. 56 (WebCore::IDBRequest::IDBRequest): 57 (WebCore::IDBRequest::~IDBRequest): 58 (WebCore::IDBRequest::abort): 59 (WebCore::IDBRequest::eventTargetData): 60 (WebCore::IDBRequest::ensureEventTargetData): 61 * storage/IDBRequest.h: Added. 62 (WebCore::IDBRequest::create): 63 (WebCore::IDBRequest::readyState): 64 (WebCore::IDBRequest::error): 65 (WebCore::IDBRequest::result): 66 (WebCore::IDBRequest::scriptExecutionContext): 67 (WebCore::IDBRequest::toIDBRequest): 68 (WebCore::IDBRequest::refEventTarget): 69 (WebCore::IDBRequest::derefEventTarget): 70 * storage/IDBRequest.idl: Added. 71 * storage/IndexedDatabaseRequest.cpp: Added. 72 (WebCore::IndexedDatabaseRequest::IndexedDatabaseRequest): 73 (WebCore::IndexedDatabaseRequest::~IndexedDatabaseRequest): 74 (WebCore::IndexedDatabaseRequest::open): 75 * storage/IndexedDatabaseRequest.h: Added. 76 (WebCore::IndexedDatabaseRequest::create): 77 (WebCore::IndexedDatabaseRequest::request): 78 * storage/IndexedDatabaseRequest.idl: Added. 79 1 80 2010-01-29 Brian Weinstein <bweinstein@apple.com> 2 81 -
trunk/WebCore/Configurations/FeatureDefines.xcconfig
r53746 r54085 52 52 ENABLE_GEOLOCATION = ENABLE_GEOLOCATION; 53 53 ENABLE_ICONDATABASE = ENABLE_ICONDATABASE; 54 ENABLE_INDEXED_DATABASE = ENABLE_INDEXED_DATABASE; 54 55 ENABLE_JAVASCRIPT_DEBUGGER = ENABLE_JAVASCRIPT_DEBUGGER; 55 56 ENABLE_MATHML = ; … … 72 73 ENABLE_XSLT = ENABLE_XSLT; 73 74 74 FEATURE_DEFINES = $(ENABLE_3D_CANVAS) $(ENABLE_3D_RENDERING) $(ENABLE_CHANNEL_MESSAGING) $(ENABLE_CLIENT_BASED_GEOLOCATION) $(ENABLE_DATABASE) $(ENABLE_DATAGRID) $(ENABLE_DATALIST) $(ENABLE_DOM_STORAGE) $(ENABLE_EVENTSOURCE) $(ENABLE_FILTERS) $(ENABLE_GEOLOCATION) $(ENABLE_ICONDATABASE) $(ENABLE_ JAVASCRIPT_DEBUGGER) $(ENABLE_MATHML) $(ENABLE_NOTIFICATIONS) $(ENABLE_OFFLINE_WEB_APPLICATIONS) $(ENABLE_SHARED_WORKERS) $(ENABLE_SVG) $(ENABLE_SVG_ANIMATION) $(ENABLE_SVG_AS_IMAGE) $(ENABLE_SVG_DOM_OBJC_BINDINGS) $(ENABLE_SVG_FONTS) $(ENABLE_SVG_FOREIGN_OBJECT) $(ENABLE_SVG_USE) $(ENABLE_VIDEO) $(ENABLE_WEB_SOCKETS) $(ENABLE_WML) $(ENABLE_WORKERS) $(ENABLE_XHTMLMP) $(ENABLE_XPATH) $(ENABLE_XSLT);75 FEATURE_DEFINES = $(ENABLE_3D_CANVAS) $(ENABLE_3D_RENDERING) $(ENABLE_CHANNEL_MESSAGING) $(ENABLE_CLIENT_BASED_GEOLOCATION) $(ENABLE_DATABASE) $(ENABLE_DATAGRID) $(ENABLE_DATALIST) $(ENABLE_DOM_STORAGE) $(ENABLE_EVENTSOURCE) $(ENABLE_FILTERS) $(ENABLE_GEOLOCATION) $(ENABLE_ICONDATABASE) $(ENABLE_INDEXED_DATABASE) $(ENABLE_JAVASCRIPT_DEBUGGER) $(ENABLE_MATHML) $(ENABLE_NOTIFICATIONS) $(ENABLE_OFFLINE_WEB_APPLICATIONS) $(ENABLE_SHARED_WORKERS) $(ENABLE_SVG) $(ENABLE_SVG_ANIMATION) $(ENABLE_SVG_AS_IMAGE) $(ENABLE_SVG_DOM_OBJC_BINDINGS) $(ENABLE_SVG_FONTS) $(ENABLE_SVG_FOREIGN_OBJECT) $(ENABLE_SVG_USE) $(ENABLE_VIDEO) $(ENABLE_WEB_SOCKETS) $(ENABLE_WML) $(ENABLE_WORKERS) $(ENABLE_XHTMLMP) $(ENABLE_XPATH) $(ENABLE_XSLT); -
trunk/WebCore/WebCore.gypi
r54053 r54085 212 212 'plugins/PluginArray.idl', 213 213 'storage/Database.idl', 214 'storage/IDBDatabaseError.idl', 215 'storage/IDBDatabaseException.idl', 216 'storage/IDBRequest.idl', 217 'storage/IndexedDatabaseRequest.idl', 214 218 'storage/SQLError.idl', 215 219 'storage/SQLResultSet.idl', … … 718 722 'bindings/v8/custom/V8HTMLSelectElementCustom.cpp', 719 723 'bindings/v8/custom/V8HTMLSelectElementCustom.h', 724 'bindings/v8/custom/V8IDBRequestCustom.cpp', 725 'bindings/v8/custom/V8IndexedDatabaseRequestCustom.cpp', 720 726 'bindings/v8/custom/V8InjectedScriptHostCustom.cpp', 721 727 'bindings/v8/custom/V8InspectorFrontendHostCustom.cpp', … … 3181 3187 'storage/DatabaseTracker.h', 3182 3188 'storage/DatabaseTrackerClient.h', 3189 'storage/IDBDatabaseError.h', 3190 'storage/IDBDatabaseException.h', 3191 'storage/IDBRequest.cpp', 3192 'storage/IDBRequest.h', 3193 'storage/IndexedDatabaseRequest.cpp', 3194 'storage/IndexedDatabaseRequest.h', 3183 3195 'storage/LocalStorageTask.cpp', 3184 3196 'storage/LocalStorageTask.h', -
trunk/WebCore/bindings/scripts/CodeGeneratorV8.pm
r54042 r54085 376 376 return ("abstractWorkerCacheIndex", "workerContextCacheIndex", "cacheIndex") if $name eq "SharedWorkerContext"; 377 377 return ("cacheIndex") if $name eq "Notification"; 378 return ("cacheIndex") if $name eq "IDBRequest"; 378 379 return ("cacheIndex") if $name eq "SVGElementInstance"; 379 380 return ("consoleIndex", "historyIndex", "locationbarIndex", "menubarIndex", "navigatorIndex", "personalbarIndex", -
trunk/WebCore/bindings/v8/DOMObjectsInclude.h
r53931 r54085 199 199 #include "PositionError.h" 200 200 201 #if ENABLE(INDEXED_DATABASE) 202 #include "IDBDatabaseError.h" 203 #include "IDBDatabaseException.h" 204 #include "IDBRequest.h" 205 #include "IndexedDatabaseRequest.h" 206 #endif // DATABASE 207 201 208 #if ENABLE(SVG) 202 209 #include "SVGAngle.h" -
trunk/WebCore/bindings/v8/DerivedSourcesAllInOne.cpp
r53931 r54085 258 258 #endif 259 259 260 #if ENABLE(INDEXED_DATABASE) 261 #include "bindings/V8IDBDatabaseError.cpp" 262 #include "bindings/V8IDBDatabaseException.cpp" 263 #include "bindings/V8IDBRequest.cpp" 264 #include "bindings/V8IndexedDatabaseRequest.cpp" 265 #endif 266 260 267 #if ENABLE(WORKERS) 261 268 #include "bindings/V8AbstractWorker.cpp" -
trunk/WebCore/bindings/v8/RuntimeEnabledFeatures.cpp
r53641 r54085 39 39 bool RuntimeEnabledFeatures::isApplicationCacheEnabled = false; 40 40 bool RuntimeEnabledFeatures::isGeolocationEnabled = false; 41 bool RuntimeEnabledFeatures::isIndexedDatabaseEnabled = false; 41 42 42 43 } // namespace WebCore -
trunk/WebCore/bindings/v8/RuntimeEnabledFeatures.h
r53641 r54085 52 52 static bool geolocationEnabled() { return isGeolocationEnabled; } 53 53 54 static void setIndexedDatabaseEnabled(bool isEnabled) { isIndexedDatabaseEnabled = isEnabled; } 55 static bool indexedDatabaseEnabled() { return isIndexedDatabaseEnabled; } 56 54 57 private: 55 58 // Never instantiate. … … 61 64 static bool isApplicationCacheEnabled; 62 65 static bool isGeolocationEnabled; 66 static bool isIndexedDatabaseEnabled; 63 67 }; 64 68 -
trunk/WebCore/bindings/v8/V8Index.cpp
r53931 r54085 428 428 #endif 429 429 430 #if ENABLE(INDEXED_DATABASE) 431 #include "V8IDBDatabaseError.h" 432 #include "V8IDBDatabaseException.h" 433 #include "V8IDBRequest.h" 434 #include "V8IndexedDatabaseRequest.h" 435 #endif 436 430 437 #if ENABLE(XPATH) 431 438 #include "V8XPathResult.h" -
trunk/WebCore/bindings/v8/V8Index.h
r53931 r54085 454 454 #endif 455 455 456 #if ENABLE(INDEXED_DATABASE) 457 #define DOM_OBJECT_INDEXED_DATABASE_TYPES(V) \ 458 V(IDBDATABASEERROR, IDBDatabaseError) \ 459 V(IDBDATABASEEXCEPTION, IDBDatabaseException) \ 460 V(IDBREQUEST, IDBRequest) \ 461 V(INDEXEDDATABASEREQUEST, IndexedDatabaseRequest) 462 #else 463 #define DOM_OBJECT_INDEXED_DATABASE_TYPES(V) 464 #endif 465 456 466 #if ENABLE(WORKERS) 457 467 #define DOM_OBJECT_WORKERS_TYPES(V) \ … … 524 534 DOM_OBJECT_DATABASE_TYPES(V) \ 525 535 DOM_OBJECT_STORAGE_TYPES(V) \ 536 DOM_OBJECT_INDEXED_DATABASE_TYPES(V) \ 526 537 DOM_OBJECT_WORKERS_TYPES(V) \ 527 538 DOM_OBJECT_3D_CANVAS_TYPES(V) \ -
trunk/WebCore/bindings/v8/custom/V8DOMWindowCustom.cpp
r53595 r54085 302 302 #endif 303 303 304 #if ENABLE(INDEXED_DATABASE) 305 bool V8DOMWindow::IndexedDBEnabled() 306 { 307 return RuntimeEnabledFeatures::indexedDatabaseEnabled(); 308 } 309 #endif 310 304 311 #if ENABLE(DOM_STORAGE) 305 312 bool V8DOMWindow::LocalStorageEnabled() -
trunk/WebCore/dom/EventNames.h
r53548 r54085 152 152 macro(touchcancel) \ 153 153 \ 154 macro(success) \ 155 \ 154 156 // end of DOM_EVENT_NAMES_FOR_EACH 155 157 -
trunk/WebCore/page/DOMWindow.cpp
r53739 r54085 644 644 #endif 645 645 646 #if ENABLE(INDEXED_DATABASE) 647 IndexedDatabaseRequest* DOMWindow::indexedDB() const 648 { 649 return 0; 650 } 651 #endif 652 646 653 void DOMWindow::postMessage(PassRefPtr<SerializedScriptValue> message, MessagePort* port, const String& targetOrigin, DOMWindow* source, ExceptionCode& ec) 647 654 { -
trunk/WebCore/page/DOMWindow.h
r53555 r54085 53 53 class Frame; 54 54 class History; 55 class IndexedDatabaseRequest; 55 56 class InspectorTimelineAgent; 56 57 class Location; … … 215 216 #if ENABLE(NOTIFICATIONS) 216 217 NotificationCenter* webkitNotifications() const; 218 #endif 219 220 #if ENABLE(INDEXED_DATABASE) 221 IndexedDatabaseRequest* indexedDB() const; 217 222 #endif 218 223 -
trunk/WebCore/page/DOMWindow.idl
r53722 r54085 170 170 #if defined(ENABLE_NOTIFICATIONS) && ENABLE_NOTIFICATIONS 171 171 readonly attribute [EnabledAtRuntime] NotificationCenter webkitNotifications; 172 #endif 173 #if defined(ENABLE_INDEXED_DATABASE) && ENABLE_INDEXED_DATABASE 174 readonly attribute [EnabledAtRuntime] IndexedDatabaseRequest indexedDB; 172 175 #endif 173 176 -
trunk/WebKit/chromium/ChangeLog
r54057 r54085 1 2010-01-29 Jeremy Orlow <jorlow@chromium.org> 2 3 Reviewed by Dimitri Glazkov. 4 5 A first step towards the Indexed Database API 6 https://bugs.webkit.org/show_bug.cgi?id=34342 7 8 Add runtime enable support for Indexed Database API. 9 10 * features.gypi: 11 * public/WebRuntimeFeatures.h: 12 * src/WebRuntimeFeatures.cpp: 13 (WebKit::WebRuntimeFeatures::enableIndexedDatabase): 14 (WebKit::WebRuntimeFeatures::isIndexedDatabaseEnabled): 15 1 16 2010-01-29 Yury Semikhatsky <yurys@chromium.org> 2 17 -
trunk/WebKit/chromium/features.gypi
r52972 r54085 51 51 'ENABLE_JSC_MULTIPLE_THREADS=0', 52 52 'ENABLE_ICONDATABASE=0', 53 'ENABLE_INDEXED_DATABASE=1', 53 54 'ENABLE_NOTIFICATIONS=1', 54 55 'ENABLE_OPENTYPE_SANITIZER=1', -
trunk/WebKit/chromium/public/WebRuntimeFeatures.h
r53406 r54085 66 66 WEBKIT_API static bool isGeolocationEnabled(); 67 67 68 WEBKIT_API static void enableIndexedDatabase(bool); 69 WEBKIT_API static bool isIndexedDatabaseEnabled(); 70 68 71 private: 69 72 WebRuntimeFeatures(); -
trunk/WebKit/chromium/src/WebRuntimeFeatures.cpp
r53641 r54085 169 169 } 170 170 171 void WebRuntimeFeatures::enableIndexedDatabase(bool enable) 172 { 173 #if ENABLE(INDEXED_DATABASE) 174 RuntimeEnabledFeatures::setIndexedDatabaseEnabled(enable); 175 #endif 176 } 177 178 bool WebRuntimeFeatures::isIndexedDatabaseEnabled() 179 { 180 #if ENABLE(INDEXED_DATABASE) 181 return RuntimeEnabledFeatures::indexedDatabaseEnabled(); 182 #else 183 return false; 184 #endif 185 } 186 171 187 } // namespace WebKit -
trunk/WebKitTools/ChangeLog
r54084 r54085 1 2010-01-29 Jeremy Orlow <jorlow@chromium.org> 2 3 Reviewed by Dimitri Glazkov. 4 5 A first step towards the Indexed Database API 6 https://bugs.webkit.org/show_bug.cgi?id=34342 7 8 Add indexed database API. 9 10 * Scripts/build-webkit: 11 1 12 2010-01-29 Andras Becsi <abecsi@webkit.org> 2 13 -
trunk/WebKitTools/Scripts/build-webkit
r53746 r54085 52 52 53 53 my ($threeDCanvasSupport, $threeDRenderingSupport, $channelMessagingSupport, $clientBasedGeolocationSupport, $databaseSupport, $datagridSupport, $datalistSupport, 54 $domStorageSupport, $eventsourceSupport, $filtersSupport, $geolocationSupport, $iconDatabaseSupport, 54 $domStorageSupport, $eventsourceSupport, $filtersSupport, $geolocationSupport, $iconDatabaseSupport, $indexedDatabaseSupport, 55 55 $javaScriptDebuggerSupport, $mathmlSupport, $offlineWebApplicationSupport, $sharedWorkersSupport, 56 56 $svgSupport, $svgAnimationSupport, $svgAsImageSupport, $svgDOMObjCBindingsSupport, $svgFontsSupport, … … 97 97 { option => "icon-database", desc => "Toggle Icon database support", 98 98 define => "ENABLE_ICONDATABASE", default => 1, value => \$iconDatabaseSupport }, 99 100 { option => "indexed-database", desc => "Toggle Indexed Database API support", 101 define => "ENABLE_INDEXED_DATABASE", default => 0, value => \$indexedDatabaseSupport }, 99 102 100 103 { option => "javascript-debugger", desc => "Toggle JavaScript Debugger/Profiler support", -
trunk/configure.ac
r53505 r54085 331 331 [],[enable_dom_storage="yes"]) 332 332 AC_MSG_RESULT([$enable_dom_storage]) 333 334 # check whether to enable the indexed database API 335 AC_MSG_CHECKING([whether to enable the indexed database API]) 336 AC_ARG_ENABLE(indexed_database, 337 AC_HELP_STRING([--enable-indexeddb], 338 [enable the indexed database API [default=no]]), 339 [],[enable_indexed_database="no"]) 340 AC_MSG_RESULT([$enable_indexed_database]) 333 341 334 342 # check whether to build with database support … … 752 760 AM_CONDITIONAL([ENABLE_EVENTSOURCE],[test "$enable_eventsource" = "yes"]) 753 761 AM_CONDITIONAL([ENABLE_ICONDATABASE],[test "$enable_icon_database" = "yes"]) 762 AM_CONDITIONAL([ENABLE_INDEXED_DATABASE],[test "$enable_indexed_database" = "yes"]) 754 763 AM_CONDITIONAL([ENABLE_XHTMLMP],[test "$enable_xhtmlmp" = "yes"]) 755 764 AM_CONDITIONAL([ENABLE_XPATH],[test "$enable_xpath" = "yes"])
Note: See TracChangeset
for help on using the changeset viewer.