Ticket #1982: 1982_3.patch
File 1982_3.patch, 1.7 KB (added by , 16 years ago) |
---|
-
editor/_source/classes/fckpanel.js
161 161 { 162 162 this.Subpanel = panel ; 163 163 // If the panel has already been increased enough, get out 164 if ( ( this.IncreasedX >= width) && (this.IncreasedY >= height))164 if ( ( this.IncreasedX >= width ) && ( this.IncreasedY >= height ) ) 165 165 return false ; 166 166 167 this.IncreasedX = Math.max( this.IncreasedX, width) ;168 this.IncreasedY = Math.max( this.IncreasedY, height) ;167 this.IncreasedX = Math.max( this.IncreasedX, width ) ; 168 this.IncreasedY = Math.max( this.IncreasedY, height ) ; 169 169 } 170 170 171 171 var x = this.ShowRect.x ; … … 175 175 176 176 // Horizontally increase as needed (sum of widths). 177 177 // Vertically, use only the maximum of this menu or the submenu 178 this._Popup.show( x, this.ShowRect.y, this.ShowRect.w + w, Math.max(this.ShowRect.h, this.IncreasedY) ) ; 178 var finalWidth = this.ShowRect.w + w ; 179 var finalHeight = Math.max( this.ShowRect.h, this.IncreasedY ) ; 180 if ( this.ParentPanel ) 181 this.ParentPanel.ResizeForSubpanel( this, finalWidth, finalHeight ) ; 182 this._Popup.show( x, this.ShowRect.y, finalWidth, finalHeight, this.RelativeElement ) ; 179 183 180 184 return this.IsRTL ; 181 185 } … … 226 230 this.ShowRect = {x:x, y:y, w:iMainWidth, h:eMainNode.offsetHeight} ; 227 231 this.IncreasedX = 0 ; 228 232 this.IncreasedY = 0 ; 233 this.RelativeElement = relElement ; 229 234 } 230 235 231 236 // Second call: Show the Popup at the specified location, with the correct size. … … 456 461 this._Window = null ; 457 462 this.Document = null ; 458 463 this.MainNode = null ; 464 this.RelativeElement = null ; 459 465 }