https://bugs.documentfoundation.org/show_bug.cgi?id=90517
Bug ID: 90517 Summary: Push WinBits constants down into subclasses Product: LibreOffice Version: unspecified Hardware: Other OS: All Status: UNCONFIRMED Severity: enhancement Priority: medium Component: graphics stack Assignee: libreoffice-bugs@lists.freedesktop.org Reporter: noelgran...@gmail.com So I started looking at converting the WinBits WB_* defines in include/tools/wintypes.hxx to an 'enum class', and after a few changes and discovering that there are lots of WB_ macros scattered around that simply define a new WB_ value as pointing to an existing one e.g. in include/svtools/ivctrl.hxx #define WB_ICON WB_RECTSTYLE #define WB_SMALLICON WB_SMALLSTYLE , I think that this whole thing needs a rethink. Specifically, I think that (*) we need to push these style things down to the subclass-specific level where each one applies, instead of multiplexing them into a single field at the root level (*) we need to convert to using setter methods to turn them on and off Further, I would suggest that (*) the setter methods have the style MyWindowSubclass& MyWindowSubClass::SetFoo(bool b = true) so to make the code easier to write when setting multiple style flags i.e. we can then write MyWindowSubclass x(); x.SetFoo().setBar(); -- You are receiving this mail because: You are the assignee for the bug.
_______________________________________________ Libreoffice-bugs mailing list Libreoffice-bugs@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice-bugs