Add wxGrid::RefreshBlock() helper

This simple function combines BlockToDeviceRect() and
wxWindow::Refresh() calls and allows to avoid the ugly casts in
wxGridSelection code as well as making the code slightly shorter and
more clear.

No real changes.
This commit is contained in:
lucian-rotariu
2019-07-11 01:13:54 +02:00
committed by Vadim Zeitlin
parent cf3709147a
commit 00224e3f30
3 changed files with 40 additions and 78 deletions

View File

@@ -1112,6 +1112,11 @@ public:
const wxArrayString& lines,
long *width, long *height ) const;
void RefreshBlock(const wxGridCellCoords& topLeft,
const wxGridCellCoords& bottomRight);
void RefreshBlock(int topRow, int leftCol,
int bottomRow, int rightCol);
// ------
// Code that does a lot of grid modification can be enclosed