Home | History | Annotate | Download | only in elements

Lines Matching refs:element

38     this.element.classList.add("spectrum-container");
39 this.element.tabIndex = 0;
41 var topElement = this.element.createChild("div", "spectrum-top");
51 var rangeContainer = this.element.createChild("div", "spectrum-range-container");
66 var displayContainer = this.element.createChild("div");
74 * @param {!Element} element
79 function hueDrag(element, dragX, dragY)
97 * @param {!Element} element
103 function colorDrag(element, dragX, dragY, event)
134 * @param {!Element} element
135 * @param {function(!Element, number, number, !MouseEvent)=} onmove
136 * @param {function(!Element, !MouseEvent)=} onstart
137 * @param {function(!Element, !MouseEvent)=} onstop
139 WebInspector.Spectrum.draggable = function(element, onmove, onstart, onstop) {
166 onmove(element, dragX, dragY, /** @type {!MouseEvent} */ (e));
181 onstart(element, mouseEvent);
184 maxHeight = element.clientHeight;
185 maxWidth = element.clientWidth;
187 scrollOffset = element.scrollOffset();
188 offset = element.totalOffset();
212 onstop(element, /** @type {!MouseEvent} */ (e));
218 element.addEventListener("mousedown", start, false);
327 this._spectrum.element.addEventListener("keydown", this._onKeyDown.bind(this), false);
331 this._popover.element.addEventListener("mousedown", consumeEvent, false);
352 toggle: function(element, color, format)
357 this.show(element, color, format);
365 show: function(element, color, format)
368 if (this._anchorElement === element)
371 // Reopen the picker for another anchor element.
375 this._anchorElement = element;
379 this.reposition(element);
386 reposition: function(element)
390 this._popover.showView(this._spectrum, element);
391 WebInspector.setCurrentFocusElement(this._spectrum.element);
436 this.element = document.createElement("span");
437 this._swatchInnerElement = this.element.createChild("span", "swatch-inner");
439 this.element.title = readOnly ? shiftClickMessage : String.sprintf("%s\n%s", WebInspector.UIString("Click to open a colorpicker."), shiftClickMessage);
440 this.element.className = "swatch";
441 this.element.addEventListener("mousedown", consumeEvent, false);
442 this.element.addEventListener("dblclick", consumeEvent, false);