diff options
author | benwells@chromium.org <benwells@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2013-07-11 09:33:23 +0000 |
---|---|---|
committer | benwells@chromium.org <benwells@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2013-07-11 09:33:23 +0000 |
commit | d841dc68f029842bfcdb3a5533480e08360a549f (patch) | |
tree | 77f66594d69f4b1fbc70a5fd01aad02ffcddc1f5 /tools/json_schema_compiler/dart_test | |
parent | a3e4127155aeb3d78aaa9118d9176d0977ec0845 (diff) | |
download | chromium_src-d841dc68f029842bfcdb3a5533480e08360a549f.zip chromium_src-d841dc68f029842bfcdb3a5533480e08360a549f.tar.gz chromium_src-d841dc68f029842bfcdb3a5533480e08360a549f.tar.bz2 |
Updated chrome API dart generator for removal of (?arg) test.
This replaces (?arg) code with (arg != null).
BUG=None
Review URL: https://chromiumcodereview.appspot.com/18675003
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@211054 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'tools/json_schema_compiler/dart_test')
5 files changed, 38 insertions, 38 deletions
diff --git a/tools/json_schema_compiler/dart_test/dictionaries.dart b/tools/json_schema_compiler/dart_test/dictionaries.dart index 2bf531f..ebe92a6 100644 --- a/tools/json_schema_compiler/dart_test/dictionaries.dart +++ b/tools/json_schema_compiler/dart_test/dictionaries.dart @@ -15,29 +15,29 @@ class DictionariesInnerType extends ChromeObject { * Public constructor */ DictionariesInnerType({String s, int b, int i, int l, double d, FileEntry f, String os, int ob, int oi, int ol, double od, FileEntry of}) { - if (?s) + if (s != null) this.s = s; - if (?b) + if (b != null) this.b = b; - if (?i) + if (i != null) this.i = i; - if (?l) + if (l != null) this.l = l; - if (?d) + if (d != null) this.d = d; - if (?f) + if (f != null) this.f = f; - if (?os) + if (os != null) this.os = os; - if (?ob) + if (ob != null) this.ob = ob; - if (?oi) + if (oi != null) this.oi = oi; - if (?ol) + if (ol != null) this.ol = ol; - if (?od) + if (od != null) this.od = od; - if (?of) + if (of != null) this.of = of; } @@ -140,9 +140,9 @@ class DictionariesOuterType extends ChromeObject { * Public constructor */ DictionariesOuterType({List<DictionariesInnerType> items, List<DictionariesInnerType> oitems}) { - if (?items) + if (items != null) this.items = items; - if (?oitems) + if (oitems != null) this.oitems = oitems; } @@ -191,9 +191,9 @@ class DictionariesComplexType extends ChromeObject { * Public constructor */ DictionariesComplexType({int i, DictionariesComplexType c}) { - if (?i) + if (i != null) this.i = i; - if (?c) + if (c != null) this.c = c; } diff --git a/tools/json_schema_compiler/dart_test/events.dart b/tools/json_schema_compiler/dart_test/events.dart index 618b4e0..d2e79ba 100644 --- a/tools/json_schema_compiler/dart_test/events.dart +++ b/tools/json_schema_compiler/dart_test/events.dart @@ -15,7 +15,7 @@ class EventsEventArgumentElement extends ChromeObject { * Public constructor */ EventsEventArgumentElement({String elementStringArg}) { - if (?elementStringArg) + if (elementStringArg != null) this.elementStringArg = elementStringArg; } @@ -40,21 +40,21 @@ class EventsEventArgument extends ChromeObject { * Public constructor */ EventsEventArgument({FileEntry entryArg, String stringArg, int intArg, List<EventsEventArgumentElement> elements, FileEntry optionalEntryArg, String optionalStringArg, int optionalIntArg, List<EventsEventArgumentElement> optionalElements}) { - if (?entryArg) + if (entryArg != null) this.entryArg = entryArg; - if (?stringArg) + if (stringArg != null) this.stringArg = stringArg; - if (?intArg) + if (intArg != null) this.intArg = intArg; - if (?elements) + if (elements != null) this.elements = elements; - if (?optionalEntryArg) + if (optionalEntryArg != null) this.optionalEntryArg = optionalEntryArg; - if (?optionalStringArg) + if (optionalStringArg != null) this.optionalStringArg = optionalStringArg; - if (?optionalIntArg) + if (optionalIntArg != null) this.optionalIntArg = optionalIntArg; - if (?optionalElements) + if (optionalElements != null) this.optionalElements = optionalElements; } @@ -192,7 +192,7 @@ class Event_events_optionalPrimitiveArgEvent extends Event { class Event_events_nonOptionalDictArgEvent extends Event { void addListener(void callback(EventsEventArgument argument)) { void __proxy_callback(argument) { - if (?callback) { + if (callback != null) { callback(new EventsEventArgument._proxy(argument)); } } @@ -201,7 +201,7 @@ class Event_events_nonOptionalDictArgEvent extends Event { void removeListener(void callback(EventsEventArgument argument)) { void __proxy_callback(argument) { - if (?callback) { + if (callback != null) { callback(new EventsEventArgument._proxy(argument)); } } @@ -210,7 +210,7 @@ class Event_events_nonOptionalDictArgEvent extends Event { bool hasListener(void callback(EventsEventArgument argument)) { void __proxy_callback(argument) { - if (?callback) { + if (callback != null) { callback(new EventsEventArgument._proxy(argument)); } } @@ -224,7 +224,7 @@ class Event_events_nonOptionalDictArgEvent extends Event { class Event_events_optionalDictArgEvent extends Event { void addListener(void callback(EventsEventArgument argument)) { void __proxy_callback(argument) { - if (?callback) { + if (callback != null) { callback(new EventsEventArgument._proxy(argument)); } } @@ -233,7 +233,7 @@ class Event_events_optionalDictArgEvent extends Event { void removeListener(void callback(EventsEventArgument argument)) { void __proxy_callback(argument) { - if (?callback) { + if (callback != null) { callback(new EventsEventArgument._proxy(argument)); } } @@ -242,7 +242,7 @@ class Event_events_optionalDictArgEvent extends Event { bool hasListener(void callback(EventsEventArgument argument)) { void __proxy_callback(argument) { - if (?callback) { + if (callback != null) { callback(new EventsEventArgument._proxy(argument)); } } diff --git a/tools/json_schema_compiler/dart_test/functions.dart b/tools/json_schema_compiler/dart_test/functions.dart index 6c31c81..2b4f02b 100644 --- a/tools/json_schema_compiler/dart_test/functions.dart +++ b/tools/json_schema_compiler/dart_test/functions.dart @@ -78,7 +78,7 @@ class API_functions { /// Function taking a dictionary callback. void dictCallbackFunc(void c(DictType dict)) { void __proxy_callback(dict) { - if (?c) { + if (c != null) { c(new DictType._proxy(dict)); } } diff --git a/tools/json_schema_compiler/dart_test/operatable_type.dart b/tools/json_schema_compiler/dart_test/operatable_type.dart index d60c9d3..725d6a6 100644 --- a/tools/json_schema_compiler/dart_test/operatable_type.dart +++ b/tools/json_schema_compiler/dart_test/operatable_type.dart @@ -15,9 +15,9 @@ class Operatable_typeDictType extends ChromeObject { * Public constructor */ Operatable_typeDictType({int x, int y}) { - if (?x) + if (x != null) this.x = x; - if (?y) + if (y != null) this.y = y; } diff --git a/tools/json_schema_compiler/dart_test/tags.dart b/tools/json_schema_compiler/dart_test/tags.dart index 78da51a..4c3514a 100644 --- a/tools/json_schema_compiler/dart_test/tags.dart +++ b/tools/json_schema_compiler/dart_test/tags.dart @@ -54,13 +54,13 @@ class TagsPlainDict extends ChromeObject { * Public constructor */ TagsPlainDict({int inline_doc, String nodoc, double nocompile, fileEntry instance_of_tag}) { - if (?inline_doc) + if (inline_doc != null) this.inline_doc = inline_doc; - if (?nodoc) + if (nodoc != null) this.nodoc = nodoc; - if (?nocompile) + if (nocompile != null) this.nocompile = nocompile; - if (?instance_of_tag) + if (instance_of_tag != null) this.instance_of_tag = instance_of_tag; } |