summaryrefslogtreecommitdiff
path: root/public/assets/javascripts/rectangles/models/wall.js
diff options
context:
space:
mode:
Diffstat (limited to 'public/assets/javascripts/rectangles/models/wall.js')
-rw-r--r--public/assets/javascripts/rectangles/models/wall.js9
1 files changed, 7 insertions, 2 deletions
diff --git a/public/assets/javascripts/rectangles/models/wall.js b/public/assets/javascripts/rectangles/models/wall.js
index ce958db..fdc8d8c 100644
--- a/public/assets/javascripts/rectangles/models/wall.js
+++ b/public/assets/javascripts/rectangles/models/wall.js
@@ -53,7 +53,6 @@
/*
mousemove: function(e){
var offset = offsetFromPoint(e, mx.el)
- var shouldFlip = base.side & (RIGHT | FRONT)
if (offset) {
var pos = base.mxOffsetToPosition( offset, index )
@@ -72,9 +71,15 @@
if (Scenery.nextText) {
}
else if (Scenery.nextMedia) {
+ var offset = offsetFromPoint(e, mx.el)
+ if (! offset) { return }
+
+ var pos = base.mxOffsetToPosition( offset, index )
+
var scenery = Scenery.addNextToWall({
wall: base,
- index: index
+ index: index,
+ position: pos,
})
// scenery was not placed