[Kde-games-devel] A new highscore manager - KScoreManager
Pino Toscano
toscano.pino at tiscali.it
Tue Apr 29 17:03:40 CEST 2008
Hi,
some API notes :)
> #include <QPair>
No QPair used, to be removed.
> enum OptionFlag
> {
> DoNotAskName, ///<Should the player be asked for their name
> upon getting a highscore
> LessIsMore ///<should the highscores be awarded
> such that a lower score is better
> };
LessIsMore seems quite confusing (at least IMHO), maybe LessIsBetter?
> KDialog createScoreDialog(const ScoreDisplay& scoreDisplay =
> ScoreDisplay()) const;
KDialog * as return value, I'd say.
> QGraphicsWidget createScoreGraphicsWidget(const ScoreDisplay&
> scoreDisplay = ScoreDisplay()) const;
... ditto.
> void setOptions(const Option& options = Option());
This would allow something like:
KScoreManager::self()->setOptions();
that IMHO is a bit illogical (a setter that sets nothing, apparently).
Better force the parameter, so
...->setOptions(KScoreManager::Options())
is way clear that it will set no options.
Ah, and better put the destructor as well, even if empty.
That's all, for now :)
--
Pino Toscano
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: This is a digitally signed message part.
Url : http://mail.kde.org/pipermail/kde-games-devel/attachments/20080429/1b23bce7/attachment.pgp
More information about the kde-games-devel
mailing list