mirror of
https://github.com/scratchfoundation/paper.js.git
synced 2025-08-28 22:08:54 -04:00
Rename Event -> DomEvent and Element -> DomElement, to be more specific and not clash with other classes, e.g. a future base class for ToolEvent and KeyEvent.
This commit is contained in:
parent
0e37f86156
commit
926fffee4a
12 changed files with 32 additions and 33 deletions
|
@ -44,7 +44,7 @@
|
|||
}
|
||||
|
||||
// Reposition the paths whenever the window is resized:
|
||||
Event.add(window, {
|
||||
DomEvent.add(window, {
|
||||
resize: function(event) {
|
||||
document.activeLayer.position = document.bounds.center;
|
||||
}
|
||||
|
|
|
@ -11,7 +11,7 @@
|
|||
// http://processing.org/learning/topics/flocking.html
|
||||
|
||||
// Reposition the heart path whenever the window is resized:
|
||||
Event.add(window, {
|
||||
DomEvent.add(window, {
|
||||
resize: function(event) {
|
||||
size = document.size;
|
||||
heartPath.position = document.bounds.center;
|
||||
|
|
|
@ -64,7 +64,7 @@
|
|||
gradientColor.hilite = mouseDown ? point : point + vector;
|
||||
}
|
||||
|
||||
Event.add(window, {
|
||||
DomEvent.add(window, {
|
||||
resize: function(event) {
|
||||
point = new Point(document.size) / 2;
|
||||
path.bounds = document.bounds;
|
||||
|
|
|
@ -59,7 +59,7 @@
|
|||
}
|
||||
|
||||
// Reposition the path whenever the window is resized:
|
||||
Event.add(window, {
|
||||
DomEvent.add(window, {
|
||||
resize: function(event) {
|
||||
initializePath();
|
||||
onFrame();
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue