diff --git a/app/assets/javascripts/aloha/plugins/custom/locomotive_media/lib/locomotive_media-plugin.js b/app/assets/javascripts/aloha/plugins/custom/locomotive_media/lib/locomotive_media-plugin.js index 0edfc470..5c98eb33 100644 --- a/app/assets/javascripts/aloha/plugins/custom/locomotive_media/lib/locomotive_media-plugin.js +++ b/app/assets/javascripts/aloha/plugins/custom/locomotive_media/lib/locomotive_media-plugin.js @@ -25,7 +25,7 @@ define( picker.close(); } - picker.render() + picker.fetch_assets(); }, /** diff --git a/app/assets/javascripts/locomotive/views/inline_editor/application_view.js.coffee b/app/assets/javascripts/locomotive/views/inline_editor/application_view.js.coffee index 2e3cb346..cf50a063 100644 --- a/app/assets/javascripts/locomotive/views/inline_editor/application_view.js.coffee +++ b/app/assets/javascripts/locomotive/views/inline_editor/application_view.js.coffee @@ -24,6 +24,8 @@ class Locomotive.Views.InlineEditor.ApplicationView extends Backbone.View @toolbar_view.render() + @content_assets_picker_view.render() + enable_iframe_autoheight: -> iframe = @iframe @@ -89,6 +91,13 @@ class Locomotive.Views.InlineEditor.ApplicationView extends Backbone.View toolbar_view.show_status 'loading' window.history.pushState('Object', 'Title', link.attr('href').replace('_edit', '_admin')) + unique_dialog_zindex: -> + # returns the number of jQuery UI modals created in order to set a valid zIndex for each of them. + # Each modal window should have a different zIndex, otherwise there will be conflicts between them. + window.Locomotive.jQueryModals ||= 0 + + 1050 + window.Locomotive.jQueryModals++ + _$: (selector) -> $(selector, @iframe[0].contentWindow.document)