Results 1 to 2 of 2

Thread: [FIXED-393][3.0.0] Ext.MessageBox maxWidth bug with fix

    Thank you for reporting this bug. We will make it our priority to review this report.
  1. #1
    Sencha Premium User
    Join Date
    Aug 2009
    Location
    Amsterdam, NY
    Posts
    41
    Vote Rating
    4
      0  

    Default [FIXED-393][3.0.0] Ext.MessageBox maxWidth bug with fix

    In the Ext.MessageBox code, there's the updateText function. It seems that opts.maxWidth isn't used in the width calculation. The code below is from Ext 3.0.0.

    Code:
            updateText : function(text){
                if(!dlg.isVisible() && !opt.width){
                    dlg.setSize(this.maxWidth, 100); // resize first so content is never clipped from previous shows
                }
                msgEl.update(text || '');
    
                var iw = iconCls != '' ? (iconEl.getWidth() + iconEl.getMargins('lr')) : 0;
                var mw = msgEl.getWidth() + msgEl.getMargins('lr');
                var fw = dlg.getFrameWidth('lr');
                var bw = dlg.body.getFrameWidth('lr');
                if (Ext.isIE && iw > 0){
                    //3 pixels get subtracted in the icon CSS for an IE margin issue,
                    //so we have to add it back here for the overall width to be consistent
                    iw += 3;
                }
                var w = Math.max(Math.min(opt.width || iw+mw+fw+bw, opt.maxWidth || this.maxWidth),
                            Math.max(opt.minWidth || this.minWidth, bwidth || 0));

  2. #2
    Sencha - Ext JS Dev Team evant's Avatar
    Join Date
    Apr 2007
    Location
    Sydney, Australia
    Posts
    18,600
    Vote Rating
    874
      0  

    Default

    Agreed, thanks for the report.

    Fix applied to svn in rev #5792 for patch release 3.1.1.
    Evan Trimboli
    Twitter - @evantrimboli

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •