toolbar.html 1.7 KB

12345678910111213141516171819202122232425262728293031323334353637383940
  1. <!DOCTYPE html>
  2. <html>
  3. <head>
  4. <meta charset="UTF-8">
  5. <title>Tooltip as Toolbar - jQuery EasyUI Demo</title>
  6. <link rel="stylesheet" type="text/css" href="../../themes/default/easyui.css">
  7. <link rel="stylesheet" type="text/css" href="../../themes/icon.css">
  8. <link rel="stylesheet" type="text/css" href="../demo.css">
  9. <script type="text/javascript" src="../../jquery.min.js"></script>
  10. <script type="text/javascript" src="../../jquery.easyui.min.js"></script>
  11. </head>
  12. <body>
  13. <h2>Tooltip as Toolbar</h2>
  14. <p>This sample shows how to create a tooltip style toolbar.</p>
  15. <div style="margin:20px 0;"></div>
  16. <div style="padding:10px 200px">
  17. <p><a id="dd" href="javascript:void(0)" class="easyui-tooltip" data-options="
  18. hideEvent: 'none',
  19. content: function(){
  20. return $('#toolbar');
  21. },
  22. onShow: function(){
  23. var t = $(this);
  24. t.tooltip('tip').focus().unbind().bind('blur',function(){
  25. t.tooltip('hide');
  26. });
  27. }
  28. ">Hover me</a> to display toolbar.</p>
  29. </div>
  30. <div style="display:none">
  31. <div id="toolbar">
  32. <a href="#" class="easyui-linkbutton easyui-tooltip" title="Add" data-options="iconCls:'icon-add',plain:true"></a>
  33. <a href="#" class="easyui-linkbutton easyui-tooltip" title="Cut" data-options="iconCls:'icon-cut',plain:true"></a>
  34. <a href="#" class="easyui-linkbutton easyui-tooltip" title="Remove" data-options="iconCls:'icon-remove',plain:true"></a>
  35. <a href="#" class="easyui-linkbutton easyui-tooltip" title="Undo" data-options="iconCls:'icon-undo',plain:true"></a>
  36. <a href="#" class="easyui-linkbutton easyui-tooltip" title="Redo" data-options="iconCls:'icon-redo',plain:true"></a>
  37. </div>
  38. </div>
  39. </body>
  40. </html>