diff options
author | Lionel Elie Mamane <lionel@mamane.lu> | 2012-07-24 17:15:55 +0200 |
---|---|---|
committer | Lionel Elie Mamane <lionel@mamane.lu> | 2012-07-24 17:35:57 +0200 |
commit | 9bd5e75b95d7b380f9be95913c949221dc4c0d67 (patch) | |
tree | a8e59c05adeec086ee01477efcacea39a5bc2b12 | |
parent | e8ddf693e69ea768e4cb1bd4c0445990149af07d (diff) |
forcing repaint has catastrophic performance implications; invalidate only
In Base:
1) Open a big table (hundreds of rows)
2) Only the first 40 to 100 rows are fetched into the cache and shown
(depending on screen / window size).
3) Move to last row (click on icon |>|)
4) The last 40 to 100 rows are fetched into the cache; the data of the
first 40/100 rows is pushed out of the cache.
5) The first 40 to 100 rows are fetched, just so that the call to
rWindow.Paint() can do its job, because they are not in the cache
anymore (!). The last 40/100 rows are pushed out of the cache.
6) The last 40 to 100 rows are fetched into the cache and displayed;
the first 40/100 rows are pushed out of the cache *again*.
Steps 5 and 6 are obviously *very* stupid.
Change-Id: Ic11b893ea9440c2c5a142bd3c77c95d6730aa723
-rw-r--r-- | svtools/source/brwbox/editbrowsebox.cxx | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/svtools/source/brwbox/editbrowsebox.cxx b/svtools/source/brwbox/editbrowsebox.cxx index 129b9f445d03..3560f2d1672b 100644 --- a/svtools/source/brwbox/editbrowsebox.cxx +++ b/svtools/source/brwbox/editbrowsebox.cxx @@ -927,8 +927,6 @@ namespace svt if (nNewRow != nEditRow) { Window& rWindow = GetDataWindow(); - // don't paint too much - // update the status immediatly if possible if ((nEditRow >= 0) && (GetBrowserFlags() & EBBF_NO_HANDLE_COLUMN_CONTENT) == 0) { Rectangle aRect = GetFieldRectPixel(nEditRow, 0, sal_False ); @@ -937,7 +935,7 @@ namespace svt // probably because it is part of a bitfield pTHIS->bPaintStatus = static_cast< sal_Bool > (( GetBrowserFlags() & EBBF_HANDLE_COLUMN_TEXT ) == EBBF_HANDLE_COLUMN_TEXT ); - rWindow.Paint(aRect); + rWindow.Invalidate(aRect); pTHIS->bPaintStatus = sal_True; } |