View Issue Details

IDProjectCategoryView StatusLast Update
0017554LazarusLCLpublic2011-01-30 12:16
ReporterAlexander KoblovAssigned ToZeljan Rikalo 
PrioritynormalSeverityminorReproducibilityalways
Status closedResolutionfixed 
Platformi386OSLinuxOS VersionUbuntu 10.04.1
Product Version0.9.29 (SVN)Product Build27551 
Target Version0.9.30Fixed in Version0.9.29 (SVN) 
Summary0017554: [Qt] Don't work scrolling of TDrawGrid by mouse wheel
DescriptionIf scroll DrawGrid at last row then scroll up by mouse wheel don't work.
Steps To Reproduce1. Add TDrawGrid on a form and set RowCount for example 50, so scrollbar is showed.
2. Scroll DrawGrid at last row.
3. Try to scroll up by mouse wheel.
Additional InformationQt 4.6.2
TagsNo tags attached.
Fixed in Revision27628,29104
LazTarget0.9.30
WidgetsetQT
Attached Files

Relationships

related to 0018880 closedZeljan Rikalo tcustomcontrol.domousewheel is not called 

Activities

Zeljan Rikalo

2010-10-06 16:39

developer   ~0041543

Please attach example.

2010-10-06 16:58

 

scrollbug.tar.bz2 (79,101 bytes)

Zeljan Rikalo

2010-10-08 22:12

developer   ~0041628

Ok, I've found root of problem, but if I fix TDrawGrid (and other TQtCustomControls) then cannot scroll anymore in source editor..so must discuss this with martin first.

Zeljan Rikalo

2010-10-08 22:59

developer   ~0041630

Please test and close if ok.

Alexander Koblov

2010-10-10 17:52

reporter   ~0041693

Thanks, it works now

Alexander Koblov

2010-10-30 20:41

reporter   ~0042451

I found that this bug is still present if setup TDrawGrid.MouseWheelOption = mwGrid

cobines

2010-12-26 07:54

reporter   ~0044594

This is a bug in TCustomGrid.WMVScroll and TCustomGrid.WMHScroll introduced in rev. 26739 while fixing 0011092. If I revert 26739 scrolling works fine, even when I revert Zeljko's change in commit 27628.

@Zeljko,
LCLGTK2 generates LM_MOUSEWHEEL event for the TCustomGrid, that's why it works fine with GTK2 because different code in TCustomGrid handles the scrolling. Can LCLQT do the same?

Zeljan Rikalo

2010-12-26 12:14

developer   ~0044597

@cobines, qt generates mousewheel msg too (that's why this issue was about), I've fixed that.Gtk2 probably sends more events so it works. What's about win32 ?

cobines

2010-12-26 18:00

reporter   ~0044604

Last edited: 2010-12-26 18:32

GTK2 sends LM_WHEEL. If it's not handled (handler returns False), then LM_VSCROLL (SB_THUMBPOSITION) is sent.

QT4 sends LM_VSCROLL and then LM_WHEEL (after commit 27628). Maybe it should be either the first or the second one. Or send LM_WHEEL, if not handled then translate it into LM_VSCROLL if the window is scrollable.

Win32 does not send LM_WHEEL. It is translated into a series of LMVSCROLL messages: SB_LINEUP, SB_ENDSCROLL, ... . For me it sends 8 SB_LINEUP/DOWN (probably system settings).

(Edit: Corrected GTK2 info)

Maxim Ganetsky

2011-01-17 22:29

developer   ~0045270

Suspected regression.

Zeljan Rikalo

2011-01-18 08:16

developer   ~0045272

Last edited: 2011-01-18 10:11

I cannot reproduce with Qt-4.7.2, wheel works ok with mwGrid and mwCursor.
What's your qt version ?
Update: reproduced ... fixation in progress

Zeljan Rikalo

2011-01-18 10:25

developer   ~0045275

Please test and close if ok.

Alexander Koblov

2011-01-24 21:41

reporter   ~0045453

OK, scrolling is works now. But the behavior of scrolling by mouse wheel with mwCursor mode under Qt is not the same as under GTK2/Win32. Under GTK2/Win32 only cursor moves at first time, and only when it moves to the end of current page then grid is scrolled. So I can select needed row by mouse wheel. Under Qt the grid is scrolling immediately and cursor moves behind the grid.

Alexander Koblov

2011-01-30 12:16

reporter   ~0045594

As I see incorrect behavior is fixed (I think it is related with issue 0018571).

Issue History

Date Modified Username Field Change
2010-10-06 16:00 Alexander Koblov New Issue
2010-10-06 16:00 Alexander Koblov Widgetset => QT
2010-10-06 16:39 Zeljan Rikalo LazTarget => -
2010-10-06 16:39 Zeljan Rikalo Note Added: 0041543
2010-10-06 16:39 Zeljan Rikalo Status new => feedback
2010-10-06 16:39 Zeljan Rikalo Status feedback => assigned
2010-10-06 16:39 Zeljan Rikalo Assigned To => Zeljan Rikalo
2010-10-06 16:58 Alexander Koblov File Added: scrollbug.tar.bz2
2010-10-08 22:12 Zeljan Rikalo Note Added: 0041628
2010-10-08 22:59 Zeljan Rikalo Fixed in Revision => 27628
2010-10-08 22:59 Zeljan Rikalo Status assigned => resolved
2010-10-08 22:59 Zeljan Rikalo Resolution open => fixed
2010-10-08 22:59 Zeljan Rikalo Note Added: 0041630
2010-10-10 17:52 Alexander Koblov Status resolved => closed
2010-10-10 17:52 Alexander Koblov Note Added: 0041693
2010-10-30 20:41 Alexander Koblov Status closed => assigned
2010-10-30 20:41 Alexander Koblov Resolution fixed => reopened
2010-10-30 20:41 Alexander Koblov Note Added: 0042451
2010-12-26 07:54 cobines Note Added: 0044594
2010-12-26 12:14 Zeljan Rikalo Note Added: 0044597
2010-12-26 18:00 cobines Note Added: 0044604
2010-12-26 18:31 cobines Note Edited: 0044604
2010-12-26 18:32 cobines Note Edited: 0044604
2011-01-17 22:29 Maxim Ganetsky LazTarget - => 0.9.30
2011-01-17 22:29 Maxim Ganetsky Note Added: 0045270
2011-01-17 22:29 Maxim Ganetsky Target Version => 0.9.30
2011-01-18 08:16 Zeljan Rikalo Note Added: 0045272
2011-01-18 08:16 Zeljan Rikalo Status assigned => feedback
2011-01-18 10:11 Zeljan Rikalo Note Edited: 0045272
2011-01-18 10:25 Zeljan Rikalo Fixed in Revision 27628 => 27628,29104
2011-01-18 10:25 Zeljan Rikalo Status feedback => resolved
2011-01-18 10:25 Zeljan Rikalo Resolution reopened => fixed
2011-01-18 10:25 Zeljan Rikalo Note Added: 0045275
2011-01-24 13:39 Vincent Snijders Fixed in Version => 0.9.29 (SVN)
2011-01-24 21:41 Alexander Koblov Note Added: 0045453
2011-01-30 12:16 Alexander Koblov Status resolved => closed
2011-01-30 12:16 Alexander Koblov Note Added: 0045594
2011-03-07 08:39 Zeljan Rikalo Relationship added related to 0018880