Reviewing merge request #1575: Fixed incorrect behavior of QHeaderView if ResizeToContents and stretchLastSection is active
Removed lastSectionSize (used when stretchLastSection activated).
lastSectionSize was used in one place. Value was incorrectly updated or not updated at all. Was replaced by value calculated immediately before use.
Before fix, qheaderview behaved incorrectly if ResizeToContents and stretchLastSection was activated.
Commits that would be merged:
Comments
Please add a test case
(I have not looked the code in details)
‘by test case, i mean a test in tests/auto/qheaderview
doing what you testcase programatically should not be difficult
I tried to merge.
But the emails in the commits is wrong.
Can you please fix that.
You can also squash the two commit into one, and rebase on top of the current 4.6 branch
(and there is also some leading spaces)
+ {
The coding style is not respected, the brace need to be on the same line as the if
+ int sectionSize = headerSectionSize(i);
This code is the same as the one a little bit after, but a little bit different.
However, the code after that does only call headerSectionSize() is required.
I think you should refactor this if to avoid code duplication here.
(and only put the lebghtToStrentch and numberOfStretchedSections in different branches)
Thank you for your contribution. With Qt 4 having moved [1] under Open
Governance [2] as well, you can now contribute your changes via Gerrit
[3]. At the same time, contributions via Gitorious can no longer be
merged.
We would still like to see your patch on the new platform, and wish
for you to become a member of the Qt Project. Please read [4] and in
particular [5] to familiarize yourself with the new tools. You will
still find a read-only mirror of all Qt repositories on Gitorious.
With a much wider set of possible reviewers, we are also looking
forward to better response times to contributions. Looking forward to
your patch!
Please note that at this point in time Qt 4.8 is a bugfix only branch,
and all fixes should be submitted to Qt 5 first, as far as
applicable. Qt 4 master is closed.
The Nokia Qt team
[1] http://labs.qt.nokia.com/2012/01/10/qt-4-moved-to-open-governance/
[2] http://labs.qt.nokia.com/2011/10/21/the-qt-project-is-live/
[3] http://codereview.qt-project.org
[4] http://www.qt-project.org
[5] http://developer.qt.nokia.com/wiki/Gerrit_Introduction


Add a new comment:
Login or create an account to post a comment