View Full Version : Missing source for adapters in Ext-1.1-rc1
rajeev
07-20-2007, 05:07 PM
I downloaded the latest code for Ext (1.1-rc1) and found that the source files for the adapters (ext-base.js, prototype-bridge.js, jquery-bridge.js, and yui-bridge.js) have missing source code above or near the following code snippet:
function(){
var libFlyweight;
...
I am not sure if this is a bug or an intended feature to make it difficult to debug the Ext code.
mystix
07-20-2007, 05:23 PM
:-/ /:) =;
http://extjs.com/forum/showthread.php?t=8887
rajeev
07-20-2007, 05:56 PM
Ext version + build no.? (1.1-rc1)
ext-base.js / ((yui / prototype / jquery) + build no. + corresponding adapter)? (e.g. yui 2.2.2 + adapter, or jquery 1.1.3.1 + adapter)
windows(xp/vista) / mac / linux? XP
browser + build no.? IE7 7.0.5730.11
code snippet / simple drop-in example / existing example from the demos? see below
FireBug stacktrace / error msg if any? (using ext-all-debug.js, not ext-all.js) n/a
screenshot? (optional - but a picture paints a thousand words ) n/a
For example, if you look at the ext-base.js file under ext-1.1-rc1/source/adapter folder you will find the following content:
/*
* Ext JS Library 1.1 RC 1
* Copyright(c) 2006-2007, Ext JS, LLC.
* licensing@extjs.com
*
* http://www.extjs.com/license
*/
(function() {
var libFlyweight;
Ext.lib.Dom = ...{
Compare this with the ext-base.js under ext-1.1-rc/adapter/ext:
/*
* Ext JS Library 1.1 RC 1
* Copyright(c) 2006-2007, Ext JS, LLC.
* licensing@extjs.com
*
* http://www.extjs.com/license
*/
Ext={};window["undefined"]=window["undefined"];Ext.apply=function(o,c,_3){if(_3){Ext.apply(o,_3) ;}if(o&&c&&typeof c=="object"){for(var p in c){o[p]=c[p];}}return o;};(function(){var _5=0;var ua=navigator.userAgent.toLowerCase();var _7=document.compatMode=="CSS1Compat",_8=ua.indexOf("opera")>-1,_9=(/webkit|khtml/).test(ua),_a=ua.indexOf("msie")>-1,_b=ua.indexOf("msie 7")>-1,_c=!_9&&ua.indexOf("gecko")>-1,_d=_a&&!_7,_e=(ua.indexOf("windows")!=-1||ua.indexOf("win32")!=-1),_f=(ua.indexOf("macintosh")!=-1||ua.indexOf("mac os x")!=-1),_10=(ua.indexOf("linux")!=-1),_11=window.location.href.toLowerCase().indexOf("https")===0;if(_a&&!_b){try{document.execCommand("BackgroundImageCache",false,true);}catch(e){}}Ext.apply(Ext,{isStrict:_ 7,isSecure:_11 ...
Not withstanding that the code is compressed and obfuscated, the difference is quite obvious. The adapter code under source folder is missing the top half of the source where the Ext object is defined.
tryanDLS
07-20-2007, 06:08 PM
It's not a bug. If you look at the ext.jsb file, you will see that the final ext-base.js file is a combination of source\core\ext.js and source\adapter\ext-base.js. This is also the case for the other adapters - ext.js is combined with the appropriate adapter to build the final file. My guess would be that this is done to reduce the number of files that need to be included in the page.
rajeev
07-20-2007, 06:11 PM
Thank you. That clears it up.
mkidder
08-02-2007, 07:26 PM
Just to clarify for anyone else who comes across this thread.
To debug from source files will need:
1) ext-1.1/ext/source/core/ext.js
2) ext-1.1/ext/source/adapter/ext-base.js
3) ext-1.1/ext/ext-all-debug.js
NOTE: ext-base.js in "ext-1.1/ext/adapter/ext-base.js" in minimized version of both ext.js and ext-base.js source files. Personally, I would say change the name of the of the ext-base.js source file to avoid confusion.
BTW - Aptana IDE is doing a really great job of showing the ExtJS library in its Outline View.
jack.slocum
08-02-2007, 11:27 PM
Yes, Aptana made some great strides in that department. They are doing a great job!
vBulletin® v3.6.7, Copyright ©2000-2009, Jelsoft Enterprises Ltd.