Re: Gtk::TreeSelection::get_selected_rows()



Yeah,

I goofed in my example in that I forgot to dereference the path pointer returned by the std::vector<Gtk::TreeModel::Path>[] operator. Sorry about that.

Bob

Doug McLain wrote:

I sort of combined both of your examples to get an error free build:

vector<Gtk::TreeModel::Path> pathlist = redirect_display.get_selection()->get_selected_rows(); for (vector<Gtk::TreeModel::Path>::iterator iter = pathlist.begin(); iter != pathlist.end(); ++iter) {
        TreeModel::Row row = *(model->get_iter (*iter));
        redirects.push_back (row[columns.redirect]);
    }

Doug

<snip>




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