1. #1
    Ext User
    Join Date
    Feb 2008
    Posts
    23
    Vote Rating
    0
    vikky_25 is on a distinguished road

      0  

    Default TriggerField: Icon tooltip

    TriggerField: Icon tooltip


    I would need to set a tooltip for the TriggerField Icon.
    Please suggest me a way if anyone knows how.

    Thanks!

  2. #2
    Sencha - Ext JS Dev Team Animal's Avatar
    Join Date
    Mar 2007
    Location
    Notts/Redwood City
    Posts
    30,546
    Vote Rating
    64
    Animal is a jewel in the rough Animal is a jewel in the rough Animal is a jewel in the rough

      0  

    Default


    Write a plugin for the TriggerField class which attaches a ToolTip to the trigger element.

  3. #3
    Ext User
    Join Date
    Feb 2008
    Posts
    23
    Vote Rating
    0
    vikky_25 is on a distinguished road

      0  

    Default


    I've found the way to add the tooltip text for the trigger icon:

    Code:
     
    var mytriggerField = new Ext.form.TriggerField({
     ...
    });
     
    mytriggerField.on("render", function() {
    Ext.QuickTips.register({
     target: this.trigger,
     title: "Some title",
     text: "Actual tooltip message"
    });
    }, this);

  4. #4
    Sencha User bt_bruno's Avatar
    Join Date
    Mar 2008
    Location
    Redwood City, CA
    Posts
    154
    Vote Rating
    10
    bt_bruno will become famous soon enough

      0  

    Default


    Another one, using triggerConfig

    Code:
    ...{
        xtype:'trigger'
       ,triggerConfig:{
             tag: "img"
             ,src: Ext.BLANK_IMAGE_URL
             ,cls: "x-form-trigger myTriggerClass" 
             ,'ext:qtip':'test'
         }
     }
    ...

Thread Participants: 2