The MASM Forum Archive 2004 to 2012

General Forums => The Campus => Topic started by: six_L on November 24, 2006, 02:11:18 PM

Title: ButtonClass
Post by: six_L on November 24, 2006, 02:11:18 PM
hello,all
as the following JPG:
why can't the tree be showed in ButtonClassName?


[attachment deleted by admin]
Title: Re: ButtonClass
Post by: Tedd on November 24, 2006, 08:55:28 PM
Probably drawing order - whichever is drawn last is drawn on-top.
If this is a dialog, you should be able to just define the ButtonClassName first.
Title: Re: ButtonClass
Post by: six_L on November 25, 2006, 01:07:25 PM
hey,Tedd
Thanks your answer.

the problem is still there. i attached the sourcecode.

[attachment deleted by admin]
Title: Re: ButtonClass
Post by: Tedd on November 25, 2006, 04:03:09 PM
Remove the WS_CLIPSIBLINGS style from the treeview creation :wink
Title: Re: ButtonClass
Post by: six_L on November 25, 2006, 04:18:47 PM
hey,Tedd
OK!
thank you very much.
Title: Re: ButtonClass
Post by: ToutEnMasm on November 25, 2006, 06:48:06 PM

I have recompiled and tested the Tree1_.asm  without changing the code and .........
It work perfectly with ml /Zp4.
Seem to be a problem of alignement.
Title: Re: ButtonClass
Post by: six_L on November 26, 2006, 06:17:02 AM
hello,ToutEnMasm
thanks your answer.
i know a method of alignement

it can't work perfectly with ml /Zp4 to me. because the line(invoke GroupButton,hWin,S('Dir'),15,5,211,225,GROUPDIR) has been added ";" in sourcecode.
Title: Re: ButtonClass
Post by: ToutEnMasm on November 26, 2006, 07:09:38 AM

Hello,
More simple like that.It is two childs of the same windows that couldn't have the same place,except if one of them has the WS_EX_TRANSPARENT extended style.
Give this extended style to the GroupButton and there is no more problem

You can also change the parent of the treeview and give it the handle of the groupbox as parent window. In this case,some events of the treeview must be modified.
                                   ToutEnMasm