Combuster wrote:Visual basic does subclass controls under the hood, since the events that you can handle are a superset of that which is sent to the parent, but also contain internal messages for the control (including mouse messages, keypress messages). Whether it always subclasses, or only when you defined the required functions, I won't comment about.
For example? Sure you can even write an activex control that subclasses itself to achieve some goal and then that could be a control in VB that subclasses under the hood. But none of the default controls, or even many of the ones that ship with VB6 do this. At least not as far as I'm aware, so, examples?
Combuster wrote:I can't check the details since I'm on linux, but your pendantcy seems to be quite a double standard.
How so?
Combuster wrote:Majority of messages that are actually used, fine.
Majority of ones that you are almost guaranteed to need to use, maybe, but certainly not the majority of ones actually used in the cases that I described several posts back.
Combuster wrote:I've actually bothered to open up a list and count them:
66 that are handled in vb (one way or another)
I'm sorry sir, I've consulted the MSDN documentation for each individual message to find that VB6 allows the programmer to handle only 28 messages. I gave you the benefit of the doubt for notifications that visual basic only lets you handle for specific parameters.
Combuster wrote:23 indirectly in vb (since they go paired with other messages or things that can be done via non-WM routes)
Such as? I'm curious which messages you think are "paired" with each other?
Combuster wrote:19 not in vb (of which 17 account for the NC* messages, for which I'm tempted to put in the next category, since UI theory dictates uniformity, and changing the default is not part of that, and vb can do forms without title bars out of the box if you really want that.)
that leaves 92 messages that are not interesting except in very specialized contexts
Well, since your original figure of 66 handled in VB is wrong, these numbers are not only off, but your dismissal of these messages leads me to believe you have not had any proper training for windows programming. Removing the title bar from the form is not the same as drawing in the non-client area, and it's awful, awful programming practice.
Combuster wrote:(a rough overview: 8-bit modes are out of fashion, users changing system settings generally only occur in the short phase after installation, you have resolution changes that always go in pairs since tabbing out of directx apps restores the resolution, and the occasional hardware changes - safe eject anyone?)
I've written several applications that needed to be aware of any system setting changes. In fact, looking over a project I wrote for a company one summer, I had to subclass a form in order to handle these messages:
WM_MOUSEACTIVATE
WM_ENTERSIZEMOVE
WM_EXITSIZEMOVE
WM_NCHITTEST
WM_NCACTIVATE
WM_NCPAINT
WM_SETTINGCHANGE
WM_NCCALCSIZE
WM_DESTROY
WM_SYSCOMMAND
WM_MOVING
WM_WINDOWPOSCHANGED
WM_GETMINMAXINFO
WM_SETCURSOR
The amount of routines in the actual visual basic form object that I could use? 3: Form_Load, Form_QueryUnload, and Form_Resize.
Did Visual Basic make this very unpleasant as well as present quirks that required an understanding of how visual basic handles these messages in order to make it behave how I needed it to? you bet.
Combuster wrote:Yes, these are things I'm saying that subclassing is necessary for in Visual Basic.
Well, apparently they are not. And even if you subclass, you'd do so much less than in C, which was the real point in question
So subclassing isn't necessary for docking toolwindows in Visual Basic? May I see your implementation so I can tell you why it's wrong?