$Window = GUICreate('',600,375,-1,-1)
$ButtonAbout = GUICtrlCreateButton('?',10,10,26,26)
$InputSearch = GUICtrlCreateInput('Введите фразу для поиска ...',46,12,454,22)
GUICtrlSetColor($InputSearch,0x999999)
$ButtonExit = GUICtrlCreateButton('Отмена',240,120,100,26)
GUIRegisterMsg(0x0111,'WM_COMMAND')
GUISetState(@SW_SHOW,$Window)
While 1
Switch GUIGetMsg()
Case -3, $ButtonExit
ExitLoop
EndSwitch
WEnd
Func WM_COMMAND($Param1,$Param2,$Param3,$Param4)
If BitAND($Param3,0x0000FFFF) = $InputSearch Then
If BitShift($Param3,0x18) = 1 Then ;фокус
If GUICtrlRead($InputSearch) = 'Введите фразу для поиска ...' Then
GUICtrlSetData($InputSearch,'')
GUICtrlSetColor($InputSearch,0x000000)
EndIf
ElseIf BitShift($Param3,0x18) = 2 Then ; потеря фокуса
If GUICtrlRead($InputSearch) = '' Then
GUICtrlSetData($InputSearch,'Введите фразу для поиска ...')
GUICtrlSetColor($InputSearch,0x999999)
EndIf
EndIf
EndIf
EndFunc