Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(149)

Unified Diff: tools/dom/templates/html/impl/impl_IDBFactory.darttemplate

Issue 12313015: Dartifying remainder of Index DB APIs. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 7 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: tools/dom/templates/html/impl/impl_IDBFactory.darttemplate
diff --git a/tools/dom/templates/html/impl/impl_IDBFactory.darttemplate b/tools/dom/templates/html/impl/impl_IDBFactory.darttemplate
index 7220e51a2fed4e5c535ee4eec169445da01f9919..59625b3fed63ae455905a03e467082db9d5a908f 100644
--- a/tools/dom/templates/html/impl/impl_IDBFactory.darttemplate
+++ b/tools/dom/templates/html/impl/impl_IDBFactory.darttemplate
@@ -62,6 +62,31 @@ $endif
}
}
+ @DomName('IDBFactory.getDatabaseNames')
+ @SupportedBrowser(SupportedBrowser.CHROME)
+ @Experimental
+ Future<List<String>> getDatabaseNames() {
+ try {
+ var request = $dom_webkitGetDatabaseNames();
+
+ return _completeRequest(request);
+ } catch (e, stacktrace) {
+ return new Future.immediateError(e, stacktrace);
+ }
+ }
+
+ /**
+ * Checks to see if getDatabaseNames is supported by the current platform.
+ */
+ bool get supportsDatabaseNames {
+$if DART2JS
+ return JS('bool', '!!(#.getDatabaseNames || #.webkitGetDatabaseNames)',
+ this, this);
+$else
+ return true;
+$endif
+ }
+
$!MEMBERS
}
« no previous file with comments | « tools/dom/templates/html/impl/impl_IDBDatabase.darttemplate ('k') | tools/dom/templates/html/impl/impl_IDBIndex.darttemplate » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698