Fixed position of new matrix

git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@8841 72102866-910b-0410-8b05-ffd578937521
This commit is contained in:
Nicola Pero 2001-01-27 15:12:50 +00:00
parent 023ba907c1
commit 5e64aba48d

View file

@ -1572,7 +1572,9 @@ static float scrollerWidth; // == [NSScroller scrollerWidth]
// then the column must be visible
if ((_lastColumnLoaded == 0) ||
(_lastColumnLoaded <= (_maxVisibleColumns - 1)))
[_horizontalScroller setEnabled: NO];
{
[_horizontalScroller setEnabled: NO];
}
else
{
if (!_skipUpdateScroller)
@ -2818,15 +2820,14 @@ static float scrollerWidth; // == [NSScroller scrollerWidth]
[matrix setCellSize: ms];
mr = [matrix frame];
// matrix smaller than scrollview's content
if (mr.size.height < cs.height)
{
// view requires origin adjustment for it to appear at top
mr.origin.y = cs.height;
[matrix setFrame: mr];
}
// this will automatically move the matrix on top if it's not
// yet the sc's document view, otherwise it will not move it
[sc setDocumentView: matrix];
// so we do it manually anyway - the clipview's coordinate
// system is flipped - we want the matrix to appear on top
mr.origin.y = cs.height;
[matrix setFrame: mr];
}
}