| |
|
|
| so can itself integral More begin, as with the Profanversion:
Windowstyle 31
Windowtitle "Trackmenü with Checkfunktion over API"
Window 0,0-640,440
DEF @CreatePopupMenu(0) !"USER32","CreatePopupMenu"
DEF @AppendMenuEx(4) !"USER32","AppendMenuA"
DEF @TrackPopupMenu(7) !"USER32","TrackPopupMenu"
DEF @CheckMenuItem(3) !"USER32","CheckMenuItem"
Declare Checkmerker%
Declare Menuhandle&,ITEM#
the Menu becomes created
LET Menuhandle&=@CreatePopupMenu()
DIM Item#,255
String Item#,0="&Messagebox"
@AppendMenuEx(Menuhandle&,0,101,ITEM#)
Dispose Item#
DIM Item#,255
String Item#,0="&Check"
@AppendMenuEx(Menuhandle&,0,102,ITEM#)
Dispose item#
While @equ(0,0)
Waitinput
IF @equ(%MouseKey,2) rights Mouse button pressed?
@TrackPopupMenu(Menuhandle&,2,%mousex,%Mousey,0,%HWND,0) Menu becomes displayed..
IF @equ(%MENUITEM,102)
LET CHECKMERKER%=@NOT(Checkmerker%) Zustandsänderung remember...
@CheckMenuItem(Menuhandle&,102,@mul(Checkmerker%,8)) Ähnlich How the commands Checkmenü!
ELSEIF @equ(%MENUITEM,101)
@Messagebox("Menüpunkt one clicked!","Hinweis",64)
ENDIF
endif
wend
|
|
|
| |
|
|
|
p.specht
| Revivial for XProfan-10 ff:
Windowstyle 31
Windowtitle "Trackmenü (rights Mouse button!) with Checkfunktion over API"
Window 0,0-640,440
DEF @CreatePopupMenu(0) !"USER32","CreatePopupMenu"
DEF @AppendMenuEx(4) !"USER32","AppendMenuA"
DEF @TrackPopupMenu(7) !"USER32","TrackPopupMenu"
DEF @CheckMenuItem(3) !"USER32","CheckMenuItem"
Declare Checkmerker%
Declare Menuhandle&,ITEM#
'the Menu becomes created
LET Menuhandle&=@CreatePopupMenu()
DIM Item#,255
String Item#,0="&Messagebox"
@AppendMenuEx(Menuhandle&,0,101,ITEM#)
Dispose Item#
DIM Item#,255
String Item#,0="&Check"
@AppendMenuEx(Menuhandle&,0,102,ITEM#)
Dispose item#
While 1
Waitinput
IF %MouseKey=2'rights Mouse button pressed?
@TrackPopupMenu(Menuhandle&,2,%mousex,%Mousey,0,%HWND,0)'Menu becomes displayed..
IF %MENUITEM=102
LET CHECKMERKER%=@NOT(Checkmerker%)'Zustandsänderung remember...
@CheckMenuItem(Menuhandle&,102, Checkmerker%*8)'Similar How the commands Checkmenü!
ELSEIF %MENUITEM=101
@Messagebox("Menüpunkt one clicked!","Hinweis",64)
ENDIF
endif
endwhile
|
|
|
| XProfan 11Computer: Gerät, daß es in Mikrosekunden erlaubt, 50.000 Fehler zu machen, zB 'daß' statt 'das'... | 01/03/19 ▲ |
|
|
|