From: <nat...@us...> - 2015-01-21 16:17:27
|
Author: nathangray Date: Wed Jan 21 17:17:19 2015 New Revision: 51340 URL: http://svn.stylite.de/viewvc/egroupware?rev=51340&view=rev Log: Pass event in instead of using window.event, fixes exposé initialization to selected image in firefox Modified: trunk/etemplate/js/expose.js Modified: trunk/etemplate/js/expose.js URL: http://svn.stylite.de/viewvc/egroupware/trunk/etemplate/js/expose.js?rev=51340&r1=51339&r2=51340&view=diff ============================================================================== --- trunk/etemplate/js/expose.js (original) +++ trunk/etemplate/js/expose.js Wed Jan 21 17:17:19 2015 @@ -296,13 +296,13 @@ } if (typeof this.options.expose_view != 'undefined' && this.options.expose_view ) { - jQuery(this.node).on('click', function(){ - self._init_blueimp_gallery(_value); + jQuery(this.node).on('click', function(event){ + self._init_blueimp_gallery(event, _value); }).addClass('et2_clickable'); } }, - _init_blueimp_gallery: function (_value) + _init_blueimp_gallery: function (event, _value) { var mediaContent = []; var nm = find_nextmatch(this); @@ -310,7 +310,7 @@ if(nm) { // Get the row that was clicked, find its index in the list - var current_entry = nm.controller.getRowByNode(window.event.srcElement); + var current_entry = nm.controller.getRowByNode(event.target); current_index = current_entry.idx || 0; // But before it goes, we'll pull everything we can |