You have to take a test to get a fishing license in Germany???
I got one by going to the Supermarket and paying $3.21 to the State of Texas for a whole year of everything of legal size that I can catch...
The commercial license costs a bit more but no test is involved there either!!!
Hmmm what a world.
As far as my $0.02: I agree about the editorgadget... count the number of lines in the editorgadget and then capture the text from those lines...
setactivegadget(#Editor_0) does not do this for you?
let me conk something up...
Code: Select all
Enumeration
#Window_0
EndEnumeration
Enumeration
#String_0
#Editor_0
EndEnumeration
Structure VisualDesignerGadgets
Gadget.l
EventFunction.l
EndStructure
Global NewList EventProcedures.VisualDesignerGadgets()
Procedure String_0_Event(Window, Event, Gadget, Type)
Debug "#String_0"
EndProcedure
Procedure Editor_0_Event(Window, Event, Gadget, Type)
Debug "#Editor_0"
If #PB_EventType_RightClick
Debug "RCLICK"
EndIf
EndProcedure
Procedure RegisterGadgetEvent(Gadget, *Function)
If IsGadget(Gadget)
AddElement(EventProcedures())
EventProcedures()\Gadget = Gadget
EventProcedures()\EventFunction = *Function
EndIf
EndProcedure
Procedure CallEventFunction(Window, Event, Gadget, Type)
ForEach EventProcedures()
If EventProcedures()\Gadget = Gadget
CallFunctionFast(EventProcedures()\EventFunction, Window, Event, Gadget, Type)
LastElement(EventProcedures())
EndIf
Next
EndProcedure
Procedure Open_Window_0()
If OpenWindow(#Window_0, 5, 5, 400, 200, "Window 0", #PB_Window_SystemMenu | #PB_Window_ScreenCentered | #PB_Window_TitleBar )
If CreateGadgetList(WindowID(#Window_0))
EditorGadget(#Editor_0, 6, 6, 384, 66, #PB_EventType_RightClick)
SetGadgetItemText(#Editor_0,-1,"EDITOR GADGET: No right-click context menu!") ; *** SHOWS UP NOW
SetGadgetColor(#Editor_0,#PB_Gadget_BackColor,RGB(0,255,0)) ; Should be green!
RegisterGadgetEvent(#Editor_0, @Editor_0_Event())
StringGadget(#String_0, 6, 78, 384, 72, "STRING GADGET: Has a right-click context menu. :)")
SetGadgetColor(#String_0,#PB_Gadget_BackColor,RGB(0,255,0)) ; Green.
RegisterGadgetEvent(#String_0, @String_0_Event())
EndIf
EndIf
EndProcedure
Open_Window_0()
Repeat
Event = WaitWindowEvent()
Gadget = EventGadget()
Type = EventType()
Window = EventWindow()
Select Event
Case #PB_Event_Gadget
CallEventFunction(Window, Event, Gadget, Type)
EndSelect
Until Event = #PB_Event_CloseWindow
End
This does what it is supposed to do??? Your problem may be in the animate window OR in the 3.94 code...
I ended up completely rewriting sections of my FREE POS code... Last week I started a whole new version...
[[[ NEW CODE UPDATE ]]]
Now if you want a right click menu popup... This version checks for R MOUSE... It isn't documented but it does work...