12、Extjs添加悬浮框

来源:互联网 发布:软件买卖合同模板 编辑:程序博客网 时间:2024/06/04 19:57

Ext.tip.QuickTipManager.init();//初始化tips

// 设置悬浮框的大小和延迟时间      Ext.apply(Ext.tip.QuickTipManager.getQuickTip(), {          maxWidth: 200,          minWidth: 100,          showDelay: 50      // Show 50ms after entering target      });
// Create a small panel to add a quick tip to      Ext.create('Ext.container.Container', {          id: 'quickTipContainer',//定义容器,为其添加提示框          width: 200,          height: 150,          style: {              backgroundColor:'#000000'         },          renderTo: Ext.getBody()      });
// 注册悬浮提示      Ext.tip.QuickTipManager.register({          target: 'quickTipContainer',//提示对象的id          title: 'My Tooltip',          text: 'This tooltip was added in code',          width: 100,          dismissDelay: 1000 // 悬浮提示的时间      });
0 0