diff --git a/src/musikbox/app/window/CategoryListView.h b/src/musikbox/app/window/CategoryListView.h index f8431586c..60e7694c5 100755 --- a/src/musikbox/app/window/CategoryListView.h +++ b/src/musikbox/app/window/CategoryListView.h @@ -1,65 +1,67 @@ -#pragma once - -#include - -#include -#include - -#include - -#include -#include - -using musik::core::QueryPtr; -using musik::core::LibraryPtr; - -using cursespp::IMessage; -using cursespp::ListWindow; -using cursespp::IScrollAdapter; -using cursespp::ScrollAdapterBase; - -namespace musik { - namespace box { - class CategoryListView : - public ListWindow, - public std::enable_shared_from_this, - public sigslot::has_slots<> - { - public: - CategoryListView(LibraryPtr library, const std::string& fieldName); - virtual ~CategoryListView(); - - void Requery(); - - virtual void ProcessMessage(IMessage &message); - - DBID GetSelectedId(); - std::string GetFieldName(); - void SetFieldName(const std::string& fieldName); - - protected: - virtual IScrollAdapter& GetScrollAdapter(); - void OnQueryCompleted(QueryPtr query); - - class Adapter : public ScrollAdapterBase { - public: - Adapter(CategoryListView &parent); - - virtual size_t GetEntryCount(); - virtual EntryPtr GetEntry(size_t index); - - private: - CategoryListView &parent; - IScrollAdapter::ScrollPosition spos; - }; - - private: - LibraryPtr library; - Adapter *adapter; - - std::string fieldName; - std::shared_ptr activeQuery; - CategoryListViewQuery::ResultList metadata; - }; - } -} +#pragma once + +#include + +#include +#include + +#include + +#include +#include + +using musik::core::QueryPtr; +using musik::core::LibraryPtr; + +using cursespp::IMessage; +using cursespp::ListWindow; +using cursespp::IScrollAdapter; +using cursespp::ScrollAdapterBase; + +namespace musik { + namespace box { + class CategoryListView : + public ListWindow, +#if ( __clang_major__==7 && __clang_minor__==3 ) + public std::enable_shared_from_this, +#endif + public sigslot::has_slots<> + { + public: + CategoryListView(LibraryPtr library, const std::string& fieldName); + virtual ~CategoryListView(); + + void Requery(); + + virtual void ProcessMessage(IMessage &message); + + DBID GetSelectedId(); + std::string GetFieldName(); + void SetFieldName(const std::string& fieldName); + + protected: + virtual IScrollAdapter& GetScrollAdapter(); + void OnQueryCompleted(QueryPtr query); + + class Adapter : public ScrollAdapterBase { + public: + Adapter(CategoryListView &parent); + + virtual size_t GetEntryCount(); + virtual EntryPtr GetEntry(size_t index); + + private: + CategoryListView &parent; + IScrollAdapter::ScrollPosition spos; + }; + + private: + LibraryPtr library; + Adapter *adapter; + + std::string fieldName; + std::shared_ptr activeQuery; + CategoryListViewQuery::ResultList metadata; + }; + } +} diff --git a/src/musikbox/app/window/CommandWindow.h b/src/musikbox/app/window/CommandWindow.h index 97e89d96a..7b0910208 100755 --- a/src/musikbox/app/window/CommandWindow.h +++ b/src/musikbox/app/window/CommandWindow.h @@ -13,7 +13,9 @@ namespace musik { class CommandWindow : public cursespp::Window, public cursespp::IInput, +#if ( __clang_major__==7 && __clang_minor__==3 ) public std::enable_shared_from_this, +#endif public sigslot::has_slots<> { public: diff --git a/src/musikbox/app/window/LogWindow.h b/src/musikbox/app/window/LogWindow.h index d1dc3c972..dd943ce9c 100755 --- a/src/musikbox/app/window/LogWindow.h +++ b/src/musikbox/app/window/LogWindow.h @@ -13,7 +13,9 @@ namespace musik { namespace box { class LogWindow : public cursespp::ScrollableWindow, +#if ( __clang_major__==7 && __clang_minor__==3 ) public std::enable_shared_from_this, +#endif public sigslot::has_slots<> { public: diff --git a/src/musikbox/app/window/OutputWindow.h b/src/musikbox/app/window/OutputWindow.h index 4786ea639..61eb0a2c9 100755 --- a/src/musikbox/app/window/OutputWindow.h +++ b/src/musikbox/app/window/OutputWindow.h @@ -8,8 +8,10 @@ namespace musik { namespace box { class OutputWindow : - public cursespp::ScrollableWindow, - public std::enable_shared_from_this + public cursespp::ScrollableWindow +#if ( __clang_major__==7 && __clang_minor__==3 ) + , public std::enable_shared_from_this +#endif { public: OutputWindow(cursespp::IWindow *parent = NULL); diff --git a/src/musikbox/app/window/ResourcesWindow.h b/src/musikbox/app/window/ResourcesWindow.h index 17a89ef30..81d79ccc9 100755 --- a/src/musikbox/app/window/ResourcesWindow.h +++ b/src/musikbox/app/window/ResourcesWindow.h @@ -8,8 +8,10 @@ namespace musik { namespace box { class ResourcesWindow : - public cursespp::Window, - public std::enable_shared_from_this + public cursespp::Window +#if true || ( __clang_major__==7 && __clang_minor__==3 ) + , public std::enable_shared_from_this +#endif { public: ResourcesWindow(cursespp::IWindow *parent = NULL); diff --git a/src/musikbox/app/window/TrackListView.h b/src/musikbox/app/window/TrackListView.h index 483a41d30..3e16c107f 100755 --- a/src/musikbox/app/window/TrackListView.h +++ b/src/musikbox/app/window/TrackListView.h @@ -15,7 +15,9 @@ namespace musik { namespace box { class TrackListView : public cursespp::ListWindow, +#if ( __clang_major__==7 && __clang_minor__==3 ) public std::enable_shared_from_this, +#endif public sigslot::has_slots<> { public: diff --git a/src/musikbox/app/window/TransportWindow.h b/src/musikbox/app/window/TransportWindow.h index 3db71bb1c..7f86f9cc8 100755 --- a/src/musikbox/app/window/TransportWindow.h +++ b/src/musikbox/app/window/TransportWindow.h @@ -12,7 +12,9 @@ namespace musik { namespace box { class TransportWindow : public cursespp::Window, +#if ( __clang_major__==7 && __clang_minor__==3 ) public std::enable_shared_from_this, +#endif public sigslot::has_slots<> { public: