Results 1 to 3 of 3

Thread: body missing from ToolTip

  1. #1

    Default body missing from ToolTip

    I've created a user extension for ToolTip that makes 'delegate' a function...this allows me to ask an embedded document for an object containing information regarding where, when, and with what content to display the tooltip.
    When I attach a listener and try to update the body with this information, it tells me there is no body!!! Of course update fails for the same reason...

    why in the world would body fail to be set???

    Code:
    
    Ext.ux.SVGToolTip = Ext.extend(Ext.ToolTip, {
    onMouseMove :function(e) {
    var t =this.delegate ?this.delegate(replace_e_for_embed(e)) :this.triggerElement =true;
    if (t) {
    this.targetXY = e.getXY();
    if (t.CheckPointEquality(this.triggerElement)) {
    if(!this.hidden &&this.trackMouse){
    this.setPagePosition(this.getTargetXY());
    }
    } else {
    this.hide();
    this.lastActive =new Date(0);
    this.onTargetOver(e);
    }
    } elseif (!this.closable &&this.isVisible()) {
    this.hide();
    }
    }
    , onTargetOver :function(e) {
    if(this.disabled || e.within(this.target.dom,true)){
    return;
    }
    var t =this.delegate ?this.delegate(replace_e_for_embed(e)) : e.getTarget();
    if (t) {
    this.triggerElement = t;
    this.clearTimer('hide');
    this.targetXY = e.getXY();
    this.delayShow();
    }
    }
    });
     
    tooltip =new Ext.ux.SVGToolTip({
    target:'mask'
    , html:'fillerblahblahblahblahblahblahblahblahblahblahblahblah'
    , dismissDelay: 0
    , hideDealy: 0
    , showDelay: 0
    , delegate: svgdoc.GetTargetPoint
    , listeners: {
    beforeshow:function updateTipBody(tip) {
    tip.update(tip.triggerElement.blah);//FAILS!!!!!!!!!!!!!!!!!
    }
    }
    });
    

  2. #2

    Default

    found it....
    renderTo: document.body
    needs to be added to the config so that body is set before the first render.

  3. #3
    Sencha User Animal's Avatar
    Join Date
    Mar 2007
    Location
    Bédoin/Nottingham
    Posts
    30,890

    Default

    Quote Originally Posted by harmomelodic View Post
    I've created a user extension for ToolTip that makes 'delegate' a function...this allows me to ask an embedded document for an object containing information regarding where, when, and with what content to display the tooltip.
    That sounds like my DataTip UX. It can show context-sensitive content on grids, trees, dataviews and forms.

Similar Threads

  1. Tooltip position on body scroll
    By webarts-pl in forum Ext 3.x: Help & Discussion
    Replies: 9
    Last Post: 7 Sep 2010, 4:48 AM
  2. ToolTip autoLoads both body and title
    By ZachG in forum Ext 2.x: Help & Discussion
    Replies: 0
    Last Post: 11 Jun 2009, 12:19 PM
  3. Replies: 1
    Last Post: 20 Aug 2008, 3:38 AM
  4. Do not set body.innerHTML='' if scripts are loaded in body
    By vtswingkid in forum Ext 2.x: Help & Discussion
    Replies: 4
    Last Post: 19 Feb 2007, 12:51 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •