[Kde-games-devel] KZoomMainWindow and adjustSize() tale :)

Dmitry Suzdalev dimsuz at gmail.com
Mon Jul 31 20:44:57 CEST 2006


On Monday 31 July 2006 22:25, Burkhard Lehner wrote:
> Instead of creating a base class one could also demand a slot
> "zoomChanged()" for the widgets that are added to the KZoomMainWindow. This
> is not the nice object oriented approach for it doesn't use polymorphism,
> but the result would be the same. The disadvantage: The compiler wouldn't
> complain about adding a widget that doesn't have this slot. Only at runtime
> the KZoomMainWindow would fail to connect to that slot (with the usual
> message on the console).
Yes, that's an option, but personally I think that it's better to clearly 
define an interface.
After all it can change through time, some specific methods/functionality may 
be added.

And what if someday Qt decides to crash (or format HDD) instead of reporting a 
connection error? :)

Thanks for you input!
Dmitry.


More information about the kde-games-devel mailing list