Lines Matching refs:offset
75 // adjust the scroll offset, if necessary
77 BPoint offset = ValidScrollOffsetFor(fScrollOffset);
78 if (offset != fScrollOffset)
79 SetScrollOffset(offset);
95 // Sets the scroll offset.
97 Scrollable::SetScrollOffset(BPoint offset)
99 // adjust the supplied offset to be valid
100 offset = ValidScrollOffsetFor(offset);
101 if (fScrollOffset != offset) {
103 fScrollOffset = offset;
114 // Returns the current scroll offset.
125 Scrollable::SetDataRectAndScrollOffset(BRect dataRect, BPoint offset)
138 // adjust the scroll offset, if necessary
139 offset = ValidScrollOffsetFor(offset);
140 if (offset != fScrollOffset)
141 SetScrollOffset(offset);
150 // Returns the valid scroll offset next to the supplied offset.
152 Scrollable::ValidScrollOffsetFor(BPoint offset) const
154 return ValidScrollOffsetFor(offset, fDataRect);
159 // Returns the valid scroll offset next to the supplied offset.
161 Scrollable::ValidScrollOffsetFor(BPoint offset, const BRect& dataRect) const
165 // adjust the offset to be valid
166 if (offset.x < dataRect.left)
167 offset.x = dataRect.left;
168 else if (offset.x > maxX)
169 offset.x = maxX;
170 if (offset.y < dataRect.top)
171 offset.y = dataRect.top;
172 else if (offset.y > maxY)
173 offset.y = maxY;
174 return offset;
196 // adjust the scroll offset, if necessary
197 BPoint offset = ValidScrollOffsetFor(fScrollOffset);
198 if (offset != fScrollOffset)
199 SetScrollOffset(offset);
216 // at the scroll offset.
237 // the scroll offset has changed.