[niepce] Fix incorrect assert. Cosmetic debug message cleanup
- From: Hubert FiguiÃre <hub src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [niepce] Fix incorrect assert. Cosmetic debug message cleanup
- Date: Thu, 31 May 2012 06:20:57 +0000 (UTC)
commit 8f4d20c7f3618b7781b0d8346a8f0b528b01e899
Author: Hubert FiguiÃre <hub figuiere net>
Date: Sat Apr 28 20:03:54 2012 -0700
Fix incorrect assert.
Cosmetic debug message cleanup
src/fwk/toolkit/metadatawidget.cpp | 2 +-
src/niepce/ui/moduleshell.cpp | 4 ++--
2 files changed, 3 insertions(+), 3 deletions(-)
---
diff --git a/src/fwk/toolkit/metadatawidget.cpp b/src/fwk/toolkit/metadatawidget.cpp
index 10027df..6da89ed 100644
--- a/src/fwk/toolkit/metadatawidget.cpp
+++ b/src/fwk/toolkit/metadatawidget.cpp
@@ -327,7 +327,7 @@ bool MetaDataWidget::set_date_data(Gtk::Widget* w, const PropertyValue & value)
fwk::Date date = boost::get<fwk::Date>(value);
static_cast<Gtk::Label*>(w)->set_text(date.to_string());
- DBG_OUT("setting date data %s\n", date.to_string().c_str());
+ DBG_OUT("setting date data %s", date.to_string().c_str());
}
catch(...) {
return false;
diff --git a/src/niepce/ui/moduleshell.cpp b/src/niepce/ui/moduleshell.cpp
index ae4df92..4f98b20 100644
--- a/src/niepce/ui/moduleshell.cpp
+++ b/src/niepce/ui/moduleshell.cpp
@@ -258,13 +258,13 @@ void ModuleShell::on_image_activated(eng::library_id_t id)
void ModuleShell::on_module_deactivated(int idx)
{
- DBG_ASSERT((idx > 0) && ((unsigned)idx < m_modules.size()), "wrong module index");
+ DBG_ASSERT((idx >= 0) && ((unsigned)idx < m_modules.size()), "wrong module index");
m_modules[idx]->set_active(false);
}
void ModuleShell::on_module_activated(int idx)
{
- DBG_ASSERT((idx > 0) && ((unsigned)idx < m_modules.size()), "wrong module index");
+ DBG_ASSERT((idx >= 0) && ((unsigned)idx < m_modules.size()), "wrong module index");
m_modules[idx]->set_active(true);
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]