[Lazarus] TWSProgressBar.SetPosition() - what is it for?

Graeme Geldenhuys graeme at geldenhuys.co.uk
Fri Apr 5 16:24:04 CEST 2013


On 2013-04-05 14:50, Mattias Gaertner wrote:
> 
> It can be deleted.
> Do you need it?

No I don't need TFpGuiWSProgressBar.SetPosition(), because of the weird
TProgressBar design, where every property change goes via
ApplyUpdates(). I just implemented it because it was a blank virtual
method from a base class.

But this raises the other question. Why is TCustomProgressBar
implemented so different and inefficient.... every property change going
through TCustomProgressBar.ApplyUpdates. I say inefficient, because now
all the backend widgetsets must check and set all properties of the
ProgressBar widget, even if only a single property value has changed.

I ran git-blame to see when it was introduced, and by whom. But the code
predates the SubVersion repository.


Regards,
  - Graeme -

-- 
fpGUI Toolkit - a cross-platform GUI toolkit using Free Pascal
http://fpgui.sourceforge.net/





More information about the Lazarus mailing list