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

Unified Diff: lib/html/scripts/systemnative.py

Issue 11358009: Migrate dart:html codegenerator to new embedder's API. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 8 years, 2 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
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: lib/html/scripts/systemnative.py
diff --git a/lib/html/scripts/systemnative.py b/lib/html/scripts/systemnative.py
index f7ca05d1b669e1fefd939f3f6c2dd7809205f425..edc97927dca33ae60d87d2c9921c00ec2c977a27 100644
--- a/lib/html/scripts/systemnative.py
+++ b/lib/html/scripts/systemnative.py
@@ -602,7 +602,7 @@ class DartiumBackend(object):
self._cpp_impl_includes.add('"DOMWindow.h"')
runtime_check = emitter.Format(
' if (!ContextFeatures::$(FEATURE)Enabled(DartUtilities::domWindowForCurrentIsolate()->document())) {\n'
- ' exception = Dart_NewString("Feature $FEATURE is not enabled");\n'
+ ' exception = Dart_NewStringFromCString("Feature $FEATURE is not enabled");\n'
' goto fail;\n'
' }',
FEATURE=v8EnabledPerContext)
@@ -612,7 +612,7 @@ class DartiumBackend(object):
self._cpp_impl_includes.add('"RuntimeEnabledFeatures.h"')
runtime_check = emitter.Format(
' if (!RuntimeEnabledFeatures::$(FEATURE)Enabled()) {\n'
- ' exception = Dart_NewString("Feature $FEATURE is not enabled");\n'
+ ' exception = Dart_NewStringFromCString("Feature $FEATURE is not enabled");\n'
' goto fail;\n'
' }',
FEATURE=self._ToWebKitName(v8EnabledAtRuntime))
@@ -654,7 +654,7 @@ class DartiumBackend(object):
body_emitter.Emit(
' ScriptExecutionContext* context = DartUtilities::scriptExecutionContext();\n'
' if (!context) {\n'
- ' exception = Dart_NewString("Failed to retrieve a context");\n'
+ ' exception = Dart_NewStringFromCString("Failed to retrieve a context");\n'
' goto fail;\n'
' }\n\n')
@@ -663,7 +663,7 @@ class DartiumBackend(object):
body_emitter.Emit(
' DOMWindow* domWindow = DartUtilities::domWindowForCurrentIsolate();\n'
' if (!domWindow) {\n'
- ' exception = Dart_NewString("Failed to fetch domWindow");\n'
+ ' exception = Dart_NewStringFromCString("Failed to fetch domWindow");\n'
' goto fail;\n'
' }\n'
' Document* document = domWindow->document();\n')
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698