mirror of
https://github.com/cookiengineer/audacity
synced 2026-02-06 03:32:09 +01:00
... in cases such as: dragging an envelope point, then hitting space to play, which forces the drag to finish early. If you move the mouse, cursor will remain "ban", even while the mouse button remains down but no drag is really happening.
42 lines
935 B
C++
42 lines
935 B
C++
/**********************************************************************
|
|
|
|
Audacity: A Digital Audio Editor
|
|
|
|
TrackPanelMouseEvent.h
|
|
|
|
Paul Licameli
|
|
|
|
**********************************************************************/
|
|
|
|
#ifndef __AUDACITY_TRACK_PANEL_MOUSE_EVENT__
|
|
#define __AUDACITY_TRACK_PANEL_MOUSE_EVENT__
|
|
|
|
class wxMouseEvent;
|
|
class wxRect;
|
|
class wxSize;
|
|
class TrackPanelCell;
|
|
|
|
// Augment a mouse event with information about which track panel cell and
|
|
// sub-rectangle was hit.
|
|
struct TrackPanelMouseEvent
|
|
{
|
|
TrackPanelMouseEvent
|
|
( wxMouseEvent &event_, const wxRect &rect_, const wxSize &whole_,
|
|
TrackPanelCell *pCell_ )
|
|
: event{ event_ }
|
|
, rect{ rect_ }
|
|
, whole{ whole_ }
|
|
, pCell{ pCell_ }
|
|
, steps{ 0 }
|
|
{
|
|
}
|
|
|
|
wxMouseEvent &event;
|
|
const wxRect ▭
|
|
const wxSize &whole;
|
|
TrackPanelCell *pCell; // may be NULL
|
|
double steps; // for mouse wheel rotation
|
|
};
|
|
|
|
#endif
|