13
0

Move 'template_search_path()' and 'route_template_search_path()' into 'libs/ardour/search_paths.cc'

This commit is contained in:
John Emmas 2014-03-10 15:59:12 +00:00
parent b32d9a1c70
commit 34c67ba854
3 changed files with 29 additions and 16 deletions

View File

@ -93,6 +93,18 @@ namespace ARDOUR {
*/
LIBARDOUR_API PBD::Searchpath panner_search_path ();
/**
* return a Searchpath containing directories in which to look for
* route templates.
*/
LIBARDOUR_API PBD::Searchpath route_template_search_path ();
/**
* return a Searchpath containing directories in which to look for
* other templates.
*/
LIBARDOUR_API PBD::Searchpath template_search_path ();
} // namespace ARDOUR
#endif /* __libardour_search_paths_h__ */

View File

@ -147,6 +147,22 @@ panner_search_path ()
return spath;
}
Searchpath
template_search_path ()
{
Searchpath spath (ardour_data_search_path());
spath.add_subdirectory_to_paths(templates_dir_name);
return spath;
}
Searchpath
route_template_search_path ()
{
Searchpath spath (ardour_data_search_path());
spath.add_subdirectory_to_paths(route_templates_dir_name);
return spath;
}
#ifdef PLATFORM_WINDOWS
const char*

View File

@ -30,6 +30,7 @@
#include "ardour/directory_names.h"
#include "ardour/filesystem_paths.h"
#include "ardour/filename_extensions.h"
#include "ardour/search_paths.h"
#include "ardour/io.h"
using namespace std;
@ -37,22 +38,6 @@ using namespace PBD;
namespace ARDOUR {
Searchpath
template_search_path ()
{
Searchpath spath (ardour_data_search_path());
spath.add_subdirectory_to_paths(templates_dir_name);
return spath;
}
Searchpath
route_template_search_path ()
{
Searchpath spath (ardour_data_search_path());
spath.add_subdirectory_to_paths(route_templates_dir_name);
return spath;
}
std::string
user_template_directory ()
{