﻿id	summary	reporter	owner	description	type	status	milestone	component	version	severity	resolution	keywords	cc
1145	GUICtrlCreateTreeView() steals application focus	tayou fabrice	Jpm	"The following code steals focus from the active application even though the GUI isn't visible immediately:
{{{
#cs ----------------------------------------------------------------------------

 AutoIt Version: 3.3.0.0
 Author:         TayouFabrice

After creating a GUICtrlTreeView the GUI take focus it is a problem for an app
whish start on Background and dosn't want ot get focus before being visible
i have put sleep ( ) at line 21 to shaw that gui is not visible but has allready
focus. This problem is serious
#ce ----------------------------------------------------------------------------


#include <GUIConstantsEx.au3>
#include <TreeViewConstants.au3>
#include <WindowsConstants.au3>
#Region ### START Koda GUI section ### Form=
$Form1 = GUICreate(""Form1"", 633, 447, 192, 215)
ConsoleWrite ( ""> GUI is created but have no focus""&@CRLF)
Sleep ( 6000)
$TreeView1 = GUICtrlCreateTreeView(96, 32, 345, 273)
ConsoleWrite ( ""> GUI has already focus""&@CRLF)
Sleep ( 6000)
GUISetState(@SW_SHOW)
#EndRegion ### END Koda GUI section ###

While 1
	$nMsg = GUIGetMsg()
	Switch $nMsg
		Case $GUI_EVENT_CLOSE
			Exit

	EndSwitch
WEnd
}}}"	Bug	closed	3.3.1.2	AutoIt	3.3.1.1	None	Fixed		tayoufabrice tayoufabrice@…
