javascript - display row tooltip on condtion base on row mouse hover -
i using code in grid render event display tpl on row mouse hover
grid.tip = new ext.tooltip({ view: grid.getview(), target: grid.getview().mainbody, delegate: '.x-grid3-row', trackmouse: true, renderto: ext.getbody(), showdelay: 1000, listeners: { beforeshow: function updatetipbody(tip) { var = grid.getview().findrowindex(tip.triggerelement); var viewobj = grid.getstore().getat(i); var namevar, addressvar, salesorgvar; if (viewobj.get('error_message') != null && (viewobj.get('error_message')).length > 1) { console.log("done.."); namevar = (viewobj.get('error_message') != null && viewobj.get('error_message') != "") ? (ext.bundle.getmsg('posfileswidget.errorfoldergrid.errorfolder.label') + " : " + viewobj.get('error_message')) : ""; tip.update(namevar); } else { tip.setsize(0, 0); tip.setvisible(false); console.log("1.."); } } } });
but when message not come display me blank tpl, not want show tooltip please see image
this extjs bug. have call
tooltip.render(ext.getbody());
at begin of app. , in listener
return false;
when don't want show tooltip.
Comments
Post a Comment