Changeset 4477 in subversion
- Timestamp:
- Feb 1, 2011 4:08:17 AM (2 years ago)
- Location:
- trunk/roundcubemail/program/js
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/roundcubemail/program/js/common.js
r4411 r4477 168 168 { 169 169 e = e || window.event; 170 return e && (typeof e.button != 'undefined')? e.button : (e && e.which ? e.which : 0);170 return e && e.button !== undefined ? e.button : (e && e.which ? e.which : 0); 171 171 }, 172 172 … … 319 319 removeEventListener: function(evt, func, obj) 320 320 { 321 if ( typeof obj == 'undefined')321 if (obj === undefined) 322 322 obj = window; 323 323 … … 336 336 { 337 337 var ret, h; 338 if ( typeof e == 'undefined')338 if (e === undefined) 339 339 e = this; 340 else if (typeof e == 'object')340 else if (typeof e === 'object') 341 341 e.event = evt; 342 342 … … 345 345 for (var i=0; i < this._events[evt].length; i++) { 346 346 if ((h = this._events[evt][i])) { 347 if (typeof h.func == 'function')347 if (typeof h.func === 'function') 348 348 ret = h.func.call ? h.func.call(h.obj, e) : h.func(e); 349 else if (typeof h.obj[h.func] == 'function')349 else if (typeof h.obj[h.func] === 'function') 350 350 ret = h.obj[h.func](e); 351 351 352 352 // cancel event execution 353 if ( typeof ret != 'undefined'&& !ret)353 if (ret !== undefined && !ret) 354 354 break; 355 355 } … … 514 514 515 515 for (var key in obj) { 516 if (obj[key] && typeof obj[key] == 'object')516 if (obj[key] && typeof obj[key] === 'object') 517 517 out[key] = clone_object(obj[key]); 518 518 else -
trunk/roundcubemail/program/js/googiespell.js
r4149 r4477 92 92 93 93 this.decorateTextarea = function(id) { 94 this.text_area = typeof (id)== 'string' ? document.getElementById(id) : id;94 this.text_area = typeof id === 'string' ? document.getElementById(id) : id; 95 95 96 96 if (this.text_area) { … … 121 121 ///// 122 122 this.setSpellContainer = function(id) { 123 this.spell_container = typeof (id)== 'string' ? document.getElementById(id) : id;123 this.spell_container = typeof id === 'string' ? document.getElementById(id) : id; 124 124 }; 125 125 … … 932 932 ///// 933 933 this.isDefined = function(o) { 934 return (o != 'undefined' && o != null)934 return (o !== undefined && o !== null) 935 935 }; 936 936 -
trunk/roundcubemail/program/js/list.js
r4411 r4477 59 59 60 60 // overwrite default paramaters 61 if (p && typeof (p)== 'object')61 if (p && typeof p === 'object') 62 62 for (var n in p) 63 63 this[n] = p[n];
Note: See TracChangeset
for help on using the changeset viewer.
