Web UI for ARGUS server
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

90 lines
3.0 KiB

6 years ago
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
  1. <html>
  2. <head>
  3. <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
  4. <title>The source code</title>
  5. <link href="../resources/prettify/prettify.css" type="text/css" rel="stylesheet" />
  6. <script type="text/javascript" src="../resources/prettify/prettify.js"></script>
  7. </head>
  8. <body onload="prettyPrint();">
  9. <pre class="prettyprint lang-js">/*!
  10. * Ext JS Library 3.3.1
  11. * Copyright(c) 2006-2010 Sencha Inc.
  12. * licensing@sencha.com
  13. * http://www.sencha.com/license
  14. */
  15. /*
  16. * @class Ext.calendar.StatusProxy
  17. * A specialized drag proxy that supports a drop status icon, {@link Ext.Layer} styles and auto-repair. It also
  18. * contains a calendar-specific drag status message containing details about the dragged event's target drop date range.
  19. * This is the default drag proxy used by all calendar views.
  20. * @constructor
  21. * @param {Object} config
  22. */
  23. Ext.calendar.StatusProxy = function(config) {
  24. Ext.apply(this, config);
  25. this.id = this.id || Ext.id();
  26. this.el = new Ext.Layer({
  27. dh: {
  28. id: this.id,
  29. cls: 'ext-dd-drag-proxy x-dd-drag-proxy ' + this.dropNotAllowed,
  30. cn: [
  31. {
  32. cls: 'x-dd-drop-icon'
  33. },
  34. {
  35. cls: 'ext-dd-ghost-ct',
  36. cn: [
  37. {
  38. cls: 'x-dd-drag-ghost'
  39. },
  40. {
  41. cls: 'ext-dd-msg'
  42. }
  43. ]
  44. }
  45. ]
  46. },
  47. shadow: !config || config.shadow !== false
  48. });
  49. this.ghost = Ext.get(this.el.dom.childNodes[1].childNodes[0]);
  50. this.message = Ext.get(this.el.dom.childNodes[1].childNodes[1]);
  51. this.dropStatus = this.dropNotAllowed;
  52. };
  53. Ext.extend(Ext.calendar.StatusProxy, Ext.dd.StatusProxy, {
  54. <div id="cfg-Ext.dd.ScrollManager-moveEventCls"></div>/**
  55. * @cfg {String} moveEventCls
  56. * The CSS class to apply to the status element when an event is being dragged (defaults to 'ext-cal-dd-move').
  57. */
  58. moveEventCls: 'ext-cal-dd-move',
  59. <div id="cfg-Ext.dd.ScrollManager-addEventCls"></div>/**
  60. * @cfg {String} addEventCls
  61. * The CSS class to apply to the status element when drop is not allowed (defaults to 'ext-cal-dd-add').
  62. */
  63. addEventCls: 'ext-cal-dd-add',
  64. // inherit docs
  65. update: function(html) {
  66. if (typeof html == 'string') {
  67. this.ghost.update(html);
  68. } else {
  69. this.ghost.update('');
  70. html.style.margin = '0';
  71. this.ghost.dom.appendChild(html);
  72. }
  73. var el = this.ghost.dom.firstChild;
  74. if (el) {
  75. Ext.fly(el).setStyle('float', 'none').setHeight('auto');
  76. Ext.getDom(el).id += '-ddproxy';
  77. }
  78. },
  79. <div id="method-Ext.dd.ScrollManager-updateMsg"></div>/**
  80. * Update the calendar-specific drag status message without altering the ghost element.
  81. * @param {String} msg The new status message
  82. */
  83. updateMsg: function(msg) {
  84. this.message.update(msg);
  85. }
  86. });</pre>
  87. </body>
  88. </html>