TOulook2003 class bug

Post Reply
User avatar
James Bott
Posts: 4654
Joined: Fri Nov 18, 2005 4:52 pm
Location: San Diego, California, USA
Contact:

TOulook2003 class bug

Post by James Bott »

Antonio,

There seems to be a small bug in the new TOulook2003 class. In the AddGroup() method there is no dialog creation like there is in the New() method.

I think this code needs to be added to the AddGroup() method:

DEFINE DIALOG oDlg OF Self STYLE WS_CHILD ;
FROM 33, 0 TO ::nHeight - ( Len( ::aGroups ) * 32 ), ::nWidth() - 1 PIXEL ;
FONT Self:oFont
AAdd( ::aDialogs, oDlg )

[This is the same code that is in the New() method.]

Or, the code needs to be made into a new AddDialog() method and called from both the New() and AddGroup() methods. This is probably a better solution.

Regards,
James
User avatar
James Bott
Posts: 4654
Joined: Fri Nov 18, 2005 4:52 pm
Location: San Diego, California, USA
Contact:

Post by James Bott »

I see that my suggested solution above will not work because AddGroup() is getting called in the New() method already, then the dialog is added. If the dialog is added in the AddGroup() method then it cannot be added in the New() method also. I guess this will require some more thought.

James
Post Reply