Custom Query


Show under each result:

Results (148 - 150 of 3868)

Ticket Resolution Summary Owner Reporter
#510 Fixed _GUICtrlListView_ClickItem: If columns inside listview exceed visible area, clicks outside of the control Gary michael.sunwoo@…

In the function _GUICtrlListView_ClickItem, if the columns inside the listview exceed visible area, the mouse click can happen outside of the control area.

Sample code is below.

#AutoIt3Wrapper_au3check_parameters=-d -w 1 -w 2 -w 3 -w 4 -w 5 -w 6
#include <GuiConstantsEx.au3>
#include <GuiListView.au3>
#include <WindowsConstants.au3>

Opt('MustDeclareVars', 1)

Global $hListView


Func _Main()
	; Create GUI
	GUICreate("ListView Click Item", 400, 300)
	$hListView = GUICtrlCreateListView("", 2, 2, 394, 268)

	; Add columns
	_GUICtrlListView_InsertColumn($hListView, 0, "Column 1", 100)
	_GUICtrlListView_InsertColumn($hListView, 1, "Column 2", 500)
	_GUICtrlListView_InsertColumn($hListView, 2, "Column 3", 500)
	; Add items
	_GUICtrlListView_AddItem($hListView, "Row 1: Col 1", 0)
	_GUICtrlListView_AddItem($hListView, "Row 2: Col 1", 1)
	_GUICtrlListView_AddItem($hListView, "Row 3: Col 1", 2)
	_GUICtrlListView_ClickItem($hListView, 1, "left", False, 2)
	; Loop until user exits
EndFunc   ;==>_Main

The expected behavior is it clicks within the currently visible area of the listview control, not the center of the width of all the columns.

This reproduces on BETA v3.2.13.7 and RELEASE v3.2.12.1.

Is there a more programmatic way to select a listview item instead of using a MouseClick (inside the _GUICtrlListView_ClickItem UDF)?

#516 Fixed _ChooseFont 64bit Vista Gary Gary

_ChooseFont does not work. The function return a value as if the user canceled selection even though no sign of the dialog box appears.

#517 Fixed WinAPI UDF - bad error checking after DllCall() Gary Zedna

This line is missing in many functions after DllCall:

If @error Then Return SetError(@error, 0, 0)


Func _WinAPI_LoadLibrary($sFileName)
	Local $aResult

	$aResult = DllCall("Kernel32.dll", "hwnd", "LoadLibraryA", "str", $sFileName)
	Return $aResult[0]
EndFunc   ;==>_WinAPI_LoadLibrary

Correct way:

Func _WinAPI_LoadLibrary($sFileName)
	Local $aResult

	$aResult = DllCall("Kernel32.dll", "hwnd", "LoadLibraryA", "str", $sFileName)
	If @error Then Return SetError(@error, 0, 0)
	Return $aResult[0]
EndFunc   ;==>_WinAPI_LoadLibrary

Mainly it should be corrected in these functions (but this is missing in many others):

_WinAPI_LoadImage _WinAPI_LoadLibrary _WinAPI_LoadLibraryEx _WinAPI_FreeLibrary

I need to have a chance to check if @error occured when calling these functions:

$hInstance = _WinAPI_LoadLibrary("some.dll")
If @error Then ...

Note: If error occurs during DllCall() then accesing $aResult[0] will hard crash my script.

Note: See TracQuery for help on using queries.