X-Git-Url: http://git.ithinksw.org/extjs.git/blobdiff_plain/530ef4b6c5b943cfa68b779d11cf7de29aa878bf..6b044c28b5f26fb99c86c237ffad19741c0f7f3d:/docs/source/QuickTips.html?ds=inline diff --git a/docs/source/QuickTips.html b/docs/source/QuickTips.html index ae384600..9ae9b694 100644 --- a/docs/source/QuickTips.html +++ b/docs/source/QuickTips.html @@ -7,10 +7,10 @@
/*!
- * Ext JS Library 3.2.1
- * Copyright(c) 2006-2010 Ext JS, Inc.
- * licensing@extjs.com
- * http://www.extjs.com/license
+ * Ext JS Library 3.3.1
+ * Copyright(c) 2006-2010 Sencha Inc.
+ * licensing@sencha.com
+ * http://www.sencha.com/license
  */
 
/** * @class Ext.QuickTips @@ -25,7 +25,7 @@ * configuration properties of Ext.QuickTip. These settings will apply to all * tooltips shown by the singleton.

*

Below is the summary of the configuration properties which can be used. - * For detailed descriptions see {@link #getQuickTip}

+ * For detailed descriptions see the config options for the {@link Ext.QuickTip QuickTip} class

*

QuickTips singleton configs (all are optional)

*
*

To register a quick tip in markup, you simply add one or more of the valid QuickTip attributes prefixed with @@ -81,7 +81,9 @@ Ext.QuickTips.register({ * @singleton */ Ext.QuickTips = function(){ - var tip, locks = []; + var tip, + disabled = false; + return {

/** * Initialize the global QuickTips instance and prepare any quick tips. @@ -95,23 +97,40 @@ Ext.QuickTips = function(){ }); return; } - tip = new Ext.QuickTip({elements:'header,body'}); + tip = new Ext.QuickTip({ + elements:'header,body', + disabled: disabled + }); if(autoRender !== false){ tip.render(Ext.getBody()); } } }, + + // Protected method called by the dd classes + ddDisable : function(){ + // don't disable it if we don't need to + if(tip && !disabled){ + tip.disable(); + } + }, + + // Protected method called by the dd classes + ddEnable : function(){ + // only enable it if it hasn't been disabled + if(tip && !disabled){ + tip.enable(); + } + },
/** * Enable quick tips globally. */ enable : function(){ if(tip){ - locks.pop(); - if(locks.length < 1){ - tip.enable(); - } + tip.enable(); } + disabled = false; },
/** @@ -121,7 +140,7 @@ Ext.QuickTips = function(){ if(tip){ tip.disable(); } - locks.push(1); + disabled = true; },
/** @@ -133,7 +152,8 @@ Ext.QuickTips = function(){ },
/** - * Gets the global QuickTips instance. + * Gets the single {@link Ext.QuickTip QuickTip} instance used to show tips from all registered elements. + * @return {Ext.QuickTip} */ getQuickTip : function(){ return tip; @@ -160,10 +180,10 @@ Ext.QuickTips = function(){ * Alias of {@link #register}. * @param {Object} config The config object */ - tips :function(){ + tips : function(){ tip.register.apply(tip, arguments); } - } + }; }(); \ No newline at end of file