- var tbWindow = $('#TB_window'),
- width = $(window).width(),
- H = $(window).height(),
- W = ( 720 < width ) ? 720 : width,
- adminbar_height = 0;
-
- if ( $('body.admin-bar').length ) {
- adminbar_height = parseInt( jQuery('#wpadminbar').css('height'), 10 );
- }
+ var tbWindow = $( '#TB_window' ),
+ width = $( window ).width(),
+ H = $( window ).height() - ( ( 850 < width ) ? 60 : 20 ),
+ W = ( 850 < width ) ? 830 : width - 20;