Skip to content

Commit efdc86a

Browse files
author
Jose Antonio Andújar Clavell
committed
issue cocos2d#1565 bug in CCSAXParser.js
1 parent 144b627 commit efdc86a

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

cocos2d/core/platform/CCSAXParser.js

+3-3
Original file line numberDiff line numberDiff line change
@@ -173,7 +173,7 @@ cc.SAXParser = cc.Class.extend(/** @lends cc.SAXParser# */{
173173
* @param {String} filePath
174174
*/
175175
preloadPlist: function (filePath, selector, target) {
176-
filePath = cc.FileUtils.getInstance().fullPathForFilename(filePath);
176+
var fullfilePath = cc.FileUtils.getInstance().fullPathForFilename(filePath);
177177

178178
if (window.XMLHttpRequest) {
179179
var xmlhttp = new XMLHttpRequest();
@@ -187,15 +187,15 @@ cc.SAXParser = cc.Class.extend(/** @lends cc.SAXParser# */{
187187
if (xmlhttp.readyState == 4) {
188188
if (xmlhttp.responseText) {
189189
cc.doCallback(selector, target);
190-
that._xmlDict[filePath] = xmlhttp.responseText;
190+
that._xmlDict[fullfilePath] = xmlhttp.responseText;
191191
xmlhttp = null;
192192
} else {
193193
cc.doCallback(selector, target, filePath);
194194
}
195195
}
196196
};
197197
// load xml
198-
xmlhttp.open("GET", filePath, true);
198+
xmlhttp.open("GET", fullfilePath, true);
199199
xmlhttp.send(null);
200200
} else
201201
throw "cocos2d:Your browser does not support XMLHTTP.";

0 commit comments

Comments
 (0)