11#ifndef __AUDACITY_PROJECT_WINDOW__
12#define __AUDACITY_PROJECT_WINDOW__
21class wxSplitterWindow;
45 wxWindow * parent, wxWindowID
id,
46 const wxPoint & pos,
const wxSize &
size,
53 bool IsActive()
override;
54 bool IsIconized()
const override;
63 wxWindow* GetTrackListWindow() noexcept;
69 wxSplitterWindow* GetContainerWindow() noexcept;
74 wxPanel *GetTopPanel() noexcept;
76 void UpdateStatusWidths();
109 double mRecentStreamTime{ -1.0 };
117 void ApplyUpdatedTheme();
124 void OnScrollLeftButton(wxScrollEvent & event);
125 void OnScrollRightButton(wxScrollEvent & event);
127 std::pair<int, int> ViewportSize()
const;
129 bool IsTrackMinimized(
const Track &track) ;
130 void SetMinimized(
Track &track,
bool minimized) ;
131 int GetTrackHeight(
const Track &track) ;
132 void SetChannelHeights(
Track &track,
unsigned height) ;
133 int GetTotalHeight(
const TrackList &trackList) ;
134 int GetHorizontalThumbPosition()
const ;
135 int GetHorizontalThumbSize()
const ;
136 int GetHorizontalRange()
const ;
137 void SetHorizontalThumbPosition(
int viewStart) ;
138 void SetHorizontalScrollbar(
int position,
int thumbSize,
139 int range,
int pageSize,
bool refresh) ;
140 void ShowHorizontalScrollbar(
bool shown) ;
142 int GetVerticalThumbPosition()
const ;
143 int GetVerticalThumbSize()
const ;
144 int GetVerticalRange()
const ;
145 void SetVerticalThumbPosition(
int viewStart) ;
146 void SetVerticalScrollbar(
int position,
int thumbSize,
147 int range,
int pageSize,
bool refresh) ;
148 void ShowVerticalScrollbar(
bool shown) ;
150 void SetToDefaultSize();
157 wxStatusBar* CreateProjectStatusBar();
167 void OnMenu(wxCommandEvent & event);
168 void OnUpdateUI(wxUpdateUIEvent & event);
170 void MacShowUndockedToolbars(
bool show);
171 void OnActivate(wxActivateEvent & event);
173 void OnMouseEvent(wxMouseEvent & event);
174 void OnIconize(wxIconizeEvent &event);
175 void OnSize(wxSizeEvent & event);
177 void OnShow(wxShowEvent & event);
178 void OnMove(wxMoveEvent & event);
179 void OnScroll(wxScrollEvent & event);
180 void OnToolBarUpdate(wxCommandEvent & event);
186 wxPanel *mTopPanel{};
188 wxWindow* mTrackListWindow{};
190 wxScrollBar *mHsbar{};
191 wxScrollBar *mVsbar{};
195 bool mActive{
true };
196 bool mIconized{
false };
197 bool mShownOnce{
false };
201 bool mIsDeleting{
false };
214 DECLARE_EVENT_TABLE()
ProjectFileIOMessage
Subscribe to ProjectFileIO to receive messages; always in idle time.
AUDACITY_DLL_API IntSetting ProjectWindowNormalWidth
void InitProjectWindow(ProjectWindow &window)
AUDACITY_DLL_API IntSetting ProjectWindowNormalHeight
AUDACITY_DLL_API IntSetting ProjectWindowHeight
void GetDefaultWindowRect(wxRect *defRect)
AUDACITY_DLL_API IntSetting ProjectWindowX
AUDACITY_DLL_API IntSetting ProjectWindowNormalX
void GetNextWindowPlacement(wxRect *nextRect, bool *pMaximized, bool *pIconized)
AUDACITY_DLL_API IntSetting ProjectWindowWidth
AUDACITY_DLL_API IntSetting ProjectWindowY
AUDACITY_DLL_API BoolSetting ProjectWindowMaximized
AUDACITY_DLL_API BoolSetting ProjectWindowIconized
AUDACITY_DLL_API IntSetting ProjectWindowNormalY
static void OnSize(wxSizeEvent &evt)
The top-level handle to an Audacity project. It serves as a source of events that other objects can b...
This specialization of Setting for bool adds a Toggle method to negate the saved value.
Specialization of Setting for int.
An object that sends messages to an open-ended list of subscribed callbacks.
A move-only handle representing a connection to a Publisher.
A listener notified of changes in preferences.
virtual void UpdatePrefs()=0
A top-level window associated with a project.
A top-level window associated with a project, and handling scrollbars and zooming.
wxScrollBar & GetHorizontalScrollBar()
PlaybackScroller & GetPlaybackScroller()
wxSplitterWindow * mContainerWindow
void RefreshTPTrack(Track *pTrk, bool refreshbacking=true)
wxScrollBar & GetVerticalScrollBar()
Observer::Subscription mThemeChangeSubscription
wxRect GetNormalizedWindowState() const
void SetNormalizedWindowState(wxRect pSizeAndLocation)
wxSize GetTPTracksUsableArea()
bool IsBeingDeleted() const
Observer::Subscription mTitleChangeSubscription
std::unique_ptr< PlaybackScroller > mPlaybackScroller
Observer::Subscription mSnappingChangedSubscription
wxRect mNormalizedWindowState
const Observer::Subscription mViewportSubscription
UI Panel that displays realtime effects from the effect stack of an individual track,...
Abstract base class for an object holding data associated with points on a time axis.
A flat linked list of tracks supporting Add, Remove, Clear, and Contains, serialization of the list o...
PROJECT_FILE_IO_API wxString Find(const FilePath &path)
Services * Get()
Fetch the global instance, or nullptr if none is yet installed.
AUDACITY_DLL_API unsigned MinimumTrackHeight()
TranslatableString Message(unsigned trackCount)
Default message type for Publisher.
Message sent when the project window is closed.