Audacity 3.2.0
Public Types | Public Member Functions | Public Attributes | List of all members
TrackListEvent Struct Reference

Notification of changes in individual tracks of TrackList, or of TrackList's composition. More...

#include <Track.h>

Collaboration diagram for TrackListEvent:
[legend]

Public Types

enum  Type {
  SELECTION_CHANGE , TRACK_DATA_CHANGE , TRACK_REQUEST_VISIBLE , PERMUTED ,
  RESIZING , ADDITION , DELETION
}
 

Public Member Functions

 TrackListEvent (Type type, const std::weak_ptr< Track > &pTrack={}, int extra=-1)
 
 TrackListEvent (const TrackListEvent &)=default
 

Public Attributes

const Type mType
 
const std::weak_ptr< TrackmpTrack
 
const int mExtra
 

Detailed Description

Notification of changes in individual tracks of TrackList, or of TrackList's composition.

Definition at line 1281 of file Track.h.

Member Enumeration Documentation

◆ Type

Enumerator
SELECTION_CHANGE 

Posted when the set of selected tracks changes.

TRACK_DATA_CHANGE 

Posted when certain fields of a track change.

TRACK_REQUEST_VISIBLE 

Posted when a track needs to be scrolled into view.

PERMUTED 

Posted when tracks are reordered but otherwise unchanged.

mpTrack points to the moved track that is earliest in the New ordering.

RESIZING 

Posted when some track changed its height.

ADDITION 

Posted when a track has been added to a tracklist. Also posted when one track replaces another.

DELETION 

Posted when a track has been deleted from a tracklist. Also posted when one track replaces another.

mpTrack points to the first track after the deletion, if there is one.

Definition at line 1283 of file Track.h.

1283 {
1286
1289
1292
1294
1295 PERMUTED,
1296
1298 RESIZING,
1299
1301 ADDITION,
1302
1304
1305 DELETION,
1306 };
@ RESIZING
Posted when some track changed its height.
Definition: Track.h:1298
@ SELECTION_CHANGE
Posted when the set of selected tracks changes.
Definition: Track.h:1285
@ DELETION
Posted when a track has been deleted from a tracklist. Also posted when one track replaces another.
Definition: Track.h:1305
@ ADDITION
Posted when a track has been added to a tracklist. Also posted when one track replaces another.
Definition: Track.h:1301
@ PERMUTED
Posted when tracks are reordered but otherwise unchanged.
Definition: Track.h:1295
@ TRACK_REQUEST_VISIBLE
Posted when a track needs to be scrolled into view.
Definition: Track.h:1291
@ TRACK_DATA_CHANGE
Posted when certain fields of a track change.
Definition: Track.h:1288

Constructor & Destructor Documentation

◆ TrackListEvent() [1/2]

TrackListEvent::TrackListEvent ( Type  type,
const std::weak_ptr< Track > &  pTrack = {},
int  extra = -1 
)
inline

Definition at line 1308 of file Track.h.

1309 {}, int extra = -1)
1310 : mType{ type }
1311 , mpTrack{ pTrack }
1312 , mExtra{ extra }
1313 {}
const int mExtra
Definition: Track.h:1319
const std::weak_ptr< Track > mpTrack
Definition: Track.h:1318
const Type mType
Definition: Track.h:1317

◆ TrackListEvent() [2/2]

TrackListEvent::TrackListEvent ( const TrackListEvent )
default

Member Data Documentation

◆ mExtra

const int TrackListEvent::mExtra

Definition at line 1319 of file Track.h.

Referenced by TrackPanel::OnEnsureVisible().

◆ mpTrack

const std::weak_ptr<Track> TrackListEvent::mpTrack

◆ mType

const Type TrackListEvent::mType

The documentation for this struct was generated from the following file: