Merge branch 'master' of github.com:locomotivecms/engine

This commit is contained in:
Didier Lafforgue 2012-04-16 12:35:44 +02:00
commit 256a0e4bc0

View File

@ -28,11 +28,11 @@ class Locomotive.Views.InlinEditor.ApplicationView extends Backbone.View
iframe.load =>
if @_$('meta[name=inline-editor]').size() > 0
# bind the resize event. When the iFrame's size changes, update its height
iframe_content = iframe.contents().find('body')
iframe_content = iframe.contents()
iframe_content.resize ->
elem = $(this)
if elem.outerHeight(true) > $('body').outerHeight(true) # Resize the iFrame.
if elem.outerHeight(true) > iframe.outerHeight(true) # Resize the iFrame.
iframe.css height: elem.outerHeight(true)
# Resize the iFrame immediately.