Changeset 26502

Show
Ignore:
Timestamp:
07/19/08 08:39:14 (4 months ago)
Author:
stippi
Message:

In my BSlider changes, I changed the behavior of GetPreferredSize(), which
previously did never shrink the slider horizontally. This broke a couple
apps, so I added it back, although I don't quite agree that this is the correct
behavior. Apps using the new layout system are not affected though, so I
guess it is alright. Should fix #2530, although I didn't test it yet.

Files:
1 modified

Legend:

Unmodified
Added
Removed
  • haiku/trunk/src/kits/interface/Slider.cpp

    r26479 r26502  
    13011301        BSize preferredSize = PreferredSize(); 
    13021302 
    1303         if (_width) 
    1304                 *_width = preferredSize.width; 
     1303        if (_width) { 
     1304//              *_width = preferredSize.width; 
     1305                // NOTE: For compatibility reasons, the BSlider never shrinks 
     1306                // horizontally. This only affects applications which do not 
     1307                // use the new layout system. 
     1308                *_width = max_c(Bounds().Width(), preferredSize.width); 
     1309        } 
    13051310 
    13061311        if (_height)