Forum | | | | - Page 1 - |
| ![Georg Hovenbitzer: 02/09/10](.././../../i/a/199623250643725492e11ec.jpg) Georg Hovenbitzer | Hello together,
i sit time again to one trouble and come not further. background is, I Search a Possibility the Umklappen the Grippers without the leave of Waitinput to get and again produce. my attempt was is over The Notifikafion RBN_HEIGHTCHANGE this To experienced, but unfortunately comes in of my SubClassProd nothing gescheites on.
Since I there 'm not as practiced, I'm going of it from, I a Error intercepting the Message make. I hope very it can me of/ one on The Sprünge help. CompileMarkSeparation $H D:Eigene DateienProgrammeXProfan11INCLUDEMessages.ph
$H D:Eigene DateienProgrammeXProfan11INCLUDEWindows.ph
$H D:Eigene DateienProgrammeXProfan11INCLUDEcommctrl.ph
Declare Edit1&, Edit2&
Struct ReBar = Size&,
Mask&,
Style&,
clrFore&,
clrBack&,
lpText&,
cch&,
iImage&,
hwndChild&,
cxMinChild&,
cyMinChild&,
cx&,
hbmBack&,
wID&,
cyChild&,
cyMaxChild&,
cyIntegral&,
cxIdeal&,
lParam&,
cxHeader&
Declare ReBar#
Dim ReBar#,ReBar
Clear ReBar#
Declare a#
Dim a#,16
Struct TNMHdr = hwndFrom&,
idFrom%,
code%
Declare lpnmhdr#
Dim lpnmhdr#,TNMHdr
WindowStyle 2 + 8 + 16 + 128 + 256 + 512
WindowTitle "ReBar - Test"
Window 0,0-1024,768
Cls ~GetSysColor(~COLOR_BTNFACE)
Edit1& = @Create("Edit",%hWnd,"TreeView",0,0,0,0)
Edit2& = @Create("Edit",%hWnd,"ListView",0,0,0,0)
Clear a#
Long a#,0 = 8
Long a#,4 = $FFFF
@External("comctl32.dll","InitCommonControlsEx",a#)
Declare ReBar&
ReBar& = @Control("ReBarWindow32","",($50000000 | ~CCS_NORESIZE | ~RBS_FIXEDORDER),5,5,1008,250,%hWnd,%hInstance,0)
With ReBar#
.Size& = @SizeOf(ReBar#)
.Mask& = (~RBBIM_CHILD | ~RBBIM_CHILDSIZE | ~RBBIM_SIZE | ~RBBIM_STYLE | ~RBBIM_IDEALSIZE)
.Style& = ~RBBS_NOGRIPPER
.clrFore& = 0
.clrBack& = 0
.lpText& = 0
.cch& = 0
.iImage& = 0
.hwndChild& = Edit1&
.cxMinChild& = 0
.cyMinChild& = @Height(ReBar&)
.cx& = 300
.hbmBack& = 0
.wID& = 0
.cyChild& = @Height(ReBar&)
.cyMaxChild& = @Height(ReBar&)
.cyIntegral& = 0
.cxIdeal& = 300
.lParam& = 0
.cxHeader& = 0
@SendMessage(ReBar&,~RB_INSERTBAND,0,ReBar#)
.Style& = ~RBBS_GRIPPERALWAYS
.clrFore& = 0
.clrBack& = 0
.lpText& = 0
.cch& = 0
.iImage& = 0
.hwndChild& = Edit2&
.cxMinChild& = 0
.cyMinChild& = @Height(ReBar&)
.cx& = 690
.hbmBack& = 0
.wID& = 0
.cyChild& = @Height(ReBar&)
.cyMaxChild& = @Height(ReBar&)
.cyIntegral& = 0
.cxIdeal& = 690
.lParam& = 0
.cxHeader& = 0
@SendMessage(ReBar&,~RB_INSERTBAND,1,ReBar#)
EndWith
SubClassProc
If %sMessage = ~WM_NOTIFY
lpnmhdr# = &sLParam
If lpnmhdr#.hwndFrom& = ReBar&
Locate 40,30
Print lpnmhdr#.idFrom%
Print lpnmhdr#.code%
If lpnmhdr#.code% = ~RBN_HEIGHTCHANGE
Locate 40,30
Print "Treffer"
EndIf
EndIf
EndIf
@Set("WinProc",1)
EndProc
SubClass %hWnd,1
WhileNot %Key = 2
WaitInput
EndWhile
Dispose a#
Dispose ReBar#
Dispose lpnmhdr#
SubClass ReBar&,0
~D Window (ReBar& )
End
|
| | | Viele Grüsse, Georg Hovenbitzer(Windows XP Pro, XProfan 11.2, Profan2Cpp 1.6a) | 02/09/10 ▲ |
| |
| ![](.././../../i/hr.gif) | « this Posting watts as Solution marked. » | | ![Jörg Sellmeyer: 06/19/18](.././../../i/a/8132362004294faafc5e8c.jpg) Jörg Sellmeyer | ![Solution](.././../../i/st3.gif) Habs too time repariert and the Veränderung eingefügt...
$H Messages.ph
$H windows.ph
$H commctrl.ph
Declare Edit1&, Edit2&
Struct ReBar = Size&,\
Mask&,\
Style&,\
clrFore&,\
clrBack&,\
lpText&,\
cch&,\
iImage&,\
hwndChild&,\
cxMinChild&,\
cyMinChild&,\
cx&,\
hbmBack&,\
wID&,\
cyChild&,\
cyMaxChild&,\
cyIntegral&,\
cxIdeal&,\
lParam&,\
cxHeader&
Declare ReBar#
Dim ReBar#,ReBar
Clear ReBar#
Declare a#
Dim a#,16
Struct TNMHdr = hwndFrom&,\
idFrom&,\
code%
Declare lpnmhdr#
Dim lpnmhdr#,TNMHdr
Window Style 2 + 8 + 16 + 128 + 256 + 512
Window Title "ReBar - Test"
Window 0,0-1024,768
Cls ~GetSysColor(~COLOR_BTNFACE)
Edit1& = @Create("Edit",%hWnd,"TreeView",0,0,0,0)
Edit2& = @Create("Edit",%hWnd,"ListView",0,0,0,0)
Clear a#
Long a#,0 = 8
Long a#,4 = $FFFF
@External("comctl32.dll","InitCommonControlsEx",a#)
Declare ReBar&
ReBar& = @Control("ReBarWindow32","",($50000000 | ~CCS_NORESIZE | ~RBS_FIXEDORDER),5,5,1008,250,%hWnd,%hInstance,0)
With ReBar#
.Size& = @SizeOf(ReBar#)
.Mask& = (~RBBIM_CHILD | ~RBBIM_CHILDSIZE | ~RBBIM_SIZE | ~RBBIM_STYLE | ~RBBIM_IDEALSIZE)
.Style& = ~RBBS_NOGRIPPER
.clrFore& = 0
.clrBack& = 0
.lpText& = 0
.cch& = 0
.iImage& = 0
.hwndChild& = Edit1&
.cxMinChild& = 0
.cyMinChild& = @Height(ReBar&)
.cx& = 300
.hbmBack& = 0
.wID& = 0
.cyChild& = @Height(ReBar&)
.cyMaxChild& = @Height(ReBar&)
.cyIntegral& = 0
.cxIdeal& = 300
.lParam& = 0
.cxHeader& = 0
@SendMessage(ReBar&,~RB_INSERTBAND,0,ReBar#)
.Style& = ~RBBS_GRIPPERALWAYS
.clrFore& = 0
.clrBack& = 0
.lpText& = 0
.cch& = 0
.iImage& = 0
.hwndChild& = Edit2&
.cxMinChild& = 0
.cyMinChild& = @Height(ReBar&)
.cx& = 690
.hbmBack& = 0
.wID& = 0
.cyChild& = @Height(ReBar&)
.cyMaxChild& = @Height(ReBar&)
.cyIntegral& = 0
.cxIdeal& = 690
.lParam& = 0
.cxHeader& = 0
@SendMessage(ReBar&,~RB_INSERTBAND,1,ReBar#)
EndWith
SubClassProc
If %sMessage = ~WM_NOTIFY
lpnmhdr# = &sLParam
If lpnmhdr#.hwndFrom& = ReBar&
If Long(&slparam,8) = ~RBN_HEIGHTCHANGE
Clear a#
@SendMessage(ReBar&,~RB_SIZETORECT,0,a#)
@Set("WinProc",0)
EndIf
EndIf
EndIf
ENDPROC
SubClass %hWnd,1
WhileNot %Key = 2
WaitInput
EndWhile
Dispose a#
Dispose ReBar#
Dispose lpnmhdr#
SubClass ReBar&,0
~DestroyWindow(ReBar&)
End
|
| | | | | ![](.././../../i/hr.gif) |
| | ![Frank Abbing: 02/09/10](.././../../i/a/noavatar.gif) Frank Abbing | Have not integrally your trouble understood. What is Umklappen the Gripper? but eventuel is it rather, directly the ReBar-Control To subclassen... |
| | | | |
| | ![Georg Hovenbitzer: 02/09/10](.././../../i/a/199623250643725492e11ec.jpg) Georg Hovenbitzer | is correct, if one The Fehlerbeschreibung ließt is tappt im dunkeln difficult to unterstand, another attempt. ![](.././../../i/s/__upl_ext_1111498515.gif)
Zieht one whom Gripper down from the ReBar Control out, disappears it completely and is only with a resetting visible again. The can make if the Waitinput interrupted becomes, because one the level determined. i want this but before, means to the interrupting the ReBar come along.
If I subclass the ReBar is no WM_NOTIFY on.
i hope so is now something understand written. ![](.././../../i/s/__upl_ext_1111498551.gif) |
| | | Viele Grüsse, Georg Hovenbitzer(Windows XP Pro, XProfan 11.2, Profan2Cpp 1.6a) | 02/09/10 ▲ |
| |
| | ![iF: 02/09/10](.././../../i/a/1.gif) | Do you have it once with of/ one nproc probiert? have of Rebars no idea, but real and disruptive sounds subclassing this still integrally helpful. |
| | | | |
| | ![Georg Hovenbitzer: 02/09/10](.././../../i/a/199623250643725492e11ec.jpg) Georg Hovenbitzer | yet not yet (will be But time try), where I do not faith, that it was bring. Since no Notifikation through comes, always only 64 ?! |
| | | Viele Grüsse, Georg Hovenbitzer(Windows XP Pro, XProfan 11.2, Profan2Cpp 1.6a) | 02/09/10 ▲ |
| |
| | ![iF: 02/09/10](.././../../i/a/1.gif) | know Yes not, whether a durchkommt, if Waitinput leave and is so Yes no more messages are ready for the SubclassProc. go in example 20 Messages abgesandt and the first Message resolve already one leave of Waitinput from, then become You The restlichen 19 Messages presumably not at all More by SubClassProc erfassen can, because You Perhaps not at all again in the Waitinput are. very this drop can I me hierbei quite well present, thatswhy again my hint it Real To subclassen. |
| | | | |
| | ![Frank Abbing: 02/09/10](.././../../i/a/noavatar.gif) Frank Abbing | Ts, WM_NOTIFY operates too with XProfans Subclassing perfect together...
your manner, How You The Notify-structure ansprichst, is wrong, there must you start. the here functions z.B. without Problems: CompileMarkSeparation The structure is well defective, z.B. must lpnmhdr#.idFrom% one Long-Int his, in the form go but only 2 byte reserved and addressed... |
| | | | |
| | ![Georg Hovenbitzer: 02/10/10](.././../../i/a/199623250643725492e11ec.jpg) Georg Hovenbitzer | Hello Frank,
Volltreffer ![](.././../../i/s/qq8.gif) on it lying it, I have from the windows.ph the structure TNMHdr taken (there it no NMHdr given) and this was the Error. super, everything work out right and you can now the vanish the Grippers directly prevent. CompileMarkSeparation |
| | | Viele Grüsse, Georg Hovenbitzer(Windows XP Pro, XProfan 11.2, Profan2Cpp 1.6a) | 02/10/10 ▲ |
| |
| | ![Jörg Sellmeyer: 06/19/18](.././../../i/a/8132362004294faafc5e8c.jpg) Jörg Sellmeyer | ![Solution](.././../../i/st3.gif) Habs too time repariert and the Veränderung eingefügt...
$H Messages.ph
$H windows.ph
$H commctrl.ph
Declare Edit1&, Edit2&
Struct ReBar = Size&,\
Mask&,\
Style&,\
clrFore&,\
clrBack&,\
lpText&,\
cch&,\
iImage&,\
hwndChild&,\
cxMinChild&,\
cyMinChild&,\
cx&,\
hbmBack&,\
wID&,\
cyChild&,\
cyMaxChild&,\
cyIntegral&,\
cxIdeal&,\
lParam&,\
cxHeader&
Declare ReBar#
Dim ReBar#,ReBar
Clear ReBar#
Declare a#
Dim a#,16
Struct TNMHdr = hwndFrom&,\
idFrom&,\
code%
Declare lpnmhdr#
Dim lpnmhdr#,TNMHdr
Window Style 2 + 8 + 16 + 128 + 256 + 512
Window Title "ReBar - Test"
Window 0,0-1024,768
Cls ~GetSysColor(~COLOR_BTNFACE)
Edit1& = @Create("Edit",%hWnd,"TreeView",0,0,0,0)
Edit2& = @Create("Edit",%hWnd,"ListView",0,0,0,0)
Clear a#
Long a#,0 = 8
Long a#,4 = $FFFF
@External("comctl32.dll","InitCommonControlsEx",a#)
Declare ReBar&
ReBar& = @Control("ReBarWindow32","",($50000000 | ~CCS_NORESIZE | ~RBS_FIXEDORDER),5,5,1008,250,%hWnd,%hInstance,0)
With ReBar#
.Size& = @SizeOf(ReBar#)
.Mask& = (~RBBIM_CHILD | ~RBBIM_CHILDSIZE | ~RBBIM_SIZE | ~RBBIM_STYLE | ~RBBIM_IDEALSIZE)
.Style& = ~RBBS_NOGRIPPER
.clrFore& = 0
.clrBack& = 0
.lpText& = 0
.cch& = 0
.iImage& = 0
.hwndChild& = Edit1&
.cxMinChild& = 0
.cyMinChild& = @Height(ReBar&)
.cx& = 300
.hbmBack& = 0
.wID& = 0
.cyChild& = @Height(ReBar&)
.cyMaxChild& = @Height(ReBar&)
.cyIntegral& = 0
.cxIdeal& = 300
.lParam& = 0
.cxHeader& = 0
@SendMessage(ReBar&,~RB_INSERTBAND,0,ReBar#)
.Style& = ~RBBS_GRIPPERALWAYS
.clrFore& = 0
.clrBack& = 0
.lpText& = 0
.cch& = 0
.iImage& = 0
.hwndChild& = Edit2&
.cxMinChild& = 0
.cyMinChild& = @Height(ReBar&)
.cx& = 690
.hbmBack& = 0
.wID& = 0
.cyChild& = @Height(ReBar&)
.cyMaxChild& = @Height(ReBar&)
.cyIntegral& = 0
.cxIdeal& = 690
.lParam& = 0
.cxHeader& = 0
@SendMessage(ReBar&,~RB_INSERTBAND,1,ReBar#)
EndWith
SubClassProc
If %sMessage = ~WM_NOTIFY
lpnmhdr# = &sLParam
If lpnmhdr#.hwndFrom& = ReBar&
If Long(&slparam,8) = ~RBN_HEIGHTCHANGE
Clear a#
@SendMessage(ReBar&,~RB_SIZETORECT,0,a#)
@Set("WinProc",0)
EndIf
EndIf
EndIf
ENDPROC
SubClass %hWnd,1
WhileNot %Key = 2
WaitInput
EndWhile
Dispose a#
Dispose ReBar#
Dispose lpnmhdr#
SubClass ReBar&,0
~DestroyWindow(ReBar&)
End
|
| | | | |
|
AnswerThemeninformationenthis Topic has 4 subscriber: |