[PATCH] New signal for KKeySequenceWidget

Thomas McGuire thomas.mcguire at gmx.net
Tue Aug 21 16:42:11 BST 2007


Hi,

On Tuesday 21 August 2007, Andreas Hartmetz wrote:
> On Monday 20 August 2007 22:43:42 Thomas McGuire wrote:
> >
> > attached a patch which adds a new signal to KKeySequenceWidget. This
> > signal is like the existing keySequenceChanged() signal, just with more
> > parameters.
> >
> I'd rather have a virtual validate() function that can be reimplemented,
> see http://doc.trolltech.com/qq/qq13-apis.html#staticpolymorphism.
> OTOH it could be argued that breaking static polymorphism (interesting
> term) is worth it if not breaking it means too much of a hassle for API
> users. Either side has a valid argument, so - anybody else want to comment?
I'd say the validate method is too much hassle for API users. That would mean 
to create a new class that inherits KKeySequenceWidget every time I use it. 
Furthermore, there is one place where KKeySequenceWidget is used inside an UI 
file, changing that would be even more inconvenient.

So I vote for the new signal, because it minimizes porting work.

Regards,
Thomas





More information about the kde-core-devel mailing list