File tree Expand file tree Collapse file tree 1 file changed +14
-4
lines changed
lib/web/mage/adminhtml/wysiwyg/tiny_mce Expand file tree Collapse file tree 1 file changed +14
-4
lines changed Original file line number Diff line number Diff line change @@ -238,10 +238,18 @@ define([
238
238
* @param {Object } o
239
239
*/
240
240
openFileBrowser : function ( o ) {
241
- var typeTitle ,
242
- storeId = this . config [ 'store_id' ] !== null ? this . config [ 'store_id' ] : 0 ,
243
- frameDialog = jQuery ( o . win . frameElement ) . parents ( '[role="dialog"]' ) ,
244
- wUrl = this . config [ 'files_browser_window_url' ] +
241
+ var targetElementID = tinyMCE . activeEditor . getElement ( ) . getAttribute ( 'id' ) ,
242
+ originId = this . id ,
243
+ typeTitle ,
244
+ storeId ,
245
+ frameDialog ,
246
+ wUrl ;
247
+
248
+ this . initialize ( targetElementID , this . config ) ;
249
+
250
+ storeId = this . config [ 'store_id' ] !== null ? this . config [ 'store_id' ] : 0 ;
251
+ frameDialog = jQuery ( o . win . frameElement ) . parents ( '[role="dialog"]' ) ;
252
+ wUrl = this . config [ 'files_browser_window_url' ] +
245
253
'target_element_id/' + this . id + '/' +
246
254
'store/' + storeId + '/' ;
247
255
@@ -255,6 +263,8 @@ define([
255
263
typeTitle = this . translate ( 'Insert File...' ) ;
256
264
}
257
265
266
+ this . initialize ( originId , this . config ) ;
267
+
258
268
frameDialog . hide ( ) ;
259
269
jQuery ( '#mceModalBlocker' ) . hide ( ) ;
260
270
You can’t perform that action at this time.
0 commit comments