diff options
author | David Robillard <d@drobilla.net> | 2012-08-17 02:14:07 +0000 |
---|---|---|
committer | David Robillard <d@drobilla.net> | 2012-08-17 02:14:07 +0000 |
commit | 318b37d8b556add13b3f156f31c9e72eca339a16 (patch) | |
tree | ca7b881f8980a41eca77602b474f29964b5c89db /src/gui/App.cpp | |
parent | a42744e1068a8630d8034df73bb344ca21a53b32 (diff) | |
download | ingen-318b37d8b556add13b3f156f31c9e72eca339a16.tar.gz ingen-318b37d8b556add13b3f156f31c9e72eca339a16.tar.bz2 ingen-318b37d8b556add13b3f156f31c9e72eca339a16.zip |
Implement real logging system, LV2 log extension support, and purge evil/ugly/untranslatable C++ stream printing.
Remove coloured log stuff from Raul.
git-svn-id: http://svn.drobilla.net/lad/trunk/ingen@4717 a436a847-0d15-0410-975c-d299462d15a1
Diffstat (limited to 'src/gui/App.cpp')
-rw-r--r-- | src/gui/App.cpp | 16 |
1 files changed, 7 insertions, 9 deletions
diff --git a/src/gui/App.cpp b/src/gui/App.cpp index e9c9c663..cfba10c7 100644 --- a/src/gui/App.cpp +++ b/src/gui/App.cpp @@ -25,15 +25,15 @@ #include "ganv/Edge.hpp" #include "ingen/EngineBase.hpp" #include "ingen/Interface.hpp" +#include "ingen/Log.hpp" +#include "ingen/World.hpp" #include "ingen/client/ClientStore.hpp" #include "ingen/client/ObjectModel.hpp" #include "ingen/client/PatchModel.hpp" #include "ingen/client/SigClientInterface.hpp" -#include "ingen/World.hpp" #include "ingen/runtime_paths.hpp" #include "lilv/lilv.h" #include "raul/Path.hpp" -#include "raul/log.hpp" #include "App.hpp" #include "Configuration.hpp" @@ -49,8 +49,6 @@ #include "WidgetFactory.hpp" #include "WindowFactory.hpp" -#define LOG(s) (s("[GUI] ")) - using namespace std; namespace Raul { class Deletable; } @@ -148,7 +146,6 @@ App::run() break; _main->run(); - LOG(Raul::info)("Exiting\n"); } void @@ -163,7 +160,7 @@ App::attach(SharedPtr<SigClientInterface> client) } _client = client; - _store = SharedPtr<ClientStore>(new ClientStore(_world->uris(), _world->interface(), client)); + _store = SharedPtr<ClientStore>(new ClientStore(_world->uris(), _world->log(), _world->interface(), client)); _loader = SharedPtr<ThreadedLoader>(new ThreadedLoader(*this, _world->interface())); _patch_tree_window->init(*this, *_store); @@ -229,10 +226,10 @@ App::property_change(const Raul::URI& subject, { if (subject == uris().ingen_engine && key == uris().ingen_sampleRate) { if (value.type() == forge().Int) { - LOG(Raul::info)(Raul::fmt("Sample rate: %1%\n") % uris().forge.str(value)); + log().info(Raul::fmt("Sample rate: %1%\n") % uris().forge.str(value)); _sample_rate = value.get_int32(); } else { - Raul::error << "Engine sample rate property is not an integer" << std::endl; + log().error("Engine sample rate property is not an integer\n"); } } } @@ -378,7 +375,8 @@ App::icon_from_path(const string& path, int size) new IconDestroyNotification(*this, make_pair(path, size)), &App::icon_destroyed); } catch (const Glib::Error& e) { - Raul::warn << "Error loading icon: " << e.what() << endl; + log().warn(Raul::fmt("Error loading icon %1%: %2%\n") + % path % e.what()); } return buf; } |