Audacity 3.2.0
Public Member Functions | Public Attributes | Static Public Attributes | List of all members
MessageCommand Class Reference

Command to get a message response. Used for testing, and used internally to create messages for forwarding. More...

#include <MessageCommand.h>

Inheritance diagram for MessageCommand:
[legend]
Collaboration diagram for MessageCommand:
[legend]

Public Member Functions

ComponentInterfaceSymbol GetSymbol () const override
 
TranslatableString GetDescription () const override
 
template<bool Const>
bool VisitSettings (SettingsVisitorBase< Const > &S)
 
bool VisitSettings (SettingsVisitor &S) override
 
bool VisitSettings (ConstSettingsVisitor &S) override
 
void PopulateOrExchange (ShuttleGui &S) override
 
bool Apply (const CommandContext &context) override
 
ManualPageID ManualPage () override
 
- Public Member Functions inherited from AudacityCommand
 AudacityCommand ()
 
virtual ~AudacityCommand ()
 
PluginPath GetPath () const override
 
VendorSymbol GetVendor () const override
 
wxString GetVersion () const override
 
ComponentInterfaceSymbol GetSymbol () const override=0
 
virtual TranslatableString GetDescription () const override
 
virtual ManualPageID ManualPage ()
 
virtual bool IsBatchProcessing () const
 
virtual void SetBatchProcessing (bool start)
 
virtual bool Apply (const CommandContext &WXUNUSED(context))
 
bool ShowInterface (wxWindow *parent, bool forceModal=false)
 
wxDialog * CreateUI (wxWindow *parent, AudacityCommand *client)
 
bool SaveSettingsAsString (wxString &parms)
 
bool LoadSettingsFromString (const wxString &parms)
 
bool DoAudacityCommand (wxWindow *parent, const CommandContext &context, bool shouldPrompt=true)
 
int MessageBox (const TranslatableString &message, long style=DefaultMessageBoxStyle, const TranslatableString &titleStr={})
 
virtual bool Init ()
 
virtual bool PromptUser (wxWindow *parent)
 
virtual bool CheckWhetherSkipAudacityCommand ()
 
virtual void End ()
 
virtual void PopulateOrExchange (ShuttleGui &WXUNUSED(S))
 
virtual bool TransferDataToWindow ()
 
virtual bool TransferDataFromWindow ()
 
virtual bool VisitSettings (SettingsVisitor &)
 
virtual bool VisitSettings (ConstSettingsVisitor &)
 
- Public Member Functions inherited from ComponentInterface
virtual ~ComponentInterface ()
 
virtual PluginPath GetPath () const =0
 
virtual ComponentInterfaceSymbol GetSymbol () const =0
 
virtual VendorSymbol GetVendor () const =0
 
virtual wxString GetVersion () const =0
 
virtual TranslatableString GetDescription () const =0
 
TranslatableString GetName () const
 

Public Attributes

wxString mMessage
 

Static Public Attributes

static const ComponentInterfaceSymbol Symbol { XO("Message") }
 

Additional Inherited Members

- Public Types inherited from AudacityCommand
enum  : long { DefaultMessageBoxStyle = wxOK | wxCENTRE }
 
- Protected Attributes inherited from AudacityCommand
ProgressDialogmProgress
 
wxDialog * mUIDialog
 
wxWindow * mUIParent
 

Detailed Description

Command to get a message response. Used for testing, and used internally to create messages for forwarding.

Command to send a message (currently on the status channel)

Definition at line 27 of file MessageCommand.h.

Member Function Documentation

◆ Apply()

bool MessageCommand::Apply ( const CommandContext context)
override

Definition at line 55 of file MessageCommand.cpp.

55 {
56 context.Status( mMessage );
57 return true;
58}
virtual void Status(const wxString &message, bool bFlush=false) const
wxString mMessage

References mMessage, and CommandContext::Status().

Here is the call graph for this function:

◆ GetDescription()

TranslatableString MessageCommand::GetDescription ( ) const
inlineoverridevirtual

Reimplemented from AudacityCommand.

Definition at line 34 of file MessageCommand.h.

34{return XO("Echos a message.");};
XO("Cut/Copy/Paste")

References XO().

Here is the call graph for this function:

◆ GetSymbol()

ComponentInterfaceSymbol MessageCommand::GetSymbol ( ) const
inlineoverridevirtual

Implements AudacityCommand.

Definition at line 33 of file MessageCommand.h.

33{return Symbol;};
static const ComponentInterfaceSymbol Symbol

References Symbol.

◆ ManualPage()

ManualPageID MessageCommand::ManualPage ( )
inlineoverridevirtual

Reimplemented from AudacityCommand.

Definition at line 42 of file MessageCommand.h.

42{return L"Extra_Menu:_Scriptables_II#message";}

◆ PopulateOrExchange()

void MessageCommand::PopulateOrExchange ( ShuttleGui S)
override

Definition at line 44 of file MessageCommand.cpp.

45{
46 S.AddSpace(0, 5);
47
48 S.StartMultiColumn(2, wxALIGN_CENTER);
49 {
50 S.TieTextBox(XXO("Text:"),mMessage,60);
51 }
52 S.EndMultiColumn();
53}
XXO("&Cut/Copy/Paste Toolbar")
#define S(N)
Definition: ToChars.cpp:64

References mMessage, S, and XXO().

Here is the call graph for this function:

◆ VisitSettings() [1/3]

bool MessageCommand::VisitSettings ( ConstSettingsVisitor )
overridevirtual

Visit settings, if defined. false means no defined settings. Default implementation returns false

Reimplemented from AudacityCommand.

Definition at line 41 of file MessageCommand.cpp.

42 { return VisitSettings<true>(S); }

References S.

◆ VisitSettings() [2/3]

bool MessageCommand::VisitSettings ( SettingsVisitor )
overridevirtual

Visit settings, if defined. false means no defined settings. Default implementation returns false

Reimplemented from AudacityCommand.

Definition at line 38 of file MessageCommand.cpp.

39 { return VisitSettings<false>(S); }

References S.

◆ VisitSettings() [3/3]

template<bool Const>
bool MessageCommand::VisitSettings ( SettingsVisitorBase< Const > &  S)

Definition at line 33 of file MessageCommand.cpp.

33 {
34 S.Define( mMessage, wxT("Text"), wxString{"Some message"} );
35 return true;
36}
wxT("CloseDown"))

References mMessage, S, and wxT().

Here is the call graph for this function:

Member Data Documentation

◆ mMessage

wxString MessageCommand::mMessage

Definition at line 44 of file MessageCommand.h.

Referenced by Apply(), PopulateOrExchange(), and VisitSettings().

◆ Symbol

const ComponentInterfaceSymbol MessageCommand::Symbol { XO("Message") }
static

Definition at line 30 of file MessageCommand.h.

Referenced by GetSymbol().


The documentation for this class was generated from the following files: