summaryrefslogtreecommitdiffstats
path: root/src/LashDriver.h
diff options
context:
space:
mode:
authorDavid Robillard <d@drobilla.net>2007-04-06 02:20:48 +0000
committerDavid Robillard <d@drobilla.net>2007-04-06 02:20:48 +0000
commit1019f1b943ae17bb116bbd2223fcbd0532657055 (patch)
tree5989fd5989d46f7f0b3a653a0b8fd934727a2d49 /src/LashDriver.h
parent9f7241e83ba62f51852430398f4badfe68320e0f (diff)
downloadpatchage-1019f1b943ae17bb116bbd2223fcbd0532657055.tar.gz
patchage-1019f1b943ae17bb116bbd2223fcbd0532657055.tar.bz2
patchage-1019f1b943ae17bb116bbd2223fcbd0532657055.zip
LASH project saving/restoring.
git-svn-id: http://svn.drobilla.net/lad/patchage@400 a436a847-0d15-0410-975c-d299462d15a1
Diffstat (limited to 'src/LashDriver.h')
-rw-r--r--src/LashDriver.h23
1 files changed, 18 insertions, 5 deletions
diff --git a/src/LashDriver.h b/src/LashDriver.h
index cac5bfd..dde644a 100644
--- a/src/LashDriver.h
+++ b/src/LashDriver.h
@@ -19,6 +19,7 @@
#define LASHDRIVER_H
#include <lash/lash.h>
+#include <raul/LashServerInterface.h>
#include "Driver.h"
class Patchage;
@@ -32,7 +33,7 @@ public:
void attach(bool launch_daemon);
void detach();
- bool is_attached() const { return lash_enabled(_client); }
+ bool is_attached() const { return _server_interface->enabled(); }
bool connect(boost::shared_ptr<PatchagePort>, boost::shared_ptr<PatchagePort>)
{ return false; }
@@ -42,12 +43,24 @@ public:
void refresh() {}
- void process_events();
+ void process_events() { _server_interface->process_events(); }
+
+ void restore_project(const std::string& directory);
+ void set_project_directory(const std::string& directory);
+ void save_project();
+ void close_project();
private:
- Patchage* _app;
- lash_client_t* _client;
- lash_args_t* _args;
+ Patchage* _app;
+ std::string _project_name;
+
+ lash_args_t* _args;
+ SharedPtr<Raul::LashServerInterface> _server_interface;
+
+ void on_project_add(const SharedPtr<Raul::LashProject> project);
+ void on_save_file(const std::string& directory);
+ void on_restore_file(const std::string& directory);
+ void on_quit();
void handle_event(lash_event_t* conf);
void handle_config(lash_config_t* conf);