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

Unified Diff: sdk/lib/html/templates/html/impl/impl_History.darttemplate

Issue 11697011: Fixing up history test to pass properly on supported platforms. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Fixing dartium. Created 8 years 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: sdk/lib/html/templates/html/impl/impl_History.darttemplate
diff --git a/sdk/lib/html/templates/dart2js_impl.darttemplate b/sdk/lib/html/templates/html/impl/impl_History.darttemplate
similarity index 53%
copy from sdk/lib/html/templates/dart2js_impl.darttemplate
copy to sdk/lib/html/templates/html/impl/impl_History.darttemplate
index 35ea8d4f1c717e62e81287d9995e09dc8358a951..943d8314691b6179250989aa8d680a74f26b87ba 100644
--- a/sdk/lib/html/templates/dart2js_impl.darttemplate
+++ b/sdk/lib/html/templates/html/impl/impl_History.darttemplate
@@ -6,4 +6,19 @@ part of $LIBRARYNAME;
/// @domName $DOMNAME; @docsEditable true$ANNOTATIONS
class $CLASSNAME$EXTENDS$IMPLEMENTS$NATIVESPEC {
+
+ /**
+ * Checks if the State APIs are supported on the current platform.
+ *
+ * See also:
+ *
+ * * [pushState]
+ * * [replaceState]
+ * * [state]
+ */
+$if DART2JS
+ static bool get supportsState => JS('bool', '!!window.history.pushState');
+$else
+ static bool get supportsState => true;
+$endif
$!MEMBERS}

Powered by Google App Engine
This is Rietveld 408576698