I created a Window & image inside it.
image event on click, gives MessageBox.
The PROBLEM is that, once you close the MessageBox & hover-over the image by Mouse (quickly), the MessageBox trigger again!!
Any help?
Here is my CODE:
Code: Select all
Enumeration
#WIN_MAIN
#BUTTON_CLOSE
EndEnumeration
Global Quit.b = #False
#FLAGS = #PB_Window_SystemMenu | #PB_Window_ScreenCentered
If OpenWindow(#WIN_MAIN, 0, 0, 200, 80, "Repeated Message Issue!", #FLAGS)
ButtonGadget(#BUTTON_CLOSE, 70, 30, 60, 20, "Close"):SetClassLong_(hWnd, #GCL_HCURSOR, LoadCursor_(0, #IDC_HAND))
Img_Window_1_0 = LoadImage(#PB_Any,"C:\Settings.bmp")
Image_0 = ImageGadget(#PB_Any, 10, 18, 20, 20, ImageID(Img_Window_1_0))
Repeat
Event.l = WaitWindowEvent()
Select Event
Case #PB_Event_Gadget
Select EventGadget()
Case #BUTTON_CLOSE
MessageRequester("", "im a button.") ; This Message are Not Repeated.
Case Image_0
MessageRequester("", "im an image.") ; This Message are Repeated (the Problem here ...)
EndSelect
EndSelect
Until Event = #PB_Event_CloseWindow
EndIf
End

