Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
RE: [platform-swt-dev] Inheritance and SWT


Erik,
        My comments weren't intended as a flame. I do think it's important for people to understand the shift in usage though.

        As to subclassing as a hobby, go for it. The one thing to keep in mind is that, SWT does not guarantee consistancy of internal structure between releases. I know of a specific example of a case in the early days where someone was relying on the internals of a widget that was "not intended to be subclassed" and much of their work was broken when the next release came out.

McQ.



"Erik Poupaert" <erik.poupaert@xxxxxxxxx>
Sent by: platform-swt-dev-admin@xxxxxxxxxxx

02/04/03 09:36 AM
Please respond to platform-swt-dev

       
        To:        <platform-swt-dev@xxxxxxxxxxx>
        cc:        
        Subject:        RE: [platform-swt-dev] Inheritance and SWT




>>>> On a more fundamental level though, usually when someone wants to
subclass a widget, it's because they are trying to treat SWT as framework
and implement application logic, for example, in the widget itself. This is
the wrong way to use SWT. SWT widgets simply represent reasonable packagings
of the platform widget capabilities. Unless you find a platform which has a
widget that has your application logic embedded in its operating system
code, you shouldn't be trying to subclass an existing widget to implement
it.

Unfortunately, none of us are infallible; and the SWT designers aren't
either. I subclass widgets, because I enjoy subclassing widgets. It's my
hobby.

_______________________________________________
platform-swt-dev mailing list
platform-swt-dev@xxxxxxxxxxx
http://dev.eclipse.org/mailman/listinfo/platform-swt-dev


Back to the top