锘??xml version="1.0" encoding="utf-8" standalone="yes"?>成人97人人超碰人人99,国内精品免费,国产精品一区二http://www.aygfsteel.com/alter/category/51333.html緹庢弧 嬋鎯?閱囧帤zh-cnSat, 07 Apr 2012 16:19:33 GMTSat, 07 Apr 2012 16:19:33 GMT60Extjs4鐗規т粙緇嶄簩http://www.aygfsteel.com/alter/articles/373464.htmla_altera_alterFri, 06 Apr 2012 06:32:00 GMThttp://www.aygfsteel.com/alter/articles/373464.html

Mixins

瀹樻柟鏂囨。浠嬬粛

This is a new approach to plugging custom functionality into existing classes. The new mixins config, included during instantiation of a class, allows you to "mix in" new capabilities to the class prototype. This is similar to the existing Ext.override function, although it does not replace existing methods like override does, it simply augments the prototype with whatever is new.       

 == java override 錛?涓嶈繃鏀寔澶氱戶鎵褲?鐩稿悓鏂規硶鍙栨渶鍚庡疄鐜般?br />

Statics

闈欐佸瓧孌靛拰鏂規硶瀹氫箟鍧椼?br />
Ext.define('Person',{
   statics:{
      staticAttribute:'闈欐佸彉閲?錛?br />      staticFunction:
function(){
        
// 闈欐佹柟娉?/span>
      }
   }
});

alert(Person.staticAttribute);

Config

榪欎釜鐞嗚В涓?java 鐨刾ojo涓殑鍙橀噺錛?鍙互鑷姩鐢熸垚浠ヤ笅鏂規硶錛?浠ヤ笅浠g爜鎽樺畼鏂規枃妗c?br />
usage
Ext.define('MyClass', {
    config: {
        title: 'Default Title'
    }
});
鑷姩鐢熸垚浠ヤ笅浠g爜
title: 'Default Title',

getTitle: 
function() {
    
return this.title;
},

resetTitle: 
function() {
    
this.setTitle('Default Title');
},

setTitle: 
function(newTitle) {
   
this.title = this.applyTitle(newTitle) || newTitle;
},

applyTitle: 
function(newTitle) {
    
// custom code here
    // e.g. Ext.get('titleEl').update(newTitle);
}

媯嫻嬬敤鎴風殑浣跨敤鐜  鐩稿叧瑙丄PI鏂囨。
  • Ext.env.Browser
  • Ext.env.FeatureDetector
  • Ext.env.OS





a_alter 2012-04-06 14:32 鍙戣〃璇勮
]]>
ExtJS4 -- 鍔ㄦ佸姞杞?/title><link>http://www.aygfsteel.com/alter/articles/373459.html</link><dc:creator>a_alter</dc:creator><author>a_alter</author><pubDate>Fri, 06 Apr 2012 05:25:00 GMT</pubDate><guid>http://www.aygfsteel.com/alter/articles/373459.html</guid><description><![CDATA[<h4> ExtJS4  鏂扮壒鎬?/h4> <p> </p><div> <ul> <li id="ext-gen1354">Ext.define to create class definitions within the new system</li> <li id="ext-gen1349">Automatic dependency management and dynamic class loading</li> <li id="ext-gen1353">Mixins</li> <li id="ext-gen1350">Statics</li> <li id="ext-gen1352">New config option for Automatic setter / getter generation</li> </ul> <p> </p><div> <div> <h3> Library Inclusion methods</h3> <p id="ext-gen1530">When you unzip the Ext JS 4 download, you will see the following files:</p> <ol> <li> <p id="ext-gen1526"><code id="ext-gen1534">ext-debug.js</code> - This file is only for use during development. It provides the minimum number of core Ext JS classes needed to get up and running. Any additional classes should be dynamically loaded as separate files as demonstrated above.</p> </li> <li> <p id="ext-gen1527"><code>ext.js</code> - same as <code id="ext-gen1529">ext-debug.js</code> but minified for use in production. Meant to be used in combination with your application's <code>app-all.js</code> file. (see section <em>3</em>)</p> </li> <li> <p id="ext-gen1528"><code>ext-all-debug.js</code> - This file contains the entire Ext JS library. This can be helpful for shortening your initial learning curve, however <code>ext-debug.js</code> is preferred in most cases for actual application development.</p> </li> <li> <p id="ext-gen1531"><code>ext-all.js</code> - This is a minified version of <code id="ext-gen1533">ext-all-debug.js</code> that can be used in production environments, however, it is not recommended since most applications will not make use of all the classes that it contains. Instead it is recommended that you create a custom build for your production environment as described in section <em>3</em>.</p></li> </ol><p><span style="background-color: #ffffff; color: #0099cc;">浜嗚В涓嶅悓js鐨勪嬌鐢ㄥ畾浣?/span><span style="color: #99cc00; background-color: #ffffff;"></span><br /></p> </div> </div> <div> <h4>Class Loading</h4> </div><div>Ext 4 now includes a robust dynamic class loading system that also provides integrated dependency management. Again, this is an optional feature, but provides a couple of key benefits:</div> <p> </p><div> <ul> <li> <p id="ext-gen1367"><strong id="ext-gen1383">Dynamic loading</strong>: Classes can be loaded dynamically and asynchronously at runtime simply based on the dependency tree that Ext manages internally. This means that you can stop managing brittle blocks of manual include tags in HTML pages and simply let the class loader figure out what your page needs to run. This is mostly useful in the development environment when dependency flexibility is more important than page load speed.</p> </li> <li> <p id="ext-gen1368"><strong id="ext-gen1382">Dynamic build generation</strong>: For production, it's usually preferable still to compile down to a single (or few) build files. Since Ext now understands the entire dependency graph at runtime, it can easily output that graph as needed (for example, in the form of a custom build configuration). And even more importantly, this capability is not restricted to the Ext namespace. You can include any number of custom classes and namespaces in addition to Ext and as long as everything is defined using the class system Ext will be able to figure out how they all relate. In the very near future, any Ext developer will have one-click custom build capability that automatically manages the entire Ext + custom application class graph, even as it changes from one minute to the next, and only builds <em id="ext-gen1384">exactly</em> what's actually needed by the app.</p> </li> </ul> <p> </p><div> <p id="ext-gen1369">This dynamic loading is enabled simply by using Ext.define and by defining the dependencies in code using two <span style="color: #0099cc;">new class properties:</span></p> <ul> <li id="ext-gen1381"><span style="color: #0099cc;">requires:</span> The class dependencies required for a class to work. These are guaranteed to be loaded <span style="color: #0099cc;">prior to </span>the current class being instantiated.</li> <li id="ext-gen1372"><span style="color: #0099cc;">uses</span>: Optional class dependencies that are used by, but not required by, a class. These can be loaded <span style="color: #0099cc;">asynchronously </span>and <span style="color: #0099cc;">do not have to be available</span> for the class to be instantiated.</li> </ul> <p><span style="color: red;">絎竴縐嶆柟寮?/span><br /> </p> <div style="background-color:#eeeeee;font-size:13px;border:1px solid #CCCCCC;padding-right: 5px;padding-bottom: 4px;padding-left: 4px;padding-top: 4px;width: 98%;word-break:break-all"><!--<br /> <br /> Code highlighting produced by Actipro CodeHighlighter (freeware)<br /> http://www.CodeHighlighter.com/<br /> <br /> --><span style="color: #000000; ">        Ext.require([<br />             </span><span style="color: #000000; ">'</span><span style="color: #000000; ">Ext.grid.*</span><span style="color: #000000; ">'</span><span style="color: #000000; ">,<br />             </span><span style="color: #000000; ">'</span><span style="color: #000000; ">Ext.data.*</span><span style="color: #000000; ">'</span><span style="color: #000000; ">,<br />             </span><span style="color: #000000; ">'</span><span style="color: #000000; ">Ext.util.*</span><span style="color: #000000; ">'</span><span style="color: #000000; ">,</span><span style="color: #000000; "><br />       </span><span style="color: #000000; ">  ]);</span></div> </div> <p> </p> <p><span style="color: red;">絎簩縐嶆柟寮?/span></p> <div style="background-color:#eeeeee;font-size:13px;border:1px solid #CCCCCC;padding-right: 5px;padding-bottom: 4px;padding-left: 4px;padding-top: 4px;width: 98%;word-break:break-all"><!--<br /><br />Code highlighting produced by Actipro CodeHighlighter (freeware)<br />http://www.CodeHighlighter.com/<br /><br />--><span style="color: #000000; ">Ext.define(</span><span style="color: #000000; ">'</span><span style="color: #000000; ">Ext.window.Window</span><span style="color: #000000; ">'</span><span style="color: #000000; ">, {<br />    extend: </span><span style="color: #000000; ">'</span><span style="color: #000000; ">Ext.panel.Panel</span><span style="color: #000000; ">'</span><span style="color: #000000; ">,<br /><br />    alternateClassName: </span><span style="color: #000000; ">'</span><span style="color: #000000; ">Ext.Window</span><span style="color: #000000; ">'</span><span style="color: #000000; ">,<br /><br />    requires: [</span><span style="color: #000000; ">'</span><span style="color: #000000; ">Ext.util.ComponentDragger</span><span style="color: #000000; ">'</span><span style="color: #000000; ">, </span><span style="color: #000000; ">'</span><span style="color: #000000; ">Ext.util.Region</span><span style="color: #000000; ">'</span><span style="color: #000000; ">, </span><span style="color: #000000; ">'</span><span style="color: #000000; ">Ext.EventManager</span><span style="color: #000000; ">'</span><span style="color: #000000; ">],<br /><br /><img src="http://www.aygfsteel.com/Images/dot.gif" alt="" /><img src="http://www.aygfsteel.com/Images/dot.gif" alt="" /><img src="http://www.aygfsteel.com/Images/dot.gif" alt="" /><br /><br />});</span></div><p> </p> <p><br /> </p> </div> <p> </p> <p><br /> </p> <p><br /> </p> </div> <br /> <p> </p><img src ="http://www.aygfsteel.com/alter/aggbug/373459.html" width = "1" height = "1" /><br><br><div align=right><a style="text-decoration:none;" href="http://www.aygfsteel.com/alter/" target="_blank">a_alter</a> 2012-04-06 13:25 <a href="http://www.aygfsteel.com/alter/articles/373459.html#Feedback" target="_blank" style="text-decoration:none;">鍙戣〃璇勮</a></div>]]></description></item></channel></rss> <footer> <div class="friendship-link"> <a href="http://www.aygfsteel.com/" title="狠狠久久亚洲欧美专区_中文字幕亚洲综合久久202_国产精品亚洲第五区在线_日本免费网站视频">狠狠久久亚洲欧美专区_中文字幕亚洲综合久久202_国产精品亚洲第五区在线_日本免费网站视频</a> </div> </footer> 主站蜘蛛池模板: <a href="http://" target="_blank">安仁县</a>| <a href="http://" target="_blank">镇巴县</a>| <a href="http://" target="_blank">东台市</a>| <a href="http://" target="_blank">澄迈县</a>| <a href="http://" target="_blank">罗定市</a>| <a href="http://" target="_blank">友谊县</a>| <a href="http://" target="_blank">洱源县</a>| <a href="http://" target="_blank">黄大仙区</a>| <a href="http://" target="_blank">独山县</a>| <a href="http://" target="_blank">青阳县</a>| <a href="http://" target="_blank">柳江县</a>| <a href="http://" target="_blank">莫力</a>| <a href="http://" target="_blank">新竹县</a>| <a href="http://" target="_blank">扎赉特旗</a>| <a href="http://" target="_blank">淳安县</a>| <a href="http://" target="_blank">西峡县</a>| <a href="http://" target="_blank">铅山县</a>| <a href="http://" target="_blank">吴江市</a>| <a href="http://" target="_blank">长海县</a>| <a href="http://" target="_blank">郎溪县</a>| <a href="http://" target="_blank">大安市</a>| <a href="http://" target="_blank">庆安县</a>| <a href="http://" target="_blank">应用必备</a>| <a href="http://" target="_blank">托里县</a>| <a href="http://" target="_blank">电白县</a>| <a href="http://" target="_blank">鄂尔多斯市</a>| <a href="http://" target="_blank">陆丰市</a>| <a href="http://" target="_blank">娄烦县</a>| <a href="http://" target="_blank">林芝县</a>| <a href="http://" target="_blank">婺源县</a>| <a href="http://" target="_blank">大洼县</a>| <a href="http://" target="_blank">天水市</a>| <a href="http://" target="_blank">攀枝花市</a>| <a href="http://" target="_blank">启东市</a>| <a href="http://" target="_blank">璧山县</a>| <a href="http://" target="_blank">古交市</a>| <a href="http://" target="_blank">无棣县</a>| <a href="http://" target="_blank">松桃</a>| <a href="http://" target="_blank">天长市</a>| <a href="http://" target="_blank">乐至县</a>| <a href="http://" target="_blank">雷波县</a>| <script> (function(){ var bp = document.createElement('script'); var curProtocol = window.location.protocol.split(':')[0]; if (curProtocol === 'https') { bp.src = 'https://zz.bdstatic.com/linksubmit/push.js'; } else { bp.src = 'http://push.zhanzhang.baidu.com/push.js'; } var s = document.getElementsByTagName("script")[0]; s.parentNode.insertBefore(bp, s); })(); </script> </body>