develooper Front page | perl.wxperl.users | Postings from March 2013

Re: Getting information from EVT_LIST_ITEM_RIGHT_CLICK

Thread Previous | Thread Next
Mark Dootson
March 5, 2013 21:01
Re: Getting information from EVT_LIST_ITEM_RIGHT_CLICK
Message ID:

Attached updated code uses ListCtrl->GetItemRect to determine correct 
offset when control is scrolled.



On 05/03/2013 20:14, Dave Hayes wrote:
> On 02/04/13 19:45, Mark Dootson wrote:
>> Hi,
>> A small update to previous code. On wxGTK EVT_LIST_ITEM_RIGHT_CLICK
>> events are generated even if a right click in the wxListCtrl is not on
>> an item. Amended attachment handles this.
> I've run into a bug with your implementation.
> If you add enough columns to invoke the horizontal scrollbar, this
> breaks what you wrote. Instead, columns will be reported with 0 being
> the visible scrolled column, which is not the actual column.
> Googling around a bit seems to indicate that it's impossible to get a
> scroll event from a ListCtrl at 2.8. So how would I detect that the
> ListCtrl is scrolled horizontally?

Thread Previous | Thread Next Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at | Group listing | About