tuiHoneyPot

front and back end of my TUI honeypot
Log | Files | Refs | README

getStyles.js (409B)


      1 define( function() {
      2 	"use strict";
      3 
      4 	return function( elem ) {
      5 
      6 		// Support: IE <=11 only, Firefox <=30 (trac-15098, trac-14150)
      7 		// IE throws on elements created in popups
      8 		// FF meanwhile throws on frame elements through "defaultView.getComputedStyle"
      9 		var view = elem.ownerDocument.defaultView;
     10 
     11 		if ( !view || !view.opener ) {
     12 			view = window;
     13 		}
     14 
     15 		return view.getComputedStyle( elem );
     16 	};
     17 } );