1
0
mirror of https://github.com/cookiengineer/audacity synced 2025-10-22 14:32:58 +02:00

Added Steve Parry's patch that adds the Open and SaveAs commands to scripting.

This commit is contained in:
james.k.crook@gmail.com
2014-01-13 22:12:20 +00:00
parent 30e6a3dec4
commit 6fc830c0b6
6 changed files with 212 additions and 0 deletions

View File

@@ -0,0 +1,65 @@
/**********************************************************************
Audacity: A Digital Audio Editor
Audacity(R) is copyright (c) 1999-2009 Audacity Team.
File License: wxwidgets
OpenSaveCommands.h
Stephen Parry
******************************************************************//**
\class OpenProjectCommand
\brief Command for opening an Audacity project
\class SaveProjectCommand
\brief Command for saving an Audacity project
*//*******************************************************************/
#include "Command.h"
#include "CommandType.h"
// Open
class OpenProjectCommandType : public CommandType
{
public:
virtual wxString BuildName();
virtual void BuildSignature(CommandSignature &signature);
virtual Command *Create(CommandOutputTarget *target);
};
class OpenProjectCommand : public CommandImplementation
{
public:
OpenProjectCommand(CommandType &type,
CommandOutputTarget *target)
: CommandImplementation(type, target)
{ }
virtual ~OpenProjectCommand();
virtual bool Apply(CommandExecutionContext context);
};
// Save
class SaveProjectCommandType : public CommandType
{
public:
virtual wxString BuildName();
virtual void BuildSignature(CommandSignature &signature);
virtual Command *Create(CommandOutputTarget *target);
};
class SaveProjectCommand : public CommandImplementation
{
public:
SaveProjectCommand(CommandType &type,
CommandOutputTarget *target)
: CommandImplementation(type, target)
{ }
virtual ~SaveProjectCommand();
virtual bool Apply(CommandExecutionContext context);
};