Add ardour/template_utils.h that contains ARDOUR::user_template_directory and ARDOUR::system_template_directory
git-svn-id: svn://localhost/ardour2/trunk@2015 d708f5d6-7413-0410-9779-e7cbd77b26cf
This commit is contained in:
parent
f21746ad7c
commit
0681da3e62
@ -33,6 +33,7 @@ diskstream.cc
|
||||
directory_names.cc
|
||||
filename_extensions.cc
|
||||
find_session.cc
|
||||
template_utils.cc
|
||||
track.cc
|
||||
audio_diskstream.cc
|
||||
audio_library.cc
|
||||
|
20
libs/ardour/ardour/template_utils.h
Normal file
20
libs/ardour/ardour/template_utils.h
Normal file
@ -0,0 +1,20 @@
|
||||
|
||||
#ifndef TEMPLATE_UTILS_INCLUDED
|
||||
#define TEMPLATE_UTILS_INCLUDED
|
||||
|
||||
#include <vector>
|
||||
|
||||
#include <pbd/filesystem.h>
|
||||
|
||||
namespace ARDOUR {
|
||||
|
||||
using std::vector;
|
||||
using namespace PBD;
|
||||
|
||||
sys::path system_template_directory ();
|
||||
|
||||
sys::path user_template_directory ();
|
||||
|
||||
} // namespace ARDOUR
|
||||
|
||||
#endif
|
28
libs/ardour/template_utils.cc
Normal file
28
libs/ardour/template_utils.cc
Normal file
@ -0,0 +1,28 @@
|
||||
|
||||
#include <pbd/filesystem.h>
|
||||
|
||||
#include <ardour/template_utils.h>
|
||||
#include <ardour/ardour.h>
|
||||
#include <ardour/directory_names.h>
|
||||
|
||||
namespace ARDOUR {
|
||||
|
||||
sys::path
|
||||
system_template_directory ()
|
||||
{
|
||||
sys::path p(get_system_data_path());
|
||||
p /= templates_dir_name;
|
||||
|
||||
return p;
|
||||
}
|
||||
|
||||
sys::path
|
||||
user_template_directory ()
|
||||
{
|
||||
sys::path p(get_user_ardour_path());
|
||||
p /= templates_dir_name;
|
||||
|
||||
return p;
|
||||
}
|
||||
|
||||
} // namespace ARDOUR
|
Loading…
Reference in New Issue
Block a user