search for: hasownproperty

Displaying 20 results from an estimated 29 matches for "hasownproperty".

2007 Aug 21
0
2 commits - test/trace
..., 98 deletions(-) New commits: diff-tree 92ddd92a1bf234440d90f8707067be07d36ab16c (from f1d548cb56d3e4f8b48eb1fc99ebb006f61c259f) Author: Pekka Lampila <pekka.lampila at iki.fi> Date: Tue Aug 21 23:02:26 2007 +0300 Fix errors in the trace_properties.as Only use own version of hasOwnProperty in version 5 Recompile propflags to use the new code diff --git a/test/trace/propflags-5.swf b/test/trace/propflags-5.swf index 3f6f077..acea9ad 100644 Binary files a/test/trace/propflags-5.swf and b/test/trace/propflags-5.swf differ diff --git a/test/trace/propflags-6.swf b/test/trace/propfla...
2007 Aug 21
0
4 commits - libswfdec/swfdec_as_array.c libswfdec/swfdec_as_boolean.c libswfdec/swfdec_as_function.c libswfdec/swfdec_as_number.c libswfdec/swfdec_as_object.c libswfdec/swfdec_as_string.c libswfdec/swfdec_color_as.c test/trace
...i> Date: Wed Aug 22 00:05:31 2007 +0300 Another small fix to trace_properties.as diff --git a/test/trace/trace_properties.as b/test/trace/trace_properties.as index a93f05c..5c6f171 100644 --- a/test/trace/trace_properties.as +++ b/test/trace/trace_properties.as @@ -16,8 +16,8 @@ function hasOwnProperty (o, prop) if (o.hasOwnProperty != undefined) return o.hasOwnProperty (prop); - o.hasOwnProperty = Object.prototype.hasOwnProperty; - result = o.hasOwnProperty (prop); + o.hasOwnProperty = _global.Object.prototype.hasOwnProperty; + var result = o.hasOwnProperty (prop); delete o.hasO...
2007 Sep 18
4
Prototype.js and Multidimensional Arrays
Hi there, this code works only fine , if i dont embedding the prototype.js in my document: <script type="text/javascript"> var myCheckBox2 = new Array(); myCheckBox2[''Ort''] = new Array("hamburg","berlin","hannover"); myCheckBox2[''Art''] = new Array("programmierung","support");
2007 Aug 22
0
3 commits - libswfdec/swfdec_as_array.c libswfdec/swfdec_as_function.c test/trace
...= setTimeout; +_global.showRedrawRegions = showRedrawRegions; +_global.textRenderer = textRenderer; +_global.trace = trace; +_global.unescape = unescape; +_global.updateAfterEvent = updateAfterEvent; +#endif function new_empty_object () { var hash = new Object (); @@ -65,7 +132,8 @@ function hasOwnProperty (o, prop) if (o[prop] != o.__proto__[prop]) { return true; } else { - trace ("ERROR: can't test property '" + prop + "', __proto__ has superconstant version"); + trace ("ERROR: can't test property '" + prop + + "', __proto...
2007 Aug 20
0
3 commits - libswfdec/swfdec_as_context.c test/trace
...hat are not permanent -function permanent_properties (obj) -{ - hidden = hidden_properties (obj); - constant = constant_properties (obj); - - ASSetPropFlags (obj, hidden, 0, 1); - - permanent = new Array(); - for (var prop in obj) { - var old = obj[prop]; - delete obj[prop]; - if (obj.hasOwnProperty (prop)) { - permanent.push (prop); - } else { - obj[prop] = old; - } - } - - ASSetPropFlags (obj, hidden, 1, 0); - ASSetPropFlags (obj, constant, 3, 0); - - return permanent.sort (); -} - -function constant_properties (obj) -{ - hidden = hidden_properties (obj); - - ASSetPropF...
2007 Oct 12
0
Changes to 'refs/tags/0.5.3'
..._internal.h only provide a new image if decoding succeeded only iterate audio if there is audio to iterate only do size changes when decoding was successful various fixes: Merge branch 'master' of ssh://company at git.freedesktop.org/git/swfdec/swfdec use hasOwnProperty instead of != undefined to figure out if the object has the property use the right frame when creating an audio stream make this work when time_t is 32bit, too merge the too get_variable functions, so we can export swfdec_movie_get_by_path() implement swfdec_action_get_movie...
2007 Aug 15
3
2 commits - libswfdec/swfdec_as_object.c test/trace
libswfdec/swfdec_as_object.c | 62 +++++++++++++++------- test/trace/Makefile.am | 9 +++ test/trace/addProperty-set-prototypes-5.swf |binary test/trace/addProperty-set-prototypes-5.swf.trace | 4 + test/trace/addProperty-set-prototypes-6.swf |binary test/trace/addProperty-set-prototypes-6.swf.trace | 5 +
2007 Oct 28
1
test/trace
...SWFTextField (); + display = SWFMovie_add (movie, (SWFBlock) text); + + SWFMovie_add (movie, (SWFBlock) newSWFAction ("" + "trace ('Test whether native properties of TextField are initialized if the movie contains an EditText tag');" + "_global.TextField.prototype.hasOwnProperty = ASnative (101, 5);" + "trace (_global.TextField.prototype.hasOwnProperty ('text'));" + "_global.TextField.prototype = new Object ();" + "loadMovie (\"FSCommand:quit\", \"\");" + "")); + SWFMovie_nextFrame (movie); + + spri...
2007 Sep 04
0
4 commits - libswfdec/swfdec_as_array.c libswfdec/swfdec_video_movie_as.c test/trace
...l.a = _global.Number.prototype + constructor (h) = _global.Number +local.b = number : 42 diff --git a/test/trace/trace_properties.as b/test/trace/trace_properties.as index 3925bdb..bcd0a08 100644 --- a/test/trace/trace_properties.as +++ b/test/trace/trace_properties.as @@ -112,8 +112,9 @@ function hasOwnProperty (o, prop) o.__proto__ = "to-be-deleted"; delete o.__proto__; if (o.__proto__ != undefined) { - trace ("ERROR: Couldn't delete temporary __proto__"); o.__proto__ = undefined; + if (o.__proto__ != undefined) + trace ("ERROR: Couldn't de...
2010 May 21
0
r83 committed - Making the geocoder pass JSLint
...;' not supported by mapstraction-geocoder''); } -} +}; /** * Change the Routing API to use * @param {String} api The API to swap to @@ -76,17 +76,17 @@ if (this.api == api) { return; } this.api = api; - if (this.geocoders[this.api] == undefined) { + if (!this.geocoders.hasOwnProperty(this.api)) { this.addAPI($(element),api); } -} +}; /** * Default Geocode error function */ MapstractionGeocoder.prototype.geocode_error = function(response) { alert("Sorry, we were unable to geocode that address"); -} +}; /** * Default handler for geocode reques...
2007 Oct 25
0
18 commits - libswfdec/swfdec_player_internal.h libswfdec/swfdec_text_field_movie_as.c libswfdec/swfdec_text_format.c libswfdec/swfdec_text_format.h libswfdec/swfdec_xml.c libswfdec/swfdec_xml_node.c libswfdec/swfdec_xml_node.h test/trace
...est/trace/text-field-init.as b/test/trace/text-field-init.as new file mode 100644 index 0000000..336f1ce --- /dev/null +++ b/test/trace/text-field-init.as @@ -0,0 +1,47 @@ +// makeswf -v 7 -r 1 -o textfield-init-7.swf textfield-init.as + +function check_and_reset () { + _global.TextField.prototype.hasOwnProperty = ASnative (101, 5); + trace (_global.TextField.prototype.hasOwnProperty ("text")); + _global.TextField.prototype = new Object (); +} + +trace ("Check when TextField's native properties are initialized"); + +// FIXME: Not tested yet: The properties should only be created i...
2009 May 31
7
[mapstraction commit] r11 - Added functionality to automatically load scripts needed.
...plementation of a particular method. */ var invoke = function(sApiId, sObjName, sFnName, oScope, args){ @@ -29,14 +77,14 @@ }; return { - + /** * Registers a set of provider specific implementation functions. */ register: function(sApiId, oApiImpl){ if(!apis.hasOwnProperty(sApiId)) apis[sApiId] = {}; mxn.util.merge(apis[sApiId], oApiImpl); - }, + }, /** * Adds a list of named proxy methods to the prototype of a @@ -202,21 +250,8 @@ * @param {String} src URL to JSON file * @param {Function} callback Callback function */ - loa...
2005 Sep 25
1
Prototype "classes" and inheritance
JavaScript doesn''t (yet) have a notion of classes. Prototype.js just adds a suitable convention for implementing them. It provides a way to create a new class by extending a base class using Object.extend, but it doesn''t handle method inheritance. There are ways of doing implementing this through traversing the chain of prototypes, but I''m not sure they are
2007 Sep 03
0
20 commits - libswfdec/Makefile.am libswfdec/swfdec_as_context.c libswfdec/swfdec_as_function.c libswfdec/swfdec_as_initialize.as libswfdec/swfdec_as_initialize.h libswfdec/swfdec_as_internal.h libswfdec/swfdec_as_interpret.c libswfdec/swfdec_as_number.c
.....7944812 --- /dev/null +++ b/test/trace/constructor-madness.as @@ -0,0 +1,10 @@ +// makeswf -v 7 -s 200x150 -r 1 -o constructor-madness.swf constructor-madness.as + +trace ("Check what version has __constructor__ vs constructor"); +o = new Object (); +trace (o.__constructor__); +trace (o.hasOwnProperty ("__constructor__")); +trace (o.constructor); +trace (o.hasOwnProperty ("constructor")); + +loadMovie ("FSCommand:quit", ""); diff-tree 62f2e4615342ee03bfd8d24e7ebc46752731c2d0 (from 12ed7065f523247bd107c2b03cc087d89d9177c3) Author: Benjamin Otte <otte at...
2007 Sep 11
0
8 commits - libswfdec/swfdec_as_function.c libswfdec/swfdec_as_initialize.as libswfdec/swfdec_as_initialize.h libswfdec/swfdec_as_object.c libswfdec/swfdec_as_strings.c test/trace
...atch_test, "user data")); o.test = 1; @@ -47,7 +55,21 @@ o.test = 1; trace (o.unwatch ("test")); o.test = 2; -// missing params + +trace ("deleting the variable"); +o.test = 0; +trace (o.watch ("test", watch_test)); +o.test = 1; +delete o.test; +trace (o.hasOwnProperty ("test")); +o.test = 2; +delete o.test; +trace (o.hasOwnProperty ("test")); +trace (o.unwatch ("test")); +o.test = 3; + + +trace ("missing params"); trace (o.watch ()); trace (o.unwatch ()); @@ -57,14 +79,30 @@ o.test = 1; trace (o.unwatch ("test&qu...
2007 Aug 20
0
Branch 'vivi' - 60 commits - libswfdec-gtk/swfdec_gtk_loader.c libswfdec/Makefile.am libswfdec/swfdec_as_array.c libswfdec/swfdec_as_context.c libswfdec/swfdec_as_frame.c libswfdec/swfdec_as_frame_internal.h libswfdec/swfdec_as_interpret.c
...hat are not permanent -function permanent_properties (obj) -{ - hidden = hidden_properties (obj); - constant = constant_properties (obj); - - ASSetPropFlags (obj, hidden, 0, 1); - - permanent = new Array(); - for (var prop in obj) { - var old = obj[prop]; - delete obj[prop]; - if (obj.hasOwnProperty (prop)) { - permanent.push (prop); - } else { - obj[prop] = old; - } - } - - ASSetPropFlags (obj, hidden, 1, 0); - ASSetPropFlags (obj, constant, 3, 0); - - return permanent.sort (); -} - -function constant_properties (obj) -{ - hidden = hidden_properties (obj); - - ASSetPropF...
2007 Aug 17
0
4 commits - libswfdec/swfdec_as_context.c libswfdec/swfdec_as_interpret.c libswfdec/swfdec_as_object.c libswfdec/swfdec_as_object.h test/trace
...hat are not permanent +function permanent_properties (obj) +{ + hidden = hidden_properties (obj); + constant = constant_properties (obj); + + ASSetPropFlags (obj, hidden, 0, 1); + + permanent = new Array(); + for (var prop in obj) { + var old = obj[prop]; + delete obj[prop]; + if (obj.hasOwnProperty (prop)) { + permanent.push (prop); + } else { + obj[prop] = old; + } + } + + ASSetPropFlags (obj, hidden, 1, 0); + ASSetPropFlags (obj, constant, 3, 0); + + return permanent; +} + +function constant_properties (obj) +{ + hidden = hidden_properties (obj); + + ASSetPropFlags (ob...
2018 May 11
0
Wine release 3.8
...OM aggregation for IWinInetInfo and IWinInetHttpInfo interfaces in BindProtocol. urlmon: Query for IWinInet[Http]Info on BindProtocol instead of protocol handler directly. jscript: Added Object.getOwnPropertyDescriptor implementation. jscript: Use jsdisp_get_own_property in Object.hasOwnProperty implementation. jscript: Use jsdisp_get_own_property in Object.propertyIsEnumerable implementation. jscript: Make String.length non-writable. jscript: Make Function instance object properties non-writable. jscript: Make RegExp object properties non-writable. jscript: A...
2013 Mar 15
0
Wine release 1.5.26
...t of request reading from cache. wininet: Skip test_open_url_async on IEs older than 7. jscript: Use BSTR also for pure IDispatch call in disp_delete_name. jscript: Use BSTR also for pure IDispatch call in disp_get_id. jscript: Use BSTR also for pure IDispatch call in Object.hasOwnProperty. winnt.h: Added GCC variant of DEFAULT_UNREACHABLE macro. vbscript: Use DEFAULT_UNREACHABLE macro where appropriate. jscript: Use DEFAULT_UNREACHABLE macro where appropriate. msctf.idl: Added ITfContextOwnerServices declaration. mshtml.idl: Added IHTMLButtonElement and...
2007 Aug 27
0
8 commits - libswfdec/swfdec_as_boolean.c libswfdec/swfdec_as_interpret.c libswfdec/swfdec_as_number.c libswfdec/swfdec_initialize.as libswfdec/swfdec_initialize.h test/trace vivified/core
...this [""]); +for (i = 0; i < 300; i++) { + name = String.fromCharCode (i); + trace (">>> " + name + " (" + i + ")"); + if (name != "i" && name != "I") { + this[name] = 42; + trace (this[name]); + trace (this.hasOwnProperty (name)); + name = "a" + name; + this[name] = 42; + trace (this[name]); + trace (this.hasOwnProperty (name)); + name = name + "b"; + this[name] = 42; + trace (this[name]); + trace (this.hasOwnProperty (name)); + } +} loadMovie ("FSCommand:quit&quo...