From 46459ab2f46fdb826102562c266b0bc2921a3737 Mon Sep 17 00:00:00 2001 From: David Robillard Date: Sun, 28 Sep 2008 04:55:46 +0000 Subject: Remove header namespace pollution (particularly from libs/gui/App.hpp). Fix more LV2 plugin RDF race/lock issues with -eg. Show human readable names on new ports when human readable is set (fix ticket #202). git-svn-id: http://svn.drobilla.net/lad/trunk/ingen@1523 a436a847-0d15-0410-975c-d299462d15a1 --- src/libs/gui/App.hpp | 53 ++++++++++++++++++++++++---------------------------- 1 file changed, 24 insertions(+), 29 deletions(-) (limited to 'src/libs/gui/App.hpp') diff --git a/src/libs/gui/App.hpp b/src/libs/gui/App.hpp index 08ceb271..4a4b6580 100644 --- a/src/libs/gui/App.hpp +++ b/src/libs/gui/App.hpp @@ -15,23 +15,20 @@ * 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA */ -#ifndef APP_H -#define APP_H +#ifndef INGEN_APP_HPP +#define INGEN_APP_HPP #include #include #include -#include +#include #include #include #include #include #include -#include +#include #include -#include - -using namespace std; namespace Ingen { class Engine; @@ -51,10 +48,6 @@ namespace Ingen { } } -using namespace Ingen::Shared; -using namespace Ingen::Serialisation; -using namespace Ingen::Client; - /** \defgroup GUI GTK GUI */ @@ -84,10 +77,10 @@ class App public: ~App(); - void error_message(const string& msg); + void error_message(const std::string& msg); - void attach(SharedPtr client, - SharedPtr handle=SharedPtr()); + void attach(SharedPtr client, + SharedPtr handle=SharedPtr()); void detach(); @@ -110,14 +103,14 @@ public: Configuration* configuration() const { return _configuration; } WindowFactory* window_factory() const { return _window_factory; } - Glib::RefPtr icon_from_path(const string& path, int size); + Glib::RefPtr icon_from_path(const std::string& path, int size); - const SharedPtr& engine() const { return _world->engine; } - const SharedPtr& client() const { return _client; } - const SharedPtr& store() const { return _store; } - const SharedPtr& loader() const { return _loader; } + const SharedPtr& engine() const { return _world->engine; } + const SharedPtr& client() const { return _client; } + const SharedPtr& store() const { return _store; } + const SharedPtr& loader() const { return _loader; } - const SharedPtr& serialiser(); + const SharedPtr& serialiser(); static inline App& instance() { assert(_instance); return *_instance; } @@ -130,29 +123,31 @@ protected: /** This is needed for the icon map. */ template struct LexicalCompare { - bool operator()(const pair& p1, const pair& p2) { + bool operator()(const std::pair& p1, const std::pair& p2) { return (p1.first < p2.first) || ((p1.first == p2.first) && (p1.second < p2.second)); } }; - typedef map, Gdk::Pixbuf*, LexicalCompare > Icons; + typedef std::map< std::pair, + Gdk::Pixbuf*, + LexicalCompare > Icons; Icons _icons; App(Ingen::Shared::World* world); bool animate(); - void error_response(int32_t id, const string& str); + void error_response(int32_t id, const std::string& str); static void* icon_destroyed(void* data); static App* _instance; - SharedPtr _client; - SharedPtr _handle; - SharedPtr _store; - SharedPtr _serialiser; - SharedPtr _loader; + SharedPtr _client; + SharedPtr _handle; + SharedPtr _store; + SharedPtr _serialiser; + SharedPtr _loader; Configuration* _configuration; @@ -174,5 +169,5 @@ protected: } // namespace GUI } // namespace Ingen -#endif // APP_H +#endif // INGEN_APP_HPP -- cgit v1.2.1