1. #41
    Ext Premium Member halcwb's Avatar
    Join Date
    Mar 2010
    Location
    Rotterdam
    Posts
    379
    Vote Rating
    39
    halcwb has a spectacular aura about halcwb has a spectacular aura about

      0  

    Default


    I use the DataTip in a grid view to dynamically show additional information. This information should be shown only at some nodes, so, I look at the DataTip data to determine whether the tip should be shown or not during the beforeshow event. This works fine with the first visible tip, but then afterwards, the data prop of the DataTip is not updated any more. This is due to the following code in DataTip:

    Code:
        function updateTip(tip, data) {
    //     Adding the below line solves the problem
            tip.data = data;
            if (tip.rendered) {
                if (tip.host.fireEvent('beforeshowtip', tip.eventHost, tip, data) === false) {
                    return false;
                }
                tip.update(data);
            } else {
                if (Ext.isString(data)) {
                    tip.html = data;
                } else {
                    tip.data = data;
                }
            }
        }
    The thing I don't get is that if DataTip is not rendered, tip.data is set to an object (if data is not a string). But then afterwards, tip is updated by data, whether or not it is a string, which doesn't seem logical to me. A simple fix is to set data any way. This enables me to look at the data (which is a tree record), load the associated information and update the tip with that data.

    Is this a bug, or am I not using the DataTip in the right way?

  2. #42
    Ext Premium Member halcwb's Avatar
    Join Date
    Mar 2010
    Location
    Rotterdam
    Posts
    379
    Vote Rating
    39
    halcwb has a spectacular aura about halcwb has a spectacular aura about

      0  

    Default


    Quote Originally Posted by halcwb View Post
    I use the DataTip in a grid view to dynamically show additional information. This information should be shown only at some nodes, so, I look at the DataTip data to determine whether the tip should be shown or not during the beforeshow event. This works fine with the first visible tip, but then afterwards, the data prop of the DataTip is not updated any more. This is due to the following code in DataTip:

    Code:
        function updateTip(tip, data) {
    //     Adding the below line solves the problem
            tip.data = data;
            if (tip.rendered) {
                if (tip.host.fireEvent('beforeshowtip', tip.eventHost, tip, data) === false) {
                    return false;
                }
                tip.update(data);
            } else {
                if (Ext.isString(data)) {
                    tip.html = data;
                } else {
                    tip.data = data;
                }
            }
        }
    The thing I don't get is that if DataTip is not rendered, tip.data is set to an object (if data is not a string). But then afterwards, tip is updated by data, whether or not it is a string, which doesn't seem logical to me. A simple fix is to set data any way. This enables me to look at the data (which is a tree record), load the associated information and update the tip with that data.

    Is this a bug, or am I not using the DataTip in the right way?
    Also, how should I override my fixed updateTip, as the original function is not accessible by being a closure?

  3. #43
    Sencha User
    Join Date
    Dec 2008
    Location
    France
    Posts
    244
    Vote Rating
    0
    senacle is on a distinguished road

      0  

    Default


    Quote Originally Posted by senacle View Post
    I upgrade my code from Extjs 3.2.1 to Extjs 3.3.0 and the Datatip doesn't work anymore for combobox.

    There's no error message.
    Some precision : the Datatip is working for the items of the combobox list, but not for the combo itself.

    I've found the reason.
    My combobox has the property hiddenName.
    When the mouse goes on the combobox, the first element read in the DOM is the hidden field with hiddenname.
    And because it's hidden, it can't display tooltip.

    I've found this solution : put a listener in the property of the combobox (http://stackoverflow.com/questions/2...-for-combo-box)
    Code:
        listeners: {
            render: function(c) {
              new Ext.ToolTip({
                target: c.getEl(),
                html: 'Tooltip content'
              });
            }
        },

Turkiyenin en sevilen filmlerinin yer aldigi xnxx internet sitemiz olan ve porn sex tarzi bir site olan mobil porno izle sitemiz gercekten dillere destan bir durumda herkesin sevdigi bir site olarak tarihe gececege benziyor. Sitenin en belirgin ozelliklerinden birisi de Turkiyede gercekten kaliteli ve muntazam, duzenli porno izle siteleri olmamasidir. Bu yuzden iste. Ayrica en net goruntu kalitesine sahip adresinde yayinlanmaktadir. Mesela diğer sitelerimizden bahsedecek olursak, en iyi hd porno video arşivine sahip bir siteyiz. "The Best anal porn videos and slut anus, big asses movies set..." hd porno faketaxi