Mixer/DPM: Fix reposition interfering with optimized drawing.

This commit is contained in:
Jonathan Moore Liles 2013-07-14 18:50:53 -07:00
parent 123d45c1ae
commit b31eef9c36
1 changed files with 6 additions and 3 deletions

View File

@ -116,13 +116,16 @@ DPM::draw_label ( void )
void void
DPM::resize ( int X, int Y, int W, int H ) DPM::resize ( int X, int Y, int W, int H )
{ {
int old_segments = _segments;
if ( type() == FL_HORIZONTAL ) if ( type() == FL_HORIZONTAL )
_segments = floor( W / (double)_pixels_per_segment ); _segments = floor( W / (double)_pixels_per_segment );
else else
_segments = floor( H / (double)_pixels_per_segment ); _segments = floor( H / (double)_pixels_per_segment );
_last_drawn_hi_segment = 0; if ( old_segments != _segments )
_last_drawn_hi_segment = 0;
Fl_Widget::resize( X, Y, W, H ); Fl_Widget::resize( X, Y, W, H );
} }