[Sie-announce] SIEコード [2076] createTextNodeメソッドの引数を自動で文字列型に変換する

Back to archive index

svnno****@sourc***** svnno****@sourc*****
2010年 10月 20日 (水) 21:59:00 JST


Revision: 2076
          http://sourceforge.jp/projects/sie/svn/view?view=rev&revision=2076
Author:   dhrname
Date:     2010-10-20 21:59:00 +0900 (Wed, 20 Oct 2010)

Log Message:
-----------
createTextNodeメソッドの引数を自動で文字列型に変換する

Modified Paths:
--------------
    branches/06x/062/org/w3c/core.js
    branches/06x/sie.js

Modified: branches/06x/062/org/w3c/core.js
===================================================================
--- branches/06x/062/org/w3c/core.js	2010-10-20 12:57:50 UTC (rev 2075)
+++ branches/06x/062/org/w3c/core.js	2010-10-20 12:59:00 UTC (rev 2076)
@@ -372,7 +372,7 @@
  *どんな機能をサポートしているかどうかをチェック
  */
 /*boolean*/ isSupported : function( /*string*/ feature, version) {
-  return (this.ownerDocument.implementation.hasFeature(feature, version));
+  return (this.ownerDocument.implementation.hasFeature(feature+"", version+""));
 },
 /*hasAttributesメソッド
  *ノードが属性を持っているかどうか
@@ -804,8 +804,8 @@
  */
 /*Text*/               Document.prototype.createTextNode = function( /*string*/ data) {
   var s = new Text();
-  s.data = s.nodeValue = data;
-  s.length = data.length;
+  s.data = s.nodeValue = data+"";
+  s.length = (data+"").length;
   s.ownerDocument = this;
   return s;
 };

Modified: branches/06x/sie.js
===================================================================
--- branches/06x/sie.js	2010-10-20 12:57:50 UTC (rev 2075)
+++ branches/06x/sie.js	2010-10-20 12:59:00 UTC (rev 2076)
@@ -804,8 +804,8 @@
  */
 /*Text*/               Document.prototype.createTextNode = function( /*string*/ data) {
   var s = new Text();
-  s.data = s.nodeValue = data;
-  s.length = data.length;
+  s.data = s.nodeValue = data+"";
+  s.length = (data+"").length;
   s.ownerDocument = this;
   return s;
 };




Sie-announce メーリングリストの案内
Back to archive index