[gtkmm] how do I know when a row has been edited?



Hi!

How can I call a callback when a value in my list has been changed?
signal_changed() only calls my callback after selection but not when
I edit the row.

I read about signal_row_changed() but I don't have a TreeModel...


// TreeView of the columned list
Gtk::TreeView m_treeView;

// TreeModel of the columned list
Glib::RefPtr<Gtk::ListStore> m_listStoreRef; 

// Selection in current TreeView
Glib::RefPtr<Gtk::TreeSelection> m_treeSelRef; 


  // Build Tree Model/View
  m_listStoreRef = Gtk::ListStore::create(m_columns);
  m_treeView.set_model(m_listStoreRef);
  m_treeView.set_rules_hint();
  m_treeView.set_size_request();

  // Handle selection
  m_treeSelRef = m_treeView.get_selection();
  m_treeSelRef->set_mode(Gtk::SELECTION_SINGLE);
  m_treeSelRef->signal_changed().connect(SigC::slot (*this,
&ElementsTable::rowSelectionCallback));



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]