Changeset edd2565 in github


Ignore:
Timestamp:
Aug 4, 2012 5:44:50 AM (11 months ago)
Author:
Thomas Bruederli <thomas@…>
Children:
b169de8
Parents:
ea32756
Message:

Also fix dialog position 'right'

File:
1 edited

Legend:

Unmodified
Added
Removed
  • plugins/jqueryui/jqueryui.php

    rea32756 redd2565  
    4040            $rcmail->output->add_script("jQuery.extend(jQuery.ui.dialog.prototype.options.position, { 
    4141                using: function(pos) { 
    42                     var topOffset = jQuery(this).css(pos).offset().top - 12; 
    43                     if (topOffset < 0) jQuery(this).css('top', pos.top - topOffset); 
     42                    var me = jQuery(this), 
     43                        offset = me.css(pos).offset(), 
     44                        topOffset = offset.top - 12; 
     45                    if (topOffset < 0) 
     46                        me.css('top', pos.top - topOffset); 
     47                    if (offset.left + me.outerWidth() + 12 > jQuery(window).width()) 
     48                        me.css('left', pos.left - 12); 
    4449                } 
    4550            });", 'foot'); 
Note: See TracChangeset for help on using the changeset viewer.