'libs/pbd' - DLL visibility stuff and associated changes needed for building with MSVC. Currently includes debugging information and things that are just commented out until we have known compatibility with the other platforms (i.e. contains stuff to be removed at a later date)
This commit is contained in:
parent
b855e5f322
commit
6bd36896e7
|
@ -146,4 +146,4 @@ EnvironmentalProtectionAgency::clear () const
|
|||
string before = estring.substr (0, equal);
|
||||
g_unsetenv(before.c_str());
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -521,7 +521,7 @@ gchar *pUsrHome = 0;
|
|||
// relevant index.
|
||||
// On Failure: NULL
|
||||
//
|
||||
PBD_API G_CONST_RETURN gchar* PBD_APICALLTYPE
|
||||
LIBPBD_API G_CONST_RETURN gchar* PBD_APICALLTYPE
|
||||
get_platform_fallback_folder (PBD::fallback_folder_t index)
|
||||
{
|
||||
if ((index >= 0) && (index < FALLBACK_FOLDER_MAX))
|
||||
|
@ -546,7 +546,7 @@ get_platform_fallback_folder (PBD::fallback_folder_t index)
|
|||
//
|
||||
// The value obtained from 'get_platform_fallback_folders()'
|
||||
//
|
||||
PBD_API G_CONST_RETURN gchar* G_CONST_RETURN * PBD_APICALLTYPE
|
||||
LIBPBD_API G_CONST_RETURN gchar* G_CONST_RETURN * PBD_APICALLTYPE
|
||||
alloc_platform_fallback_folders ()
|
||||
{
|
||||
return ((G_CONST_RETURN gchar* G_CONST_RETURN *)get_platform_fallback_folders ());
|
||||
|
@ -564,7 +564,7 @@ alloc_platform_fallback_folders ()
|
|||
//
|
||||
// NONE.
|
||||
//
|
||||
PBD_API void PBD_APICALLTYPE
|
||||
LIBPBD_API void PBD_APICALLTYPE
|
||||
free_platform_fallback_folders ()
|
||||
{
|
||||
int index = FOLDER_LOCALE;
|
||||
|
|
|
@ -49,7 +49,7 @@ struct timezone
|
|||
int tz_dsttime; /* type of dst correction */
|
||||
};
|
||||
|
||||
PBD_API int PBD_APICALLTYPE
|
||||
LIBPBD_API int PBD_APICALLTYPE
|
||||
gettimeofday(struct timeval *__restrict tv, __timezone_ptr_t tz) // Does this need to be exported ?
|
||||
{
|
||||
FILETIME ft;
|
||||
|
@ -94,22 +94,22 @@ static int tzflag = 0;
|
|||
#ifndef PTHREAD_H // Defined by PTW32 (Linux and other versions define _PTHREAD_H)
|
||||
#error "An incompatible version of 'pthread.h' is #included. Use only the Windows (ptw32) version!"
|
||||
#else
|
||||
bool operator> (const pthread_t& lhs, const pthread_t& rhs)
|
||||
LIBPBD_API bool operator> (const pthread_t& lhs, const pthread_t& rhs)
|
||||
{
|
||||
return (std::greater<void*>()(lhs.p, rhs.p));
|
||||
}
|
||||
|
||||
bool operator< (const pthread_t& lhs, const pthread_t& rhs)
|
||||
LIBPBD_API bool operator< (const pthread_t& lhs, const pthread_t& rhs)
|
||||
{
|
||||
return (std::less<void*>()(lhs.p, rhs.p));
|
||||
}
|
||||
|
||||
bool operator!= (const pthread_t& lhs, const pthread_t& rhs)
|
||||
LIBPBD_API bool operator!= (const pthread_t& lhs, const pthread_t& rhs)
|
||||
{
|
||||
return (std::not_equal_to<void*>()(lhs.p, rhs.p));
|
||||
}
|
||||
|
||||
bool operator== (const pthread_t& lhs, const pthread_t& rhs)
|
||||
LIBPBD_API bool operator== (const pthread_t& lhs, const pthread_t& rhs)
|
||||
{
|
||||
return (!(lhs != rhs));
|
||||
}
|
||||
|
@ -166,7 +166,7 @@ char invert_forwardslash(char character)
|
|||
// On Success: The number of bytes read from the file
|
||||
// On Failure: -1
|
||||
//
|
||||
PBD_API ssize_t PBD_APICALLTYPE
|
||||
LIBPBD_API ssize_t PBD_APICALLTYPE
|
||||
pread(int handle, void *buf, size_t nbytes, off_t offset)
|
||||
{
|
||||
int old_errno;
|
||||
|
@ -201,7 +201,7 @@ ssize_t ret;
|
|||
// On Success: The number of bytes written to the file
|
||||
// On Failure: -1
|
||||
//
|
||||
PBD_API ssize_t PBD_APICALLTYPE
|
||||
LIBPBD_API ssize_t PBD_APICALLTYPE
|
||||
pwrite(int handle, const void *buf, size_t nbytes, off_t offset)
|
||||
{
|
||||
int old_errno;
|
||||
|
@ -235,7 +235,7 @@ ssize_t ret;
|
|||
// equal to 'x'.
|
||||
// On Failure: None
|
||||
//
|
||||
PBD_API double PBD_APICALLTYPE
|
||||
LIBPBD_API double PBD_APICALLTYPE
|
||||
round(double x)
|
||||
{
|
||||
return (floor(x));
|
||||
|
@ -255,7 +255,7 @@ namespace PBD {
|
|||
// On Success: TRUE (if the user's OS matches the minimum spec)
|
||||
// On Failure: FALSE otherwise
|
||||
//
|
||||
PBD_API bool PBD_APICALLTYPE
|
||||
LIBPBD_API bool PBD_APICALLTYPE
|
||||
TestForMinimumSpecOS(char *revision /* currently ignored */)
|
||||
{
|
||||
bool bRet = true;
|
||||
|
@ -289,7 +289,7 @@ bool bRet = true;
|
|||
// On Success: A pointer to the resolved (absolute) path
|
||||
// On Failure: NULL
|
||||
//
|
||||
PBD_API char* PBD_APICALLTYPE
|
||||
LIBPBD_API char* PBD_APICALLTYPE
|
||||
realpath (const char *original_path, char resolved_path[_MAX_PATH+1])
|
||||
{
|
||||
char *pRet = NULL;
|
||||
|
@ -332,7 +332,7 @@ bool bIsSymLink = 0; // We'll probably need to test the incoming path
|
|||
// On Success: Pointer to a (heap based) DIR structure
|
||||
// On Failure: NULL
|
||||
//
|
||||
PBD_API DIR* PBD_APICALLTYPE
|
||||
LIBPBD_API DIR* PBD_APICALLTYPE
|
||||
opendir (const char *szPath)
|
||||
{
|
||||
wchar_t wpath[PATH_MAX+1];
|
||||
|
@ -424,7 +424,7 @@ DIR *pDir = 0;
|
|||
// On Success: A pointer to the supplied DIR's 'dirent' struct
|
||||
// On Failure: NULL
|
||||
//
|
||||
PBD_API struct dirent* PBD_APICALLTYPE
|
||||
LIBPBD_API struct dirent* PBD_APICALLTYPE
|
||||
readdir (DIR* pDir)
|
||||
{
|
||||
int old_errno = 0;
|
||||
|
@ -502,7 +502,7 @@ errno = 0;
|
|||
// On Success: 0
|
||||
// On Failure: -1
|
||||
//
|
||||
PBD_API int PBD_APICALLTYPE
|
||||
LIBPBD_API int PBD_APICALLTYPE
|
||||
closedir (DIR *pDir)
|
||||
{
|
||||
int rc = 0;
|
||||
|
@ -536,7 +536,7 @@ int rc = 0;
|
|||
// On Success: A file descriptor for the opened file.
|
||||
// On Failure: (-1)
|
||||
//
|
||||
PBD_API int PBD_APICALLTYPE
|
||||
LIBPBD_API int PBD_APICALLTYPE
|
||||
mkstemp (char *template_name)
|
||||
{
|
||||
int ret = (-1);
|
||||
|
@ -567,7 +567,7 @@ char szTempPath[PATH_MAX+100]; // Just ensure we have plenty of buffer space
|
|||
// On Success: Non-zero.
|
||||
// On Failure: Zero (call 'GetLastError()' to retrieve info)
|
||||
//
|
||||
PBD_API int PBD_APICALLTYPE
|
||||
LIBPBD_API int PBD_APICALLTYPE
|
||||
ntfs_link (const char *existing_filepath, const char *link_filepath)
|
||||
{
|
||||
int ret = 1; // 'ERROR_INVALID_FUNCTION'
|
||||
|
@ -697,7 +697,7 @@ bool bValidPath = false;
|
|||
// On Success: Non-zero.
|
||||
// On Failure: Zero (call 'GetLastError()' to retrieve info)
|
||||
//
|
||||
PBD_API int PBD_APICALLTYPE
|
||||
LIBPBD_API int PBD_APICALLTYPE
|
||||
ntfs_unlink (const char *link_filepath)
|
||||
{
|
||||
int ret = 1; // 'ERROR_INVALID_FUNCTION'
|
||||
|
@ -820,7 +820,7 @@ bool bValidPath = false;
|
|||
// On Success: A handle to the opened DLL
|
||||
// On Failure: NULL
|
||||
//
|
||||
PBD_API void* PBD_APICALLTYPE
|
||||
LIBPBD_API void* PBD_APICALLTYPE
|
||||
dlopen (const char *file_name, int mode)
|
||||
{
|
||||
// Note that 'mode' is ignored in Win32
|
||||
|
@ -839,7 +839,7 @@ dlopen (const char *file_name, int mode)
|
|||
// On Success: A non-zero number
|
||||
// On Failure: 0
|
||||
//
|
||||
PBD_API int PBD_APICALLTYPE
|
||||
LIBPBD_API int PBD_APICALLTYPE
|
||||
dlclose (void *handle)
|
||||
{
|
||||
return (::FreeLibrary((HMODULE)handle));
|
||||
|
@ -857,7 +857,7 @@ dlclose (void *handle)
|
|||
// On Success: A pointer to the found function or symbol
|
||||
// On Failure: NULL
|
||||
//
|
||||
PBD_API void* PBD_APICALLTYPE
|
||||
LIBPBD_API void* PBD_APICALLTYPE
|
||||
dlsym (void *handle, const char *symbol_name)
|
||||
{
|
||||
// First test for RTLD_DEFAULT and RTLD_NEXT
|
||||
|
@ -883,7 +883,7 @@ static char szLastWinError[LOCAL_ERROR_BUF_SIZE];
|
|||
// last error
|
||||
// On Failure: NULL (if the last error was ERROR_SUCCESS)
|
||||
//
|
||||
PBD_API char* PBD_APICALLTYPE
|
||||
LIBPBD_API char* PBD_APICALLTYPE
|
||||
dlerror ()
|
||||
{
|
||||
DWORD dwLastErrorId = GetLastError();
|
||||
|
|
|
@ -172,7 +172,7 @@ int ret = 0; // This functionality is not yet implemented
|
|||
// writing or had data available for reading.
|
||||
// On Failure: -1 (the actual error is saved in 'errno').
|
||||
//
|
||||
PBD_API int PBD_APICALLTYPE
|
||||
LIBPBD_API int PBD_APICALLTYPE
|
||||
poll (struct pollfd *fds, nfds_t nfds, int timeout)
|
||||
{
|
||||
int elapsed_time = 0;
|
||||
|
|
|
@ -34,7 +34,7 @@
|
|||
// if the type of object being contained has no appropriate comparison operators
|
||||
// defined (specifically, if operators '<' and '==' are undefined). This seems
|
||||
// to be the case with ptw32 'pthread_t' which is a simple struct.
|
||||
DECLARE_DEFAULT_COMPARISONS(pthread_t)
|
||||
DECLARE_DEFAULT_COMPARISONS(ptw32_handle_t)
|
||||
#endif
|
||||
|
||||
using namespace std;
|
||||
|
|
|
@ -52,7 +52,7 @@
|
|||
class Touchable;
|
||||
|
||||
template<typename RequestObject>
|
||||
class ABSTRACT_UI_API AbstractUI : public BaseUI /* see notes in visibility.h about why this is not LIBPBD_API */
|
||||
class /*ABSTRACT_UI_API*/ AbstractUI : public BaseUI /* see notes in visibility.h about why this is not LIBPBD_API */
|
||||
{
|
||||
public:
|
||||
AbstractUI (const std::string& name);
|
||||
|
|
|
@ -97,7 +97,7 @@ struct LIBPBD_API AngularVector {
|
|||
}
|
||||
};
|
||||
|
||||
LIBPBD_API inline void CartesianVector::angular (AngularVector& a) const {
|
||||
inline void CartesianVector::angular (AngularVector& a) const {
|
||||
cartesian_to_spherical (x, y, z, a.azi, a.ele, a.length);
|
||||
}
|
||||
|
||||
|
|
|
@ -204,7 +204,7 @@ namespace StringPrivate
|
|||
// a series of functions which accept a format string on the form "text %1
|
||||
// more %2 less %3" and a number of templated parameters and spits out the
|
||||
// composited string
|
||||
template <typename T1> LIBPBD_API
|
||||
template <typename T1>
|
||||
inline std::string string_compose(const std::string &fmt, const T1 &o1)
|
||||
{
|
||||
StringPrivate::Composition c(fmt);
|
||||
|
@ -212,7 +212,7 @@ namespace StringPrivate
|
|||
return c.str();
|
||||
}
|
||||
|
||||
template <typename T1, typename T2> LIBPBD_API
|
||||
template <typename T1, typename T2>
|
||||
inline std::string string_compose(const std::string &fmt,
|
||||
const T1 &o1, const T2 &o2)
|
||||
{
|
||||
|
@ -221,7 +221,7 @@ namespace StringPrivate
|
|||
return c.str();
|
||||
}
|
||||
|
||||
template <typename T1, typename T2, typename T3> LIBPBD_API
|
||||
template <typename T1, typename T2, typename T3>
|
||||
inline std::string string_compose(const std::string &fmt,
|
||||
const T1 &o1, const T2 &o2, const T3 &o3)
|
||||
{
|
||||
|
@ -230,7 +230,7 @@ namespace StringPrivate
|
|||
return c.str();
|
||||
}
|
||||
|
||||
template <typename T1, typename T2, typename T3, typename T4> LIBPBD_API
|
||||
template <typename T1, typename T2, typename T3, typename T4>
|
||||
inline std::string string_compose(const std::string &fmt,
|
||||
const T1 &o1, const T2 &o2, const T3 &o3,
|
||||
const T4 &o4)
|
||||
|
@ -240,7 +240,7 @@ namespace StringPrivate
|
|||
return c.str();
|
||||
}
|
||||
|
||||
template <typename T1, typename T2, typename T3, typename T4, typename T5> LIBPBD_API
|
||||
template <typename T1, typename T2, typename T3, typename T4, typename T5>
|
||||
inline std::string string_compose(const std::string &fmt,
|
||||
const T1 &o1, const T2 &o2, const T3 &o3,
|
||||
const T4 &o4, const T5 &o5)
|
||||
|
@ -251,7 +251,7 @@ namespace StringPrivate
|
|||
}
|
||||
|
||||
template <typename T1, typename T2, typename T3, typename T4, typename T5,
|
||||
typename T6> LIBPBD_API
|
||||
typename T6>
|
||||
inline std::string string_compose(const std::string &fmt,
|
||||
const T1 &o1, const T2 &o2, const T3 &o3,
|
||||
const T4 &o4, const T5 &o5, const T6 &o6)
|
||||
|
@ -262,7 +262,7 @@ namespace StringPrivate
|
|||
}
|
||||
|
||||
template <typename T1, typename T2, typename T3, typename T4, typename T5,
|
||||
typename T6, typename T7> LIBPBD_API
|
||||
typename T6, typename T7>
|
||||
inline std::string string_compose(const std::string &fmt,
|
||||
const T1 &o1, const T2 &o2, const T3 &o3,
|
||||
const T4 &o4, const T5 &o5, const T6 &o6,
|
||||
|
@ -274,7 +274,7 @@ namespace StringPrivate
|
|||
}
|
||||
|
||||
template <typename T1, typename T2, typename T3, typename T4, typename T5,
|
||||
typename T6, typename T7, typename T8> LIBPBD_API
|
||||
typename T6, typename T7, typename T8>
|
||||
inline std::string string_compose(const std::string &fmt,
|
||||
const T1 &o1, const T2 &o2, const T3 &o3,
|
||||
const T4 &o4, const T5 &o5, const T6 &o6,
|
||||
|
@ -286,7 +286,7 @@ namespace StringPrivate
|
|||
}
|
||||
|
||||
template <typename T1, typename T2, typename T3, typename T4, typename T5,
|
||||
typename T6, typename T7, typename T8, typename T9> LIBPBD_API
|
||||
typename T6, typename T7, typename T8, typename T9>
|
||||
inline std::string string_compose(const std::string &fmt,
|
||||
const T1 &o1, const T2 &o2, const T3 &o3,
|
||||
const T4 &o4, const T5 &o5, const T6 &o6,
|
||||
|
@ -298,7 +298,7 @@ namespace StringPrivate
|
|||
}
|
||||
|
||||
template <typename T1, typename T2, typename T3, typename T4, typename T5,
|
||||
typename T6, typename T7, typename T8, typename T9, typename T10> LIBPBD_API
|
||||
typename T6, typename T7, typename T8, typename T9, typename T10>
|
||||
inline std::string string_compose(const std::string &fmt,
|
||||
const T1 &o1, const T2 &o2, const T3 &o3,
|
||||
const T4 &o4, const T5 &o5, const T6 &o6,
|
||||
|
@ -313,7 +313,7 @@ namespace StringPrivate
|
|||
|
||||
template <typename T1, typename T2, typename T3, typename T4, typename T5,
|
||||
typename T6, typename T7, typename T8, typename T9, typename T10,
|
||||
typename T11> LIBPBD_API
|
||||
typename T11>
|
||||
inline std::string string_compose(const std::string &fmt,
|
||||
const T1 &o1, const T2 &o2, const T3 &o3,
|
||||
const T4 &o4, const T5 &o5, const T6 &o6,
|
||||
|
@ -328,7 +328,7 @@ namespace StringPrivate
|
|||
|
||||
template <typename T1, typename T2, typename T3, typename T4, typename T5,
|
||||
typename T6, typename T7, typename T8, typename T9, typename T10,
|
||||
typename T11, typename T12> LIBPBD_API
|
||||
typename T11, typename T12>
|
||||
inline std::string string_compose(const std::string &fmt,
|
||||
const T1 &o1, const T2 &o2, const T3 &o3,
|
||||
const T4 &o4, const T5 &o5, const T6 &o6,
|
||||
|
@ -343,7 +343,7 @@ namespace StringPrivate
|
|||
|
||||
template <typename T1, typename T2, typename T3, typename T4, typename T5,
|
||||
typename T6, typename T7, typename T8, typename T9, typename T10,
|
||||
typename T11, typename T12, typename T13> LIBPBD_API
|
||||
typename T11, typename T12, typename T13>
|
||||
inline std::string string_compose(const std::string &fmt,
|
||||
const T1 &o1, const T2 &o2, const T3 &o3,
|
||||
const T4 &o4, const T5 &o5, const T6 &o6,
|
||||
|
@ -359,7 +359,7 @@ namespace StringPrivate
|
|||
|
||||
template <typename T1, typename T2, typename T3, typename T4, typename T5,
|
||||
typename T6, typename T7, typename T8, typename T9, typename T10,
|
||||
typename T11, typename T12, typename T13, typename T14> LIBPBD_API
|
||||
typename T11, typename T12, typename T13, typename T14>
|
||||
inline std::string string_compose(const std::string &fmt,
|
||||
const T1 &o1, const T2 &o2, const T3 &o3,
|
||||
const T4 &o4, const T5 &o5, const T6 &o6,
|
||||
|
@ -376,7 +376,7 @@ namespace StringPrivate
|
|||
template <typename T1, typename T2, typename T3, typename T4, typename T5,
|
||||
typename T6, typename T7, typename T8, typename T9, typename T10,
|
||||
typename T11, typename T12, typename T13, typename T14,
|
||||
typename T15> LIBPBD_API
|
||||
typename T15>
|
||||
inline std::string string_compose(const std::string &fmt,
|
||||
const T1 &o1, const T2 &o2, const T3 &o3,
|
||||
const T4 &o4, const T5 &o5, const T6 &o6,
|
||||
|
|
|
@ -47,7 +47,7 @@ LIBPBD_API std::string length2string (const int64_t frames, const double sample_
|
|||
LIBPBD_API std::vector<std::string> internationalize (const char *, const char **);
|
||||
LIBPBD_API bool strings_equal_ignore_case (const std::string& a, const std::string& b);
|
||||
|
||||
template <class T> std::string LIBPBD_API
|
||||
template <class T> std::string /*LIBPBD_API*/
|
||||
to_string (T t, std::ios_base & (*f)(std::ios_base&))
|
||||
{
|
||||
std::ostringstream oss;
|
||||
|
|
|
@ -32,7 +32,7 @@
|
|||
|
||||
namespace PBD
|
||||
{
|
||||
template<typename T> LIBPBD_API
|
||||
template<typename T> /*LIBPBD_API*/
|
||||
std::string demangled_name (T const & obj)
|
||||
{
|
||||
#ifdef __GNUC__
|
||||
|
|
|
@ -23,7 +23,7 @@
|
|||
#include <glib/gtypes.h>
|
||||
|
||||
#ifdef PLATFORM_WINDOWS // Would not be relevant for Cygwin!!
|
||||
PBD_API gchar* PBD_APICALLTYPE get_win_special_folder (int csidl);
|
||||
LIBPBD_API gchar* PBD_APICALLTYPE get_win_special_folder (int csidl);
|
||||
#endif
|
||||
|
||||
namespace PBD {
|
||||
|
@ -49,9 +49,9 @@ namespace PBD {
|
|||
extern "C" {
|
||||
#endif /* __cplusplus */
|
||||
|
||||
PBD_API G_CONST_RETURN gchar* PBD_APICALLTYPE get_platform_fallback_folder (PBD::fallback_folder_t index);
|
||||
PBD_API G_CONST_RETURN gchar* G_CONST_RETURN * PBD_APICALLTYPE alloc_platform_fallback_folders ();
|
||||
PBD_API void PBD_APICALLTYPE free_platform_fallback_folders ();
|
||||
LIBPBD_API G_CONST_RETURN gchar* PBD_APICALLTYPE get_platform_fallback_folder (PBD::fallback_folder_t index);
|
||||
LIBPBD_API G_CONST_RETURN gchar* G_CONST_RETURN * PBD_APICALLTYPE alloc_platform_fallback_folders ();
|
||||
LIBPBD_API void PBD_APICALLTYPE free_platform_fallback_folders ();
|
||||
|
||||
#ifdef __cplusplus
|
||||
} /* extern "C" */
|
||||
|
|
|
@ -20,8 +20,10 @@
|
|||
#ifndef __libpbd_ffs_h__
|
||||
#define __libpbd_ffs_h__
|
||||
|
||||
#include "pbd/libpbd_visibility.h"
|
||||
|
||||
namespace PBD {
|
||||
int ffs(int x);
|
||||
LIBPBD_API int ffs(int x);
|
||||
}
|
||||
|
||||
#endif /* __libpbd_ffs_h__ */
|
||||
|
|
|
@ -34,7 +34,7 @@
|
|||
|
||||
namespace PBD {
|
||||
|
||||
union LIBPBD_API Float_t
|
||||
union /*LIBPBD_API*/ Float_t
|
||||
{
|
||||
Float_t (float num = 0.0f) : f(num) {}
|
||||
|
||||
|
|
|
@ -37,7 +37,7 @@
|
|||
namespace PBD {
|
||||
|
||||
template <class obj_type, class arg_type>
|
||||
class LIBPBD_API FunctorCommand : public Command
|
||||
class /*LIBPBD_API*/ FunctorCommand : public Command
|
||||
{
|
||||
private:
|
||||
typedef void (obj_type::*functor_type)(arg_type);
|
||||
|
|
|
@ -22,11 +22,12 @@
|
|||
|
||||
#include <glibmm/threads.h>
|
||||
|
||||
#include "pbd/libpbd_visibility.h"
|
||||
#include "atomic_counter.h"
|
||||
|
||||
namespace PBD {
|
||||
|
||||
class GlibSemaphore
|
||||
class LIBPBD_API GlibSemaphore
|
||||
{
|
||||
|
||||
// prevent copying and assignment
|
||||
|
|
|
@ -24,7 +24,7 @@
|
|||
|
||||
namespace PBD {
|
||||
|
||||
struct LocaleGuard {
|
||||
struct LIBPBD_API /* Added by JE - */ LocaleGuard {
|
||||
LocaleGuard (const char*);
|
||||
~LocaleGuard ();
|
||||
const char* old;
|
||||
|
|
|
@ -51,7 +51,7 @@
|
|||
* can do `just-in-time' binding from the crossfade ID.
|
||||
*/
|
||||
template <class obj_T>
|
||||
class LIBPBD_API MementoCommandBinder : public PBD::Destructible
|
||||
class /*LIBPBD_API*/ MementoCommandBinder : public PBD::Destructible
|
||||
{
|
||||
public:
|
||||
/** @return Stateful object to operate on */
|
||||
|
@ -68,7 +68,7 @@ public:
|
|||
|
||||
/** A simple MementoCommandBinder which binds directly to an object */
|
||||
template <class obj_T>
|
||||
class LIBPBD_API SimpleMementoCommandBinder : public MementoCommandBinder<obj_T>
|
||||
class /*LIBPBD_API*/ SimpleMementoCommandBinder : public MementoCommandBinder<obj_T>
|
||||
{
|
||||
public:
|
||||
SimpleMementoCommandBinder (obj_T& o)
|
||||
|
@ -100,7 +100,7 @@ private:
|
|||
* memento, and redo is restoring the after memento.
|
||||
*/
|
||||
template <class obj_T>
|
||||
class LIBPBD_API MementoCommand : public Command
|
||||
class /*LIBPBD_API*/ MementoCommand : public Command
|
||||
{
|
||||
public:
|
||||
MementoCommand (obj_T& a_object, XMLNode* a_before, XMLNode* a_after)
|
||||
|
|
|
@ -20,9 +20,12 @@
|
|||
#define _msvc_pbd_h_
|
||||
|
||||
#ifdef PBD_IS_IN_WIN_STATIC_LIB // #define if your project uses libpbd (under Windows) as a static library
|
||||
#undef LIBPBD_DLL
|
||||
#define PBD_IS_IN_WINDLL 0
|
||||
#endif
|
||||
|
||||
#include <pbd/libpbd_visibility.h>
|
||||
|
||||
#ifndef COMPILER_MSVC
|
||||
#include <sys/time.h>
|
||||
#else
|
||||
|
@ -39,23 +42,22 @@
|
|||
#endif
|
||||
#endif
|
||||
|
||||
#if PBD_IS_IN_WINDLL && !defined(PBD_API)
|
||||
#if PBD_IS_IN_WINDLL && !defined(PBD_APICALLTYPE)
|
||||
#if defined(BUILDING_PBD)
|
||||
#define PBD_API __declspec(dllexport)
|
||||
#define PBD_APICALLTYPE __stdcall
|
||||
#define PBD_APICALLTYPE __cdecl
|
||||
#elif defined(COMPILER_MSVC) || defined(COMPILER_MINGW) // Probably needs Cygwin too, at some point
|
||||
#define PBD_API __declspec(dllimport)
|
||||
#define PBD_APICALLTYPE __stdcall
|
||||
#define PBD_APICALLTYPE __cdecl
|
||||
#else
|
||||
#error "Attempting to define __declspec with an incompatible compiler !"
|
||||
#endif
|
||||
#elif !defined(PBD_API)
|
||||
#elif !defined(PBD_APICALLTYPE)
|
||||
// Other compilers / platforms could be accommodated here
|
||||
#define PBD_API
|
||||
#define PBD_APICALLTYPE
|
||||
#ifndef GETOPT_API
|
||||
#define GETOPT_API
|
||||
#define GETOPT_APICALLTYPE
|
||||
#endif
|
||||
#endif
|
||||
|
||||
#ifndef GETOPT_API
|
||||
#if defined(BUILDING_GETOPT)
|
||||
|
@ -145,23 +147,27 @@ extern "C" {
|
|||
extern "C" {
|
||||
#endif /* __cplusplus */
|
||||
|
||||
PBDEXTN_API int PBDEXTN_APICALLTYPE cyginit (unsigned int result);
|
||||
PBD_API int PBD_APICALLTYPE dlclose (void *handle) __THROW;
|
||||
PBD_API void* PBD_APICALLTYPE dlopen (const char *file_name, int mode) __THROW;
|
||||
PBD_API void* PBD_APICALLTYPE dlsym (void *handle, const char *symbol_name) __THROW;
|
||||
PBD_API char* PBD_APICALLTYPE dlerror () __THROW;
|
||||
PBDEXTN_API int PBDEXTN_APICALLTYPE cyginit (unsigned int result);
|
||||
LIBPBD_API int PBD_APICALLTYPE dlclose (void *handle) __THROW;
|
||||
LIBPBD_API void* PBD_APICALLTYPE dlopen (const char *file_name, int mode) __THROW;
|
||||
LIBPBD_API void* PBD_APICALLTYPE dlsym (void *handle, const char *symbol_name) __THROW;
|
||||
LIBPBD_API char* PBD_APICALLTYPE dlerror () __THROW;
|
||||
|
||||
#ifdef __cplusplus
|
||||
} /* extern "C" */
|
||||
#endif /* __cplusplus */
|
||||
|
||||
#ifndef __CYGWIN__
|
||||
/* For whatever reason, Ardour's 'libevoral' refuses to build as a DLL if we include both 'rpc.h' */
|
||||
/* and 'WinSock2.h'. It doesn't seem to matter which order we #include them. Given that we can't */
|
||||
/* edit 'rpc.h' or 'WinSock2.h', just make sure we don't #include them when building libevoral. */
|
||||
#ifndef BUILDING_EVORAL
|
||||
#include <rpc.h>
|
||||
typedef int (FAR PBDEXTN_APICALLTYPE *CYGINIT_API)(unsigned int);
|
||||
#endif
|
||||
#include <io.h>
|
||||
#include <sys/types.h>
|
||||
|
||||
typedef int (FAR PBDEXTN_APICALLTYPE *CYGINIT_API)(unsigned int);
|
||||
|
||||
#ifndef FILENAME_MAX
|
||||
#define FILENAME_MAX (260)
|
||||
#endif
|
||||
|
@ -216,35 +222,35 @@ struct pollfd
|
|||
|
||||
typedef unsigned int nfds_t;
|
||||
|
||||
PBD_API int PBD_APICALLTYPE gettimeofday(struct timeval *__restrict tv, __timezone_ptr_t tz);
|
||||
PBD_API ssize_t PBD_APICALLTYPE pread(int handle, void *buf, size_t nbytes, off_t offset);
|
||||
PBD_API ssize_t PBD_APICALLTYPE pwrite(int handle, const void *buf, size_t nbytes, off_t offset);
|
||||
PBD_API int PBD_APICALLTYPE poll(struct pollfd *fds, nfds_t nfds, int timeout);
|
||||
PBD_API double PBD_APICALLTYPE round(double x);
|
||||
|
||||
namespace PBD {
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif /* __cplusplus */
|
||||
|
||||
PBD_API bool PBD_APICALLTYPE TestForMinimumSpecOS(char *revision="currently ignored");
|
||||
PBD_API char* PBD_APICALLTYPE realpath (const char *original_path, char resolved_path[_MAX_PATH+1]);
|
||||
PBD_API int PBD_APICALLTYPE mkstemp (char *template_name);
|
||||
PBD_API int PBD_APICALLTYPE ntfs_link (const char *existing_filepath, const char *link_filepath);
|
||||
PBD_API int PBD_APICALLTYPE ntfs_unlink (const char *link_filepath);
|
||||
LIBPBD_API int __cdecl gettimeofday(struct timeval *__restrict tv, __timezone_ptr_t tz);
|
||||
LIBPBD_API ssize_t PBD_APICALLTYPE pread(int handle, void *buf, size_t nbytes, off_t offset);
|
||||
LIBPBD_API ssize_t PBD_APICALLTYPE pwrite(int handle, const void *buf, size_t nbytes, off_t offset);
|
||||
LIBPBD_API int PBD_APICALLTYPE poll(struct pollfd *fds, nfds_t nfds, int timeout);
|
||||
LIBPBD_API double PBD_APICALLTYPE round(double x);
|
||||
|
||||
namespace PBD {
|
||||
|
||||
LIBPBD_API bool PBD_APICALLTYPE TestForMinimumSpecOS(char *revision="currently ignored");
|
||||
LIBPBD_API char* PBD_APICALLTYPE realpath (const char *original_path, char resolved_path[_MAX_PATH+1]);
|
||||
LIBPBD_API int PBD_APICALLTYPE mkstemp (char *template_name);
|
||||
LIBPBD_API int PBD_APICALLTYPE ntfs_link (const char *existing_filepath, const char *link_filepath);
|
||||
LIBPBD_API int PBD_APICALLTYPE ntfs_unlink (const char *link_filepath);
|
||||
|
||||
// These are used to replicate 'dirent.h' functionality
|
||||
PBD_API DIR* PBD_APICALLTYPE opendir (const char *szPath);
|
||||
PBD_API struct dirent* PBD_APICALLTYPE readdir (DIR *pDir);
|
||||
PBD_API int PBD_APICALLTYPE closedir (DIR *pDir);
|
||||
LIBPBD_API DIR* PBD_APICALLTYPE opendir (const char *szPath);
|
||||
LIBPBD_API struct dirent* PBD_APICALLTYPE readdir (DIR *pDir);
|
||||
LIBPBD_API int PBD_APICALLTYPE closedir (DIR *pDir);
|
||||
|
||||
} // namespace PBD
|
||||
|
||||
#ifdef __cplusplus
|
||||
} /* extern "C" */
|
||||
#endif /* __cplusplus */
|
||||
|
||||
} // namespace PBD
|
||||
|
||||
#endif // !__CYGWIN__
|
||||
#endif // PLATFORM_WINDOWS
|
||||
#endif // _msvc_pbd_h_
|
||||
|
|
|
@ -24,6 +24,7 @@
|
|||
#include "pbd/libpbd_visibility.h"
|
||||
|
||||
namespace PBD {
|
||||
LIBPBD_API std::string canonical_path (const std::string& path);
|
||||
LIBPBD_API std::string path_expand (std::string path);
|
||||
LIBPBD_API std::string search_path_expand (std::string path);
|
||||
}
|
||||
|
|
|
@ -37,7 +37,7 @@ namespace PBD {
|
|||
|
||||
/** Parent class for classes which represent a single scalar property in a Stateful object */
|
||||
template<class T>
|
||||
class LIBPBD_API PropertyTemplate : public PropertyBase
|
||||
class /*LIBPBD_API*/ PropertyTemplate : public PropertyBase
|
||||
{
|
||||
public:
|
||||
PropertyTemplate (PropertyDescriptor<T> p, T const& v)
|
||||
|
@ -197,7 +197,7 @@ private:
|
|||
PropertyTemplate (PropertyTemplate<T> const &);
|
||||
};
|
||||
|
||||
template<class T> LIBPBD_API
|
||||
template<class T> /*LIBPBD_API*/
|
||||
std::ostream & operator<<(std::ostream& os, PropertyTemplate<T> const& s)
|
||||
{
|
||||
return os << s.val ();
|
||||
|
@ -207,7 +207,7 @@ std::ostream & operator<<(std::ostream& os, PropertyTemplate<T> const& s)
|
|||
* with types that can be written to / read from stringstreams.
|
||||
*/
|
||||
template<class T>
|
||||
class LIBPBD_API Property : public PropertyTemplate<T>
|
||||
class /*LIBPBD_API*/ Property : public PropertyTemplate<T>
|
||||
{
|
||||
public:
|
||||
Property (PropertyDescriptor<T> q, T const& v)
|
||||
|
@ -285,7 +285,7 @@ private:
|
|||
* separators, etc.
|
||||
*/
|
||||
template<>
|
||||
class LIBPBD_API Property<std::string> : public PropertyTemplate<std::string>
|
||||
class /*LIBPBD_API*/ Property<std::string> : public PropertyTemplate<std::string>
|
||||
{
|
||||
public:
|
||||
Property (PropertyDescriptor<std::string> d, std::string const & v)
|
||||
|
@ -319,7 +319,7 @@ private:
|
|||
};
|
||||
|
||||
template<class T>
|
||||
class LIBPBD_API EnumProperty : public Property<T>
|
||||
class /*LIBPBD_API*/ EnumProperty : public Property<T>
|
||||
{
|
||||
public:
|
||||
EnumProperty (PropertyDescriptor<T> q, T const& v)
|
||||
|
@ -352,7 +352,7 @@ private:
|
|||
* one.
|
||||
*/
|
||||
template <class T>
|
||||
class LIBPBD_API SharedStatefulProperty : public PropertyBase
|
||||
class /*LIBPBD_API*/ SharedStatefulProperty : public PropertyBase
|
||||
{
|
||||
public:
|
||||
typedef boost::shared_ptr<T> Ptr;
|
||||
|
|
|
@ -38,7 +38,7 @@ class LIBPBD_API StatefulDiffCommand;
|
|||
typedef GQuark PropertyID;
|
||||
|
||||
template<typename T>
|
||||
struct LIBPBD_API PropertyDescriptor {
|
||||
struct /*LIBPBD_API*/ PropertyDescriptor {
|
||||
PropertyDescriptor () : property_id (0) {}
|
||||
PropertyDescriptor (PropertyID pid) : property_id (pid) {}
|
||||
|
||||
|
@ -47,16 +47,17 @@ struct LIBPBD_API PropertyDescriptor {
|
|||
};
|
||||
|
||||
/** A list of IDs of Properties that have changed in some situation or other */
|
||||
class LIBPBD_API PropertyChange : public std::set<PropertyID>
|
||||
class /*LIBPBD_API*/ PropertyChange : public std::set<PropertyID>
|
||||
{
|
||||
public:
|
||||
PropertyChange() {}
|
||||
LIBPBD_API PropertyChange() {}
|
||||
LIBPBD_API ~PropertyChange() {}
|
||||
|
||||
template<typename T> PropertyChange(PropertyDescriptor<T> p);
|
||||
|
||||
PropertyChange(const PropertyChange& other) : std::set<PropertyID> (other) {}
|
||||
LIBPBD_API PropertyChange(const PropertyChange& other) : std::set<PropertyID> (other) {}
|
||||
|
||||
PropertyChange operator=(const PropertyChange& other) {
|
||||
LIBPBD_API PropertyChange operator=(const PropertyChange& other) {
|
||||
clear ();
|
||||
insert (other.begin (), other.end ());
|
||||
return *this;
|
||||
|
@ -65,7 +66,7 @@ public:
|
|||
template<typename T> PropertyChange operator=(PropertyDescriptor<T> p);
|
||||
template<typename T> bool contains (PropertyDescriptor<T> p) const;
|
||||
|
||||
bool contains (const PropertyChange& other) const {
|
||||
LIBPBD_API bool contains (const PropertyChange& other) const {
|
||||
for (const_iterator x = other.begin (); x != other.end (); ++x) {
|
||||
if (find (*x) != end ()) {
|
||||
return true;
|
||||
|
@ -74,8 +75,8 @@ public:
|
|||
return false;
|
||||
}
|
||||
|
||||
void add (PropertyID id) { insert (id); }
|
||||
void add (const PropertyChange& other) { insert (other.begin (), other.end ()); }
|
||||
LIBPBD_API void add (PropertyID id) { insert (id); }
|
||||
LIBPBD_API void add (const PropertyChange& other) { insert (other.begin (), other.end ()); }
|
||||
template<typename T> void add (PropertyDescriptor<T> p);
|
||||
};
|
||||
|
||||
|
|
|
@ -45,7 +45,7 @@
|
|||
and managed object.
|
||||
*/
|
||||
template<class T>
|
||||
class LIBPBD_API RCUManager
|
||||
class /*LIBPBD_API*/ RCUManager
|
||||
{
|
||||
public:
|
||||
|
||||
|
@ -111,7 +111,7 @@ class LIBPBD_API RCUManager
|
|||
means that no actual objects will be deleted incorrectly if this is misused.
|
||||
*/
|
||||
template<class T>
|
||||
class LIBPBD_API SerializedRCUManager : public RCUManager<T>
|
||||
class /*LIBPBD_API*/ SerializedRCUManager : public RCUManager<T>
|
||||
{
|
||||
public:
|
||||
|
||||
|
@ -214,7 +214,7 @@ private:
|
|||
|
||||
*/
|
||||
template<class T>
|
||||
class LIBPBD_API RCUWriter
|
||||
class /*LIBPBD_API*/ RCUWriter
|
||||
{
|
||||
public:
|
||||
|
||||
|
|
|
@ -26,7 +26,7 @@
|
|||
#include "pbd/libpbd_visibility.h"
|
||||
|
||||
template<class T>
|
||||
class LIBPBD_API RingBuffer
|
||||
class /*LIBPBD_API*/ RingBuffer
|
||||
{
|
||||
public:
|
||||
RingBuffer (guint sz) {
|
||||
|
@ -120,7 +120,7 @@ class LIBPBD_API RingBuffer
|
|||
guint size_mask;
|
||||
};
|
||||
|
||||
template<class T> LIBPBD_API guint
|
||||
template<class T> /*LIBPBD_API*/ guint
|
||||
RingBuffer<T>::read (T *dest, guint cnt)
|
||||
{
|
||||
guint free_cnt;
|
||||
|
@ -159,7 +159,7 @@ RingBuffer<T>::read (T *dest, guint cnt)
|
|||
return to_read;
|
||||
}
|
||||
|
||||
template<class T> LIBPBD_API guint
|
||||
template<class T> /*LIBPBD_API*/ guint
|
||||
RingBuffer<T>::write (T const *src, guint cnt)
|
||||
|
||||
{
|
||||
|
@ -199,7 +199,7 @@ RingBuffer<T>::write (T const *src, guint cnt)
|
|||
return to_write;
|
||||
}
|
||||
|
||||
template<class T> LIBPBD_API void
|
||||
template<class T> /*LIBPBD_API*/ void
|
||||
RingBuffer<T>::get_read_vector (typename RingBuffer<T>::rw_vector *vec)
|
||||
|
||||
{
|
||||
|
@ -240,7 +240,7 @@ RingBuffer<T>::get_read_vector (typename RingBuffer<T>::rw_vector *vec)
|
|||
}
|
||||
}
|
||||
|
||||
template<class T> LIBPBD_API void
|
||||
template<class T> /*LIBPBD_API*/ void
|
||||
RingBuffer<T>::get_write_vector (typename RingBuffer<T>::rw_vector *vec)
|
||||
|
||||
{
|
||||
|
|
|
@ -32,7 +32,7 @@ namespace PBD {
|
|||
/* ringbuffer class where the element size is not required to be a power of two */
|
||||
|
||||
template<class T>
|
||||
class LIBPBD_API RingBufferNPT
|
||||
class /*LIBPBD_API*/ RingBufferNPT
|
||||
{
|
||||
public:
|
||||
RingBufferNPT (size_t sz) {
|
||||
|
@ -120,7 +120,7 @@ class LIBPBD_API RingBufferNPT
|
|||
mutable gint read_ptr;
|
||||
};
|
||||
|
||||
template<class T> LIBPBD_API size_t
|
||||
template<class T> /*LIBPBD_API*/ size_t
|
||||
RingBufferNPT<T>::read (T *dest, size_t cnt)
|
||||
{
|
||||
size_t free_cnt;
|
||||
|
@ -159,7 +159,7 @@ RingBufferNPT<T>::read (T *dest, size_t cnt)
|
|||
return to_read;
|
||||
}
|
||||
|
||||
template<class T> LIBPBD_API size_t
|
||||
template<class T> /*LIBPBD_API*/ size_t
|
||||
RingBufferNPT<T>::write (const T *src, size_t cnt)
|
||||
{
|
||||
size_t free_cnt;
|
||||
|
@ -198,7 +198,7 @@ RingBufferNPT<T>::write (const T *src, size_t cnt)
|
|||
return to_write;
|
||||
}
|
||||
|
||||
template<class T> LIBPBD_API void
|
||||
template<class T> /*LIBPBD_API*/ void
|
||||
RingBufferNPT<T>::get_read_vector (typename RingBufferNPT<T>::rw_vector *vec)
|
||||
{
|
||||
size_t free_cnt;
|
||||
|
@ -238,7 +238,7 @@ RingBufferNPT<T>::get_read_vector (typename RingBufferNPT<T>::rw_vector *vec)
|
|||
}
|
||||
}
|
||||
|
||||
template<class T> LIBPBD_API void
|
||||
template<class T> /*LIBPBD_API*/ void
|
||||
RingBufferNPT<T>::get_write_vector (typename RingBufferNPT<T>::rw_vector *vec)
|
||||
{
|
||||
size_t free_cnt;
|
||||
|
|
|
@ -38,13 +38,13 @@ namespace PBD {
|
|||
* The Searchpath class does not test whether the paths exist
|
||||
* or are directories. It is basically just a container.
|
||||
*/
|
||||
class LIBPBD_API SearchPath : public std::vector<std::string>
|
||||
class /*LIBPBD_API*/ Searchpath : public std::vector<std::string>
|
||||
{
|
||||
public:
|
||||
/**
|
||||
* Create an empty Searchpath.
|
||||
*/
|
||||
Searchpath ();
|
||||
LIBPBD_API Searchpath ();
|
||||
|
||||
/**
|
||||
* Initialize Searchpath from a string where the string contains
|
||||
|
@ -57,7 +57,7 @@ public:
|
|||
*
|
||||
* @param search_path A path string.
|
||||
*/
|
||||
Searchpath (const std::string& search_path);
|
||||
LIBPBD_API Searchpath (const std::string& search_path);
|
||||
|
||||
/**
|
||||
* Initialize Searchpath from a vector of paths that may or may
|
||||
|
@ -65,7 +65,9 @@ public:
|
|||
*
|
||||
* @param paths A vector of paths.
|
||||
*/
|
||||
Searchpath (const std::vector<std::string>& paths);
|
||||
LIBPBD_API Searchpath (const std::vector<std::string>& paths);
|
||||
|
||||
LIBPBD_API ~Searchpath () {};
|
||||
|
||||
/**
|
||||
* @return a search path string.
|
||||
|
@ -73,39 +75,39 @@ public:
|
|||
* The string that is returned contains the platform specific
|
||||
* path separator.
|
||||
*/
|
||||
const std::string to_string () const;
|
||||
LIBPBD_API const std::string to_string () const;
|
||||
|
||||
/**
|
||||
* Add all the directories in path to this.
|
||||
*/
|
||||
Searchpath& operator+= (const Searchpath& spath);
|
||||
LIBPBD_API Searchpath& operator+= (const Searchpath& spath);
|
||||
|
||||
/**
|
||||
* Add another directory path to the search path.
|
||||
*/
|
||||
Searchpath& operator+= (const std::string& directory_path);
|
||||
LIBPBD_API Searchpath& operator+= (const std::string& directory_path);
|
||||
|
||||
/**
|
||||
* Concatenate another Searchpath onto this.
|
||||
*/
|
||||
Searchpath& operator+ (const Searchpath& other);
|
||||
LIBPBD_API Searchpath& operator+ (const Searchpath& other);
|
||||
|
||||
/**
|
||||
* Add another path to the search path.
|
||||
*/
|
||||
Searchpath& operator+ (const std::string& directory_path);
|
||||
LIBPBD_API Searchpath& operator+ (const std::string& directory_path);
|
||||
|
||||
/**
|
||||
* Add a sub-directory to each path in the search path.
|
||||
* @param subdir The directory name, it should not contain
|
||||
* any path separating tokens.
|
||||
*/
|
||||
Searchpath& add_subdirectory_to_paths (const std::string& subdir);
|
||||
LIBPBD_API Searchpath& add_subdirectory_to_paths (const std::string& subdir);
|
||||
|
||||
protected:
|
||||
|
||||
void add_directory (const std::string& directory_path);
|
||||
void add_directories (const std::vector<std::string>& paths);
|
||||
LIBPBD_API void add_directory (const std::string& directory_path);
|
||||
LIBPBD_API void add_directories (const std::vector<std::string>& paths);
|
||||
};
|
||||
|
||||
} // namespace PBD
|
||||
|
|
|
@ -49,7 +49,7 @@ namespace PBD {
|
|||
only safe way to reliably signal from a real-time audio thread. The
|
||||
counting semantics also complement ringbuffers of events nicely.
|
||||
*/
|
||||
class LIBPBD_API Semaphore
|
||||
class /*LIBPBD_API*/ Semaphore
|
||||
{
|
||||
public:
|
||||
/**
|
||||
|
|
|
@ -44,7 +44,7 @@ namespace PBD {
|
|||
* any change.
|
||||
*/
|
||||
template<typename Container>
|
||||
class LIBPBD_API SequenceProperty : public PropertyBase
|
||||
class /*LIBPBD_API*/ SequenceProperty : public PropertyBase
|
||||
{
|
||||
public:
|
||||
typedef std::set<typename Container::value_type> ChangeContainer;
|
||||
|
@ -311,10 +311,10 @@ class LIBPBD_API SequenceProperty : public PropertyBase
|
|||
}
|
||||
|
||||
Container& operator= (const Container& other) {
|
||||
for (typename Container::iterator i = _val.begin(); i != _val.end(); ++i) {
|
||||
for (typename Container::const_iterator i = _val.begin(); i != _val.end(); ++i) {
|
||||
_changes.remove (*i);
|
||||
}
|
||||
for (typename Container::iterator i = other.begin(); i != other.end(); ++i) {
|
||||
for (typename Container::const_iterator i = other.begin(); i != other.end(); ++i) {
|
||||
_changes.add (*i);
|
||||
}
|
||||
return _val = other;
|
||||
|
|
|
@ -79,7 +79,7 @@ private:
|
|||
};
|
||||
|
||||
template<typename R>
|
||||
class LIBPBD_API OptionalLastValue
|
||||
class /*LIBPBD_API*/ OptionalLastValue
|
||||
{
|
||||
public:
|
||||
typedef boost::optional<R> result_type;
|
||||
|
|
|
@ -40,10 +40,10 @@
|
|||
namespace PBD {
|
||||
LIBPBD_API void stacktrace (std::ostream& out, int levels = 0);
|
||||
LIBPBD_API void trace_twb();
|
||||
std::string demangle (const std::string&);
|
||||
/* JE - !!!! Declaration might possibly get removed (except it's still used in 'libs/canvas/item.cc') */ std::string demangle (const std::string&);
|
||||
|
||||
template<typename T>
|
||||
class LIBPBD_API thing_with_backtrace
|
||||
class /*LIBPBD_API*/ thing_with_backtrace
|
||||
{
|
||||
public:
|
||||
thing_with_backtrace () {
|
||||
|
@ -112,11 +112,11 @@ private:
|
|||
static Glib::Threads::Mutex all_mutex;
|
||||
};
|
||||
|
||||
template<typename T> LIBPBD_API std::list<PBD::thing_with_backtrace<T> *> PBD::thing_with_backtrace<T>::all;
|
||||
template<typename T> LIBPBD_API Glib::Threads::Mutex PBD::thing_with_backtrace<T>::all_mutex;
|
||||
template<typename T> /*LIBPBD_API*/ std::list<PBD::thing_with_backtrace<T> *> PBD::thing_with_backtrace<T>::all;
|
||||
template<typename T> /*LIBPBD_API*/ Glib::Threads::Mutex PBD::thing_with_backtrace<T>::all_mutex;
|
||||
|
||||
} // namespace PBD
|
||||
|
||||
|
||||
// JE - !!!!#include "../pbd/stacktrace.impl"
|
||||
|
||||
#endif /* __libpbd_stacktrace_h__ */
|
||||
|
|
|
@ -26,7 +26,7 @@
|
|||
first include the revelant container type header.
|
||||
*/
|
||||
#if defined(_CPP_VECTOR) || defined(_GLIBCXX_VECTOR) || defined(__SGI_STL_VECTOR) || defined(_LIBCPP_VECTOR)
|
||||
template<class T> LIBPBD_API void vector_delete (std::vector<T *> *vec)
|
||||
template<class T> /*LIBPBD_API*/ void vector_delete (std::vector<T *> *vec)
|
||||
{
|
||||
typename std::vector<T *>::iterator i;
|
||||
|
||||
|
@ -38,7 +38,7 @@ template<class T> LIBPBD_API void vector_delete (std::vector<T *> *vec)
|
|||
#endif // _CPP_VECTOR || _GLIBCXX_VECTOR || __SGI_STL_VECTOR || _LIBCPP_VECTOR
|
||||
|
||||
#if defined(_CPP_MAP) || defined(_GLIBCXX_MAP) || defined(__SGI_STL_MAP)
|
||||
template<class K, class T> LIBPBD_API void map_delete (std::map<K, T *> *m)
|
||||
template<class K, class T> /*LIBPBD_API*/ void map_delete (std::map<K, T *> *m)
|
||||
{
|
||||
typename std::map<K, T *>::iterator i;
|
||||
|
||||
|
@ -50,7 +50,7 @@ template<class K, class T> LIBPBD_API void map_delete (std::map<K, T *> *m)
|
|||
#endif // _CPP_MAP || _GLIBCXX_MAP || __SGI_STL_MAP
|
||||
|
||||
#if defined(_CPP_LIST) || defined(_GLIBCXX_LIST) || defined(__SGI_STL_LIST)
|
||||
template<class T> LIBPBD_API void list_delete (std::list<T *> *l)
|
||||
template<class T> /*LIBPBD_API*/ void list_delete (std::list<T *> *l)
|
||||
{
|
||||
typename std::list<T *>::iterator i;
|
||||
|
||||
|
@ -63,7 +63,7 @@ template<class T> LIBPBD_API void list_delete (std::list<T *> *l)
|
|||
#endif // _CPP_LIST || _GLIBCXX_LIST || __SGI_STL_LIST
|
||||
|
||||
#if defined(_CPP_SLIST) || defined(_GLIBCXX_SLIST) || defined(__SGI_STL_SLIST)
|
||||
template<class T> LIBPBD_API void slist_delete (std::slist<T *> *l)
|
||||
template<class T> /*LIBPBD_API*/ void slist_delete (std::slist<T *> *l)
|
||||
{
|
||||
typename std::slist<T *>::iterator i;
|
||||
|
||||
|
@ -76,7 +76,7 @@ template<class T> LIBPBD_API void slist_delete (std::slist<T *> *l)
|
|||
#endif // _CPP_SLIST || _GLIBCXX_SLIST || __SGI_STL_SLIST
|
||||
|
||||
#if defined(_CPP_SET) || defined(_GLIBCXX_SET) || defined(__SGI_STL_SET)
|
||||
template<class T> void LIBPBD_API set_delete (std::set<T *> *sset)
|
||||
template<class T> void /*LIBPBD_API*/ set_delete (std::set<T *> *sset)
|
||||
{
|
||||
typename std::set<T *>::iterator i;
|
||||
|
||||
|
|
|
@ -37,7 +37,7 @@ namespace PBD {
|
|||
are discarded.
|
||||
*/
|
||||
template<typename StringType, typename Iter>
|
||||
LIBPBD_API unsigned int
|
||||
/*LIBPBD_API*/ unsigned int
|
||||
tokenize(const StringType& str,
|
||||
const StringType& delims,
|
||||
Iter it,
|
||||
|
|
|
@ -21,7 +21,7 @@
|
|||
|
||||
#include "pbd/libpbd_visibility.h"
|
||||
|
||||
class LIBPBD_API Touchable
|
||||
class /*LIBPBD_API*/ Touchable
|
||||
{
|
||||
public:
|
||||
Touchable() : _delete_after_touch (false) {}
|
||||
|
@ -37,7 +37,7 @@ class LIBPBD_API Touchable
|
|||
};
|
||||
|
||||
template<class T>
|
||||
class LIBPBD_API DynamicTouchable : public Touchable
|
||||
class /*LIBPBD_API*/ DynamicTouchable : public Touchable
|
||||
{
|
||||
public:
|
||||
DynamicTouchable (T& t, void (T::*m)(void))
|
||||
|
@ -53,7 +53,7 @@ class LIBPBD_API DynamicTouchable : public Touchable
|
|||
};
|
||||
|
||||
template<class T1, class T2>
|
||||
class LIBPBD_API DynamicTouchable1 : public Touchable
|
||||
class /*LIBPBD_API*/ DynamicTouchable1 : public Touchable
|
||||
{
|
||||
public:
|
||||
DynamicTouchable1 (T1& t, void (T1::*m)(T2), T2 a)
|
||||
|
@ -70,7 +70,7 @@ class LIBPBD_API DynamicTouchable1 : public Touchable
|
|||
};
|
||||
|
||||
template<class T1, class T2, class T3>
|
||||
class LIBPBD_API DynamicTouchable2 : public Touchable
|
||||
class /*LIBPBD_API*/ DynamicTouchable2 : public Touchable
|
||||
{
|
||||
public:
|
||||
DynamicTouchable2 (T1& t, void (T1::*m)(T2, T3), T2 a1, T3 a2)
|
||||
|
|
|
@ -22,9 +22,9 @@
|
|||
|
||||
#include <exception>
|
||||
|
||||
#include "pbd/libpbd_visibility.h"
|
||||
//#include "pbd/libpbd_visibility.h"
|
||||
|
||||
class LIBPBD_API unknown_type : public std::exception {
|
||||
class /*LIBPBD_API*/ unknown_type : public std::exception {
|
||||
public:
|
||||
virtual const char *what() const throw() { return "unknown type"; }
|
||||
};
|
||||
|
|
|
@ -25,7 +25,7 @@
|
|||
namespace PBD {
|
||||
|
||||
template <typename T>
|
||||
class LIBPBD_API Unwinder {
|
||||
class /*LIBPBD_API*/ Unwinder {
|
||||
public:
|
||||
Unwinder (T& var, T new_val) : _var (var), _old_val (var) { var = new_val; }
|
||||
~Unwinder () { _var = _old_val; }
|
||||
|
|
|
@ -29,7 +29,7 @@
|
|||
|
||||
namespace PBD {
|
||||
|
||||
class LIBPBD_API UUID {
|
||||
class LIBPBD_API UUID : public boost::uuids::uuid {
|
||||
|
||||
public:
|
||||
UUID ()
|
||||
|
|
|
@ -106,7 +106,7 @@ PBD::stacktrace (std::ostream& out, int levels)
|
|||
#else
|
||||
|
||||
std::string
|
||||
demangle (std::string const & l)
|
||||
/* JE - !!!! 'PBD' namespace might possibly get removed (except it's still used in 'libs/canvas/item.cc') */PBD::demangle (std::string const & l)
|
||||
{
|
||||
return std::string();
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue
Block a user