Project

General

Profile

Actions

Bug #7361

closed

Regression: WTableView scrollTo fails to scroll under some conditions

Added by Bruce Toll about 5 years ago. Updated almost 5 years ago.

Status:
Closed
Priority:
Normal
Assignee:
-
Target version:
Start date:
12/10/2019
Due date:
% Done:

0%

Estimated time:

Description

There appears to be a regression with WTableView's scrollTo where it can fail to scroll correctly under some circumstances. An attached test program should help demonstrate the issue. The test program includes instructions for reproducing the problem (a window height of 600px or more is recommended). Testing was done with github master 4.2.0-1-g0b709fd4.

It appears that the regression was introduced with commit 9144a445 (and is also present in 4.1.2 with commit d9e9b770). Reverting commit 9144a445 seems to fix the behavior of the test program. The issue appears to be due to stale local values of scrollTop, etc. interacting with WTableView's autoJavaScript. The behavior is timing dependent.

I've attached a patch (0001-Additional-logging-for-WTableView-scrollTo-issue.patch) that adds some console logging to WTableView that may be helpful in debugging. The autoJavaScript messages are probably the most useful, as they appear to be directly related to the failure cases.

I also tested a potential fix: 0001-Fix-intermittent-scrollTo-failures-in-WTableView.patch. However I am not able to reproduce the original issue that commit 9144a445 was intended to address, so I don't know if it handles that issue successfully.


Files

Actions #1

Updated by Roel Standaert almost 5 years ago

  • Target version set to 4.2.1
Actions #2

Updated by Roel Standaert almost 5 years ago

  • Status changed from New to Resolved

I think I was being overly careful in commit 9144a445. I don't think there's really any reason why we're connecting headerContainer.onscroll, so I just removed that altogether.

Actions #3

Updated by Bruce Toll almost 5 years ago

Thanks, Roel. I can confirm that your update works well with the original apps as well as the test case.

Actions #4

Updated by Roel Standaert almost 5 years ago

  • Status changed from Resolved to Closed
Actions

Also available in: Atom PDF