Modify

Opened 12 years ago

Closed 12 years ago

#2470 closed Bug (No Bug)

$GUI_EVENT_(PRIMARY and SECONDARY)DOWN not triggered after WinActivate

Reported by: TommyDDR Owned by:
Milestone: Component: AutoIt
Version: 3.3.8.1 Severity: None
Keywords: Cc:

Description

$GUI_EVENT_PRIMARYDOWN and $GUI_EVENT_SECONDARYDOWN are skiped one time after a WinActivate (only if clic on a control)

#include <GUIConstantsEx.au3>

Opt("GUIOnEventMode", 1)
Opt("MustDeclareVars", 1)

Global $Gui = GUICreate("test", 300, 300)
GUISetOnEvent($GUI_EVENT_CLOSE, "quit")
GUISetOnEvent($GUI_EVENT_SECONDARYDOWN, "Clic")
GUICtrlCreateLabel("", 0, 0, 300, 300)
GUISetState()

While(True)
	Sleep(10)
WEnd

Func Clic()
	ConsoleWrite("Clic" & @CRLF)
	WinActivate("[CLASS:Progman]")
EndFunc

Func quit()
	Exit
EndFunc

Run this script, clic on time on the GUI, "Clic" is displayed, desktop is activated, re-clic on GUI, nothing append. (Working Wrong)
Stop script, comment line "WinActivate", re-run the script, clic on GUI, "Clic is displayed, clic on desktop, re-clic on GUI, "Clic is displayed". (Working)

If Label is removed, work perfectly.

Change History (1)

comment:1 Changed 12 years ago by Jpm

  • Resolution set to No Bug
  • Status changed from new to closed

Nothing wrong as your WinActivate is activating the desktop deactivating your GUI so clicking again just reactivate without really doing a click on the gui and the next click on the gui will redo a click event

You better go to the forum to ask help before submitting a ticket

Guidelines for posting comments:

  • You cannot re-open a ticket but you may still leave a comment if you have additional information to add.
  • In-depth discussions should take place on the forum.

For more information see the full version of the ticket guidelines here.

Add Comment

Author


E-mail address and user name can be saved in the Preferences.

 
Note: See TracTickets for help on using tickets.