From 7d09706a1440300c8db5007d8d6229cc8be252e1 Mon Sep 17 00:00:00 2001 From: liteng <930372551@qq.com> Date: Fri, 21 Sep 2018 07:46:50 +0800 Subject: [PATCH] =?UTF-8?q?=E6=97=B6=E9=97=B4=E8=BD=B4=E5=A2=9E=E5=8A=A0?= =?UTF-8?q?=E4=BA=8B=E4=BB=B6=E3=80=82?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../src/editor/bottom/AnimationPanel.js | 28 +++++++++++++++++++ 1 file changed, 28 insertions(+) diff --git a/ShadowEditor.Web/src/editor/bottom/AnimationPanel.js b/ShadowEditor.Web/src/editor/bottom/AnimationPanel.js index 52fad767..0fe29409 100644 --- a/ShadowEditor.Web/src/editor/bottom/AnimationPanel.js +++ b/ShadowEditor.Web/src/editor/bottom/AnimationPanel.js @@ -141,6 +141,14 @@ AnimationPanel.prototype.onAppStarted = function () { context.fillText(text, i * scale, 16); } + + var timeline = UI.get('timeline', this.id); + + timeline.dom.addEventListener(`click.${this.id}`, this.onClick.bind(this)); + timeline.dom.addEventListener(`dblclick.${this.id}`, this.onDblClick.bind(this)); + timeline.dom.addEventListener(`mousedown.${this.id}`, this.onMouseDown.bind(this)); + timeline.dom.addEventListener(`mousemove.${this.id}`, this.onMouseMove.bind(this)); + timeline.dom.addEventListener(`mouseup.${this.id}`, this.onMouseUp.bind(this)); }; AnimationPanel.prototype.updateUI = function () { @@ -214,4 +222,24 @@ AnimationPanel.prototype.onStop = function () { this.updateUI(); }; +AnimationPanel.prototype.onClick = function () { + +}; + +AnimationPanel.prototype.onDblClick = function () { + +}; + +AnimationPanel.prototype.onMouseDown = function () { + +}; + +AnimationPanel.prototype.onMouseMove = function () { + +}; + +AnimationPanel.prototype.onMouseUp = function () { + +}; + export default AnimationPanel; \ No newline at end of file