mirror of
https://github.com/scratchfoundation/paper.js.git
synced 2025-01-05 20:32:00 -05:00
Improve documentation.
This commit is contained in:
parent
734cc1cc61
commit
1046e440e8
5 changed files with 19 additions and 7 deletions
|
@ -14,6 +14,10 @@
|
|||
* All rights reserved.
|
||||
*/
|
||||
|
||||
/**
|
||||
* @name Component
|
||||
* @class
|
||||
*/
|
||||
var Component = this.Component = Base.extend(Callback, /** @lends Component# */{
|
||||
_events: [ 'onChange', 'onClick' ],
|
||||
|
||||
|
|
|
@ -17,10 +17,10 @@
|
|||
/**
|
||||
* @name KeyEvent
|
||||
*
|
||||
* @class KeyEvent The KeyEvent object is received by the {@link Tool}'s
|
||||
* keyboard handlers {@link Tool#onKeyDown}, {@link Tool#onKeyUp},
|
||||
* The KeyEvent object is the only parameter passed to these functions
|
||||
* and contains information about the keyboard event.
|
||||
* @class The KeyEvent object is received by the {@link Tool}'s keyboard
|
||||
* handlers {@link Tool#onKeyDown}, {@link Tool#onKeyUp}. The KeyEvent object is
|
||||
* the only parameter passed to these functions and contains information about
|
||||
* the keyboard event.
|
||||
*
|
||||
* @extends Event
|
||||
*/
|
||||
|
|
|
@ -17,8 +17,8 @@
|
|||
/**
|
||||
* @name MouseEvent
|
||||
*
|
||||
* @class MouseEvent The MouseEvent object is received by the {@link Item}'s
|
||||
* mouse event handlers {@link Item#onMouseDown}, {@link Item#onMouseDrag},
|
||||
* @class The MouseEvent object is received by the {@link Item}'s mouse event
|
||||
* handlers {@link Item#onMouseDown}, {@link Item#onMouseDrag},
|
||||
* {@link Item#onMouseMove}, {@link Item#onMouseUp}, {@link Item#onClick},
|
||||
* {@link Item#onDoubleClick}, {@link Item#onMouseEnter} and
|
||||
* {@link Item#onMouseLeave}. The MouseEvent object is the only parameter passed
|
||||
|
|
|
@ -14,6 +14,10 @@
|
|||
* All rights reserved.
|
||||
*/
|
||||
|
||||
/**
|
||||
* @name Palette
|
||||
* @class
|
||||
*/
|
||||
var Palette = this.Palette = Base.extend(Callback, /** @lends Palette# */{
|
||||
_events: [ 'onChange' ],
|
||||
|
||||
|
@ -63,6 +67,10 @@ var Palette = this.Palette = Base.extend(Callback, /** @lends Palette# */{
|
|||
paper.palettes.push(this);
|
||||
},
|
||||
|
||||
/**
|
||||
* Resets the values of the components to their
|
||||
* {@link Component#defaultValue}.
|
||||
*/
|
||||
reset: function() {
|
||||
for (var i in this._components)
|
||||
this._components[i].reset();
|
||||
|
|
|
@ -17,7 +17,7 @@
|
|||
/**
|
||||
* @name View
|
||||
*
|
||||
* @class The View object wraps an html element and handles drawing and user
|
||||
* @class The View object wraps an HTML element and handles drawing and user
|
||||
* interaction through mouse and keyboard for it. It offer means to scroll the
|
||||
* view, find the currently visible bounds in project coordinates, or the
|
||||
* center, both useful for constructing artwork that should appear centered on
|
||||
|
|
Loading…
Reference in a new issue