[Konsole-devel] About duplicated enumeration definitions in the code

Jekyll Wu adaptee at gmail.com
Sat Mar 17 03:52:14 UTC 2012


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Hi:

    There are a few duplicated enumeration definitions scattered
around within the code. They are mostly related with profile options,
for example:

    Profile::BellModeEnum           <==>        TerminalDisplay::BellMode
    Profile::ScrollBarPositionEnum  <==>
TerminalDisplay::ScrollBarPosition
    Profile::HistoryModeEnum        <==>
HistorySizeDialog::HistoryMode

Such duplication is definitely not good. What is the better way to
eliminate those duplication ?

a). Make TerminalDisplay, HistorySizeDialog, etc all #inlucde "Profile.h"

b). Move those enum definition into another separate small header(like
Enumeration.h), and all other related files #include "Enumeration.h"

I personally prefer b).

Regards
Jekyll


-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2.0.18 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/

iQIcBAEBAgAGBQJPZApuAAoJEOemZ9znWXlA12QP/iKkbXpfZ5JIJemuv7HxFjcn
xMosAZ5iuGyDJODKx+GxzeXWcn09MBdFI+HHRG6EWtCuINhfSVwoxMcspEgS+46S
lcFEDd1GoMvTancymsGFkNdnyTekcLS9iGGudTS5MgjB1SKuJ94ui3OdsuQf2Xrz
wgGzclywCPgLfhaX6DfQZkRqQxNI9Cbsbi8HTPb9A/RKTNK6xp+ocxory59elivn
4vaJPBoVHcP+nTapIEv1sQWYBeeNemSgT+e7H5yDe9PqjMfk6Q0cwtiQQbcYkh+H
7vQl03MrSyh6zFnrQ6Vo0uVLw86+QtUpEw24B2G5T9PUHH4a5fiUx6b1SkWWOPPt
LfLhV/B/mog9M7MHD8li7V3/zhFcq0vKCYS1dElNJTTm7urRGtTOFTCYPRMFmcQ9
xrGGswF4bEOLFgdz2VNBYEkqgY5lRZZdKuyeXOs3Iycsqe538XBbbxfDeuqtB4+w
Rt9JK8Eam2OWu1GZRYFAhM4jvDMtIreIKlMy6/xZPfVDHgK0xwT9RGtllEVw2eh/
xSJA5cFBUyIdZNRVqdiuicWBq7/H+uV65Q3pZWXxLsMI7EDIo+Qsnl/iNVGDpYDJ
x6cyhAbD762I3TwuFbEiFuPQGhTk5OF3YzFbSfyjQKRhpntRDQa/NxTSqnCXBnyN
zACzAVcw24edAVkbx1GN
=o+9Z
-----END PGP SIGNATURE-----



More information about the konsole-devel mailing list