1. #1
    Sencha User
    Join Date
    Aug 2010
    Posts
    177
    Vote Rating
    0
    mcadirci is on a distinguished road

      0  

    Question ToolTip problem

    ToolTip problem


    Hello,

    I have a tree panel just like in the api example. Have also expand-all collapse-all buttons. But there is a little problem with the tooltips of the buttons.

    Here is my code:
    Code:
    Ext.extend(ApiPanel, Ext.tree.TreePanel, {
    	initComponent: function(){
    		this.hiddenPkgs = [];
    		Ext.apply(this, {
    			tbar:[ ' ',	new Ext.form.TextField({
    				width: 80,
    				emptyText:'<fmt:message key="Plate"></fmt:message>',
    				enableKeyEvents: true,
    				listeners:{
    					render: function(f){
    						this.filter = new Ext.tree.TreeFilter(this, {
    							clearBlank: true,
    							autoClear: true
    						});
    					},
    					keydown: {
    						fn: this.filterTree,
    						buffer: 350,
    						scope: this
    					},
    					scope: this 
    				}
    			}), ' ', ' ','-',
    			{
    				iconCls: 'icon-expand-all',
    				tooltip: '<fmt:message key="ExpandAll"/>',
    				handler: function(){ this.root.expand(true); },
    				scope: this
    			}, '-', {
    				iconCls: 'icon-collapse-all',
    				tooltip: '<fmt:message key="CollapseAll"/>',
    				handler: function(){ this.root.collapse(true); },
    				scope: this
    			}]
    		})
    		ApiPanel.superclass.initComponent.call(this);
    	},
    	filterTree: function(t, e){
    		var text = t.getValue();
    		Ext.each(this.hiddenPkgs, function(n){
    			n.ui.show();
    		});
    		if(!text){
    			this.filter.clear();
    			return;
    		}
    		this.expandAll();
    		var re = new RegExp('^' + Ext.escapeRe(text), 'i');
    		this.filter.filterBy(function(n){
    			if( ! n.isLeaf() ){
    				return true;
    			}
    			return (-1!=n.text.indexOf(text));
    		});
    	}
    });
    I have added the tool tips to the ext-all.css from docs.css
    Code:
    .x-window-dlg .ext-mb-error {
        background-image:url(../images/default/window/icon-error.gif);
    }
    .icon-expand-all {
        background-image: url(../../docs/resources/expand-all.gif) !important;
    }
    .icon-collapse-all {
        background-image: url(../../docs/resources/collapse-all.gif) !important;
    }
    What can be the problem? And is there any quick fixes for this problem? Thanks alot.

    Thanks.

    --
    Mehmet
    Last edited by mcadirci; 13 Sep 2010 at 12:02 AM. Reason: code fix

  2. #2
    Sencha - Ext JS Dev Team Animal's Avatar
    Join Date
    Mar 2007
    Location
    Notts/Redwood City
    Posts
    30,483
    Vote Rating
    35
    Animal has a spectacular aura about Animal has a spectacular aura about

      0  

    Default


    Why indent your code randomly? Can't you see that it makes it almost impossible to rapidly comprehend?

  3. #3
    Sencha User
    Join Date
    Aug 2010
    Posts
    177
    Vote Rating
    0
    mcadirci is on a distinguished road

      0  

    Default


    Hello again,

    I have tried to fix the indentation.

    Thanks.

    --
    Mehmet

  4. #4
    Sencha - Community Support Team Condor's Avatar
    Join Date
    Mar 2007
    Location
    The Netherlands
    Posts
    24,251
    Vote Rating
    73
    Condor is a splendid one to behold Condor is a splendid one to behold Condor is a splendid one to behold Condor is a splendid one to behold Condor is a splendid one to behold Condor is a splendid one to behold Condor is a splendid one to behold Condor is a splendid one to behold

      0  

    Default


    What exactly is the problem with the tooltips?

    Did you call Ext.QuickTips.init() at the start of your Ext.onReady handler?

    ps. I recommend using jsbeautifier.org on your code.

  5. #5
    Sencha User
    Join Date
    Aug 2010
    Posts
    177
    Vote Rating
    0
    mcadirci is on a distinguished road

      0  

    Default


    Hello Condor,

    Thanks alot for the help. This was the problem.

    Thanks alot.

    --
    Mehmet

Similar Threads

  1. Grid Tooltip problem
    By Chods in forum Ext 3.x: Help & Discussion
    Replies: 1
    Last Post: 15 May 2009, 3:08 AM
  2. Hi tooltip problem
    By sseema in forum Ext 2.x: Help & Discussion
    Replies: 1
    Last Post: 3 Dec 2008, 5:55 AM
  3. ToolTip trackMouse problem
    By radtad in forum Ext 2.x: Help & Discussion
    Replies: 0
    Last Post: 30 Sep 2008, 3:52 PM
  4. ToolTip Problem
    By Trollo in forum Ext GWT: Help & Discussion (1.x)
    Replies: 2
    Last Post: 26 Aug 2008, 5:50 AM

Thread Participants: 2

film izle

hd film izle

film sitesi

takipci kazanma sitesi

takipci kazanma sitesi

güzel olan herşey

takipci alma sitesi

komik eğlenceli videolar