Split wxGrid RANGE_SELECT event into SELECTING and SELECTED

This will allow the applications that are only interested in the final
selection to ignore the intermediate SELECTING events, which are now
sent as soon as the selection changes while dragging the mouse, and only
handle the final SELECTED ones, when the drag is over.
This commit is contained in:
Daniel Kulp
2020-07-27 12:20:01 -04:00
committed by Vadim Zeitlin
parent 5192feb38e
commit 415f080c80
5 changed files with 89 additions and 14 deletions

View File

@@ -103,6 +103,9 @@ public:
wxVectorGridBlockCoords& GetBlocks() { return m_selection; }
void StartSelecting();
void EndSelecting();
private:
void SelectBlockNoEvent(const wxGridBlockCoords& block)
{
@@ -138,6 +141,7 @@ private:
wxGrid *m_grid;
wxGrid::wxGridSelectionModes m_selectionMode;
bool m_isSelecting;
wxDECLARE_NO_COPY_CLASS(wxGridSelection);
};