Audacity 3.2.0
|
#include <ShareAudioDialog.h>
Classes | |
class | ExportProgressUpdater |
struct | InitialStatePanel |
struct | ProgressPanel |
struct | Services |
Public Member Functions | |
ShareAudioDialog (AudacityProject &project, wxWindow *parent=nullptr) | |
~ShareAudioDialog () override | |
Public Member Functions inherited from wxDialogWrapper | |
wxDialogWrapper () | |
wxDialogWrapper (wxWindow *parent, wxWindowID id, const TranslatableString &title, const wxPoint &pos=wxDefaultPosition, const wxSize &size=wxDefaultSize, long style=wxDEFAULT_DIALOG_STYLE, const TranslatableString &name=XO("Dialog")) | |
bool | Create (wxWindow *parent, wxWindowID id, const TranslatableString &title, const wxPoint &pos=wxDefaultPosition, const wxSize &size=wxDefaultSize, long style=wxDEFAULT_DIALOG_STYLE, const TranslatableString &name=XO("Dialog")) |
void | SetTitle (const TranslatableString &title) |
void | SetLabel (const TranslatableString &title) |
void | SetName (const TranslatableString &title) |
void | SetName () |
Public Member Functions inherited from wxTabTraversalWrapper< wxDialog > | |
wxTabTraversalWrapper (Args &&... args) | |
wxTabTraversalWrapper (const wxTabTraversalWrapper &)=delete | |
wxTabTraversalWrapper (wxTabTraversalWrapper &&)=delete | |
wxTabTraversalWrapper & | operator= (const wxTabTraversalWrapper &)=delete |
wxTabTraversalWrapper & | operator= (wxTabTraversalWrapper &&)=delete |
Private Types | |
using | Clock = std::chrono::steady_clock |
Private Member Functions | |
void | Populate (ShuttleGui &s) |
void | OnCancel () |
void | OnContinue () |
wxString | ExportProject () |
void | StartUploadProcess () |
void | HandleUploadSucceeded (const UploadSuccessfulPayload &payload) |
void | HandleUploadFailed (const UploadFailedPayload &payload) |
void | HandleExportFailure () |
void | ResetProgress () |
void | UpdateProgress (uint64_t current, uint64_t total) |
Private Attributes | |
AudacityProject & | mProject |
struct cloud::audiocom::ShareAudioDialog::InitialStatePanel | mInitialStatePanel |
struct cloud::audiocom::ShareAudioDialog::ProgressPanel | mProgressPanel |
wxButton * | mContinueButton { nullptr } |
wxButton * | mCancelButton { nullptr } |
std::unique_ptr< Services > | mServices |
std::unique_ptr< ExportProgressUpdater > | mExportProgressUpdater |
Clock::time_point | mStageStartTime |
Clock::time_point | mLastUIUpdateTime |
int | mLastProgressValue { 0 } |
wxString | mFilePath |
std::function< void()> | mContinueAction |
bool | mIsAuthorised { false } |
bool | mInProgress { false } |
Definition at line 39 of file ShareAudioDialog.h.
|
private |
Definition at line 118 of file ShareAudioDialog.h.
cloud::audiocom::ShareAudioDialog::ShareAudioDialog | ( | AudacityProject & | project, |
wxWindow * | parent = nullptr |
||
) |
Definition at line 170 of file ShareAudioDialog.cpp.
|
override |
Definition at line 217 of file ShareAudioDialog.cpp.
References cloud::audiocom::GetAuthorizationHandler(), mFilePath, and cloud::audiocom::AuthorizationHandler::PopSuppressDialogs().
|
private |
Definition at line 314 of file ShareAudioDialog.cpp.
References cloud::audiocom::anonymous_namespace{ShareAudioDialog.cpp}::CalculateChannels(), Error, ExportProgressUI::ExceptionWrappedCall(), cloud::audiocom::anonymous_namespace{ShareAudioDialog.cpp}::GenerateTempPath(), ExportPluginRegistry::Get(), ProjectRate::Get(), TrackList::Get(), cloud::audiocom::ServiceConfig::GetExportConfig(), anonymous_namespace{TimeTrack.cpp}::GetRate(), cloud::audiocom::GetServiceConfig(), mExportProgressUpdater, mProject, ExportTaskBuilder::SetFileName(), ExportTaskBuilder::SetNumChannels(), ExportTaskBuilder::SetParameters(), ExportTaskBuilder::SetPlugin(), ExportTaskBuilder::SetRange(), ExportTaskBuilder::SetSampleRate(), Success, and tracks.
Referenced by StartUploadProcess().
|
private |
Definition at line 503 of file ShareAudioDialog.cpp.
References BasicUI::ModalError, BasicUI::ShowErrorDialog(), and XO().
Referenced by StartUploadProcess().
|
private |
Definition at line 474 of file ShareAudioDialog.cpp.
References cloud::audiocom::UploadFailedPayload::additionalErrors, cloud::audiocom::UploadFailedPayload::message, BasicUI::ModalError, BasicUI::ShowErrorDialog(), and XO().
|
private |
Definition at line 467 of file ShareAudioDialog.cpp.
References cloud::audiocom::UploadSuccessfulPayload::audioUrl, and BasicUI::OpenInDefaultBrowser().
|
private |
Definition at line 271 of file ShareAudioDialog.cpp.
References mExportProgressUpdater, mInProgress, mServices, and XO().
Referenced by Populate().
|
private |
Definition at line 298 of file ShareAudioDialog.cpp.
References mContinueAction.
Referenced by Populate().
|
private |
Definition at line 225 of file ShareAudioDialog.cpp.
References ShuttleGuiBase::AddButton(), ShuttleGui::AddSpace(), ShuttleGuiBase::EndHorizontalLay(), ShuttleGuiBase::EndInvisiblePanel(), AudacityProject::GetProjectName(), cloud::audiocom::ShareAudioDialog::InitialStatePanel::HasValidTitle(), mCancelButton, mContinueButton, mInitialStatePanel, mIsAuthorised, mProgressPanel, mProject, OnCancel(), OnContinue(), cloud::audiocom::ShareAudioDialog::InitialStatePanel::PopulateInitialStatePanel(), cloud::audiocom::ShareAudioDialog::ProgressPanel::PopulateProgressPanel(), ShuttleGuiBase::SetBorder(), ShuttleGuiBase::StartHorizontalLay(), ShuttleGuiBase::StartInvisiblePanel(), title, cloud::audiocom::ShareAudioDialog::InitialStatePanel::trackTitle, and XXO().
|
private |
Definition at line 513 of file ShareAudioDialog.cpp.
References BasicUI::Yield().
Referenced by StartUploadProcess().
|
private |
Definition at line 389 of file ShareAudioDialog.cpp.
References Cancelled, ExportProject(), cloud::audiocom::ShareAudioDialog::InitialStatePanel::GetTrackTitle(), HandleExportFailure(), cloud::audiocom::ShareAudioDialog::ProgressPanel::info, mContinueButton, mExportProgressUpdater, mFilePath, mInitialStatePanel, mInProgress, mProgressPanel, mServices, ResetProgress(), cloud::audiocom::ShareAudioDialog::InitialStatePanel::root, cloud::audiocom::ShareAudioDialog::ProgressPanel::root, cloud::audiocom::ShareAudioDialog::ProgressPanel::title, and XO().
|
private |
Definition at line 541 of file ShareAudioDialog.cpp.
References cloud::audiocom::anonymous_namespace{ShareAudioDialog.cpp}::SetTimeLabel(), and XO().
Referenced by cloud::audiocom::ShareAudioDialog::ExportProgressUpdater::UpdateUI().
|
private |
Definition at line 110 of file ShareAudioDialog.h.
Referenced by Populate().
|
private |
Definition at line 126 of file ShareAudioDialog.h.
Referenced by OnContinue().
|
private |
Definition at line 109 of file ShareAudioDialog.h.
Referenced by Populate(), and StartUploadProcess().
|
private |
Definition at line 116 of file ShareAudioDialog.h.
Referenced by ExportProject(), OnCancel(), and StartUploadProcess().
|
private |
Definition at line 124 of file ShareAudioDialog.h.
Referenced by StartUploadProcess(), and ~ShareAudioDialog().
|
private |
Referenced by Populate(), and StartUploadProcess().
|
private |
Definition at line 129 of file ShareAudioDialog.h.
Referenced by OnCancel(), and StartUploadProcess().
|
private |
Definition at line 128 of file ShareAudioDialog.h.
Referenced by Populate().
|
private |
Definition at line 122 of file ShareAudioDialog.h.
|
private |
Definition at line 121 of file ShareAudioDialog.h.
|
private |
Referenced by Populate(), and StartUploadProcess().
|
private |
Definition at line 62 of file ShareAudioDialog.h.
Referenced by ExportProject(), and Populate().
|
private |
Definition at line 113 of file ShareAudioDialog.h.
Referenced by OnCancel(), and StartUploadProcess().
|
private |
Definition at line 120 of file ShareAudioDialog.h.