Skip to content
Browse files

Merge pull request #238 from jchavarri/master

Fix issue #236 - `Event.ImageLoaded` event never triggered in FramerJS + Fix issue #219 "PageComponent resets position of layer"
  • Loading branch information
koenbok committed Aug 12, 2015
2 parents d129b20 + da8664d commit daa25a5cdc39aaadc2076f66f08b9108704d1574
Showing with 5 additions and 2 deletions.
  1. +4 −1 framer/Components/
  2. +1 −1 framer/
@@ -98,7 +98,10 @@ class exports.PageComponent extends ScrollComponent
direction = "right"
throw new Error("#{direction} should be in #{directions}")

point = {x:0, y:0}
# For allowing pages added with 'addPage' to behave consistently with pages added
# to the PageComponent using 'superLayer', keep the original page point
# so one of the two coordinates is left untouched after the page is added
point = page.point

if @content.subLayers.length
point.x = Utils.frameGetMaxX(@content.contentFrame()) if direction in ["right", "east"]
@@ -551,7 +551,7 @@ class exports.Layer extends BaseClass

# As an optimization, we will only use a loader
# if something is explicitly listening to the load event
if @events?.hasOwnProperty "load" or @events?.hasOwnProperty "error"
if @_eventListeners?.hasOwnProperty "load" or @_eventListeners?.hasOwnProperty "error"

loader = new Image() = imageUrl

0 comments on commit daa25a5

Please sign in to comment.
You can’t perform that action at this time.