OSDN Git Service
(root)
/
pettanr
/
clientJs.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Version 0.6.123, remove xnode._nodeType.
[pettanr/clientJs.git]
/
0.6.x
/
js
/
02_dom
/
05_XNodeAttr.js
diff --git
a/0.6.x/js/02_dom/05_XNodeAttr.js
b/0.6.x/js/02_dom/05_XNodeAttr.js
index
8b1237a
..
cd96a45
100644
(file)
--- a/
0.6.x/js/02_dom/05_XNodeAttr.js
+++ b/
0.6.x/js/02_dom/05_XNodeAttr.js
@@
-101,7
+101,7
@@
function X_Node_Attr_objToAttrText( obj ){
Node.prototype.attr = function( nameOrObj /* v */ ){
\r
var attrs = this._attrs, newAttrs, f, k, elm, v;
\r
\r
Node.prototype.attr = function( nameOrObj /* v */ ){
\r
var attrs = this._attrs, newAttrs, f, k, elm, v;
\r
\r
- if(
this._xnodeType !== 1
) return this;
\r
+ if(
!this._tag
) return this;
\r
\r
if( nameOrObj && X.Type.isObject( nameOrObj ) ){
\r
attrs || ( attrs = this._attrs = {} );
\r
\r
if( nameOrObj && X.Type.isObject( nameOrObj ) ){
\r
attrs || ( attrs = this._attrs = {} );
\r
@@
-113,7
+113,7
@@
Node.prototype.attr = function( nameOrObj /* v */ ){
};
\r
if( f ){
\r
this._attrText = false;
\r
};
\r
if( f ){
\r
this._attrText = false;
\r
- this._
dirty |= X_Node_Dirty.
ATTR;
\r
+ this._
flags |= X_Node_State.DIRTY_
ATTR;
\r
this._root && X_Node_reserveUpdate();
\r
};
\r
return this;
\r
this._root && X_Node_reserveUpdate();
\r
};
\r
return this;
\r
@@
-122,7
+122,7
@@
Node.prototype.attr = function( nameOrObj /* v */ ){
// setter
\r
if( X_Node_Attr_setAttr( this, attrs || ( this._attrs = {} ), this._newAttrs || ( this._newAttrs = {} ), nameOrObj, arguments[ 1 ] ) === true ){
\r
this._attrText = false;
\r
// setter
\r
if( X_Node_Attr_setAttr( this, attrs || ( this._attrs = {} ), this._newAttrs || ( this._newAttrs = {} ), nameOrObj, arguments[ 1 ] ) === true ){
\r
this._attrText = false;
\r
- this._
dirty |= X_Node_Dirty.
ATTR;
\r
+ this._
flags |= X_Node_State.DIRTY_
ATTR;
\r
this._root && X_Node_reserveUpdate();
\r
};
\r
return this;
\r
this._root && X_Node_reserveUpdate();
\r
};
\r
return this;
\r
@@
-141,16
+141,6
@@
Node.prototype.attr = function( nameOrObj /* v */ ){
case 'style' :
\r
case 'cssText' :
\r
return this.cssText();
\r
case 'style' :
\r
case 'cssText' :
\r
return this.cssText();
\r
- case 'text' :
\r
- return this.text();
\r
- case 'html' :
\r
- case 'innerHTML' :
\r
- return this.html();
\r
- case 'outerHTML' :
\r
- X_Node_outerXNode = this;
\r
- v = this.html();
\r
- X_Node_outerXNode = null;
\r
- return v;
\r
\r
case 'selected' :
\r
// kquery.js : safariのバグ対策
\r
\r
case 'selected' :
\r
// kquery.js : safariのバグ対策
\r
@@
-186,7
+176,7
@@
function X_Node_Attr_setAttr( that, attrs, newAttrs, name, v ){
// TODO unique の check
\r
if( v !== that._id ){
\r
that._id = v;
\r
// TODO unique の check
\r
if( v !== that._id ){
\r
that._id = v;
\r
- that._
dirty |= X_Node_Dirty.
ID;
\r
+ that._
flags |= X_Node_State.DIRTY_
ID;
\r
that._root && X_Node_reserveUpdate();
\r
};
\r
return;
\r
that._root && X_Node_reserveUpdate();
\r
};
\r
return;
\r