[Kde-games-devel] moved Kajongg from playground to kdereview
Wolfgang Rohdewald
wolfgang at rohdewald.de
Sun Feb 21 23:08:27 CET 2010
On Sunday 21 February 2010, Ingo Klöcker wrote:
> > This would fix one bug in libkmahjongg, though: If in
> > KMahjongg you click on the shadow of a tile, that tile
> > is selected even if there is another tile under that
> > shadow. The shadowed tile should be selected, not the
> > shadowing tile. This works correctly with my code
> > although I don't actually need this.
>
> This example clearly demonstrates why code duplication is bad.
> KMahjongg does not benefit from your bug fix because you
> fixed the bug only in the duplicated code.
While you are theoretically of course absolutely right,
there was no alternative for me personally.
I did some major restructuring resulting in a different
API. Being able to show tiles where some of them are
rotated, like in the corners of the wall, and correctly
showing all shadows did mean a lot of internal changes.
Also Kajongg uses QGV while libkmahjongg does not
which also makes for a lot of differences.
I do not believe it would be easy to backport that bugfix.
Anyway r934004 could help with it.
I would never have started this project if that would
have meant to first extend C++ libkmahjongg.
It is not as if I cannot write C++ code but I just did not
want to do that anymore and still don't unless I get paid
for it.
If anybody wants to extend the libkmahjongg API, I would
of course be of assistance and use it for Kajongg if possible.
--
Wolfgang
More information about the kde-games-devel
mailing list