Audacity 3.2.0
|
#include <ShareAudioDialog.h>
Classes | |
class | ExportProgressUpdater |
struct | InitialStatePanel |
struct | ProgressPanel |
struct | Services |
Public Member Functions | |
ShareAudioDialog (AudacityProject &project, AudiocomTrace, 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 audacity::cloud::audiocom::ShareAudioDialog::InitialStatePanel | mInitialStatePanel |
struct audacity::cloud::audiocom::ShareAudioDialog::ProgressPanel | mProgressPanel |
wxButton * | mContinueButton { nullptr } |
wxButton * | mCancelButton { nullptr } |
std::unique_ptr< Services > | mServices |
const AudiocomTrace | mAudiocomTrace |
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 40 of file ShareAudioDialog.h.
|
private |
Definition at line 116 of file ShareAudioDialog.h.
audacity::cloud::audiocom::ShareAudioDialog::ShareAudioDialog | ( | AudacityProject & | project, |
AudiocomTrace | trace, | ||
wxWindow * | parent = nullptr |
||
) |
Definition at line 168 of file ShareAudioDialog.cpp.
|
override |
Definition at line 216 of file ShareAudioDialog.cpp.
References audacity::cloud::audiocom::GetAuthorizationHandler(), mFilePath, and audacity::cloud::audiocom::AuthorizationHandler::PopSuppressDialogs().
|
private |
Definition at line 313 of file ShareAudioDialog.cpp.
References audacity::cloud::audiocom::anonymous_namespace{ShareAudioDialog.cpp}::CalculateChannels(), Error, ExportProgressUI::ExceptionWrappedCall(), audacity::cloud::audiocom::anonymous_namespace{ShareAudioDialog.cpp}::GenerateTempPath(), ExportPluginRegistry::Get(), ProjectRate::Get(), TrackList::Get(), audacity::cloud::audiocom::ServiceConfig::GetExportConfig(), anonymous_namespace{TimeTrack.cpp}::GetRate(), audacity::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 499 of file ShareAudioDialog.cpp.
References BasicUI::ModalError, BasicUI::ShowErrorDialog(), and XO().
Referenced by StartUploadProcess().
|
private |
Definition at line 470 of file ShareAudioDialog.cpp.
References audacity::cloud::audiocom::UploadFailedPayload::additionalErrors, audacity::cloud::audiocom::UploadFailedPayload::message, BasicUI::ModalError, BasicUI::ShowErrorDialog(), and XO().
|
private |
Definition at line 463 of file ShareAudioDialog.cpp.
References audacity::cloud::audiocom::UploadSuccessfulPayload::audioUrl, and BasicUI::OpenInDefaultBrowser().
|
private |
Definition at line 270 of file ShareAudioDialog.cpp.
References mExportProgressUpdater, mInProgress, mServices, and XO().
Referenced by Populate().
|
private |
Definition at line 297 of file ShareAudioDialog.cpp.
References mContinueAction.
Referenced by Populate().
|
private |
Definition at line 224 of file ShareAudioDialog.cpp.
References ShuttleGuiBase::AddButton(), ShuttleGui::AddSpace(), ShuttleGuiBase::EndHorizontalLay(), ShuttleGuiBase::EndInvisiblePanel(), AudacityProject::GetProjectName(), audacity::cloud::audiocom::ShareAudioDialog::InitialStatePanel::HasValidTitle(), mCancelButton, mContinueButton, mInitialStatePanel, mIsAuthorised, mProgressPanel, mProject, OnCancel(), OnContinue(), audacity::cloud::audiocom::ShareAudioDialog::InitialStatePanel::PopulateInitialStatePanel(), audacity::cloud::audiocom::ShareAudioDialog::ProgressPanel::PopulateProgressPanel(), ShuttleGuiBase::SetBorder(), ShuttleGuiBase::StartHorizontalLay(), ShuttleGuiBase::StartInvisiblePanel(), title, audacity::cloud::audiocom::ShareAudioDialog::InitialStatePanel::trackTitle, and XXO().
|
private |
Definition at line 509 of file ShareAudioDialog.cpp.
References BasicUI::Yield().
Referenced by StartUploadProcess().
|
private |
Definition at line 388 of file ShareAudioDialog.cpp.
References Cancelled, ExportProject(), audacity::cloud::audiocom::ShareAudioDialog::InitialStatePanel::GetTrackTitle(), HandleExportFailure(), audacity::cloud::audiocom::ShareAudioDialog::ProgressPanel::info, mContinueButton, mExportProgressUpdater, mFilePath, mInitialStatePanel, mInProgress, mProgressPanel, mServices, ResetProgress(), audacity::cloud::audiocom::ShareAudioDialog::InitialStatePanel::root, audacity::cloud::audiocom::ShareAudioDialog::ProgressPanel::root, audacity::cloud::audiocom::ShareAudioDialog::ProgressPanel::title, and XO().
|
private |
Definition at line 537 of file ShareAudioDialog.cpp.
References audacity::cloud::audiocom::anonymous_namespace{ShareAudioDialog.cpp}::SetTimeLabel(), and XO().
Referenced by audacity::cloud::audiocom::ShareAudioDialog::ExportProgressUpdater::UpdateUI().
|
private |
Definition at line 111 of file ShareAudioDialog.h.
|
private |
Definition at line 107 of file ShareAudioDialog.h.
Referenced by Populate().
|
private |
Definition at line 124 of file ShareAudioDialog.h.
Referenced by OnContinue().
|
private |
Definition at line 106 of file ShareAudioDialog.h.
Referenced by Populate(), and StartUploadProcess().
|
private |
Definition at line 114 of file ShareAudioDialog.h.
Referenced by ExportProject(), OnCancel(), and StartUploadProcess().
|
private |
Definition at line 122 of file ShareAudioDialog.h.
Referenced by StartUploadProcess(), and ~ShareAudioDialog().
|
private |
Referenced by Populate(), and StartUploadProcess().
|
private |
Definition at line 127 of file ShareAudioDialog.h.
Referenced by OnCancel(), and StartUploadProcess().
|
private |
Definition at line 126 of file ShareAudioDialog.h.
Referenced by Populate().
|
private |
Definition at line 120 of file ShareAudioDialog.h.
|
private |
Definition at line 119 of file ShareAudioDialog.h.
|
private |
Referenced by Populate(), and StartUploadProcess().
|
private |
Definition at line 64 of file ShareAudioDialog.h.
Referenced by ExportProject(), and Populate().
|
private |
Definition at line 110 of file ShareAudioDialog.h.
Referenced by OnCancel(), and StartUploadProcess().
|
private |
Definition at line 118 of file ShareAudioDialog.h.