Lines Matching refs:model
29 #define TR_COLUMN_ID_KEY "tr-model-column-id-key"
60 GtkTreeModel * model; /* same object as store, but recast */
61 GtkTreeStore * store; /* same object as model, but recast */
101 refreshFilesForeach( GtkTreeModel * model,
114 const gboolean is_file = !gtk_tree_model_iter_has_child( model, iter );
116 gtk_tree_model_get( model, iter, FC_ENABLED, &old_enabled,
146 gtk_tree_sortable_set_sort_column_id( GTK_TREE_SORTABLE( data->model ),
171 if( gtk_tree_model_iter_children( model, &child, iter ) ) do
177 gtk_tree_model_get( model, &child, FC_SIZE, &child_size,
196 while( gtk_tree_model_iter_next( model, &child ) );
221 gtr_tree_model_foreach_postorder_subtree( GtkTreeModel * model,
227 if( gtk_tree_model_iter_children( model, &child, parent ) ) do
228 gtr_tree_model_foreach_postorder_subtree( model, &child, func, data );
229 while( gtk_tree_model_iter_next( model, &child ) );
231 func( model, NULL, parent, data );
235 gtr_tree_model_foreach_postorder( GtkTreeModel * model,
240 if( gtk_tree_model_iter_nth_child( model, &iter, NULL, 0 ) ) do
241 gtr_tree_model_foreach_postorder_subtree( model, &iter, func, data );
242 while( gtk_tree_model_iter_next( model, &iter ) );
260 GtkTreeSortable * sortable = GTK_TREE_SORTABLE( data->model );
269 gtr_tree_model_foreach_postorder( data->model, refreshFilesForeach, &refresh_data );
296 getSelectedFilesForeach( GtkTreeModel * model,
301 const gboolean is_file = !gtk_tree_model_iter_has_child( model, iter );
315 while( !is_active && gtk_tree_model_iter_parent( model, &parent, &walk ) )
325 gtk_tree_model_get( model, iter, FC_INDEX, &i, -1 );
352 getSubtreeForeach( GtkTreeModel * model,
357 const gboolean is_file = !gtk_tree_model_iter_has_child( model, iter );
366 gtk_tree_model_get( model, iter, FC_INDEX, &i, -1 );
499 /* instantiate the model */
513 data->model = GTK_TREE_MODEL( store );
516 /* populate the model */
556 /* now, add them to the model */
573 gtk_tree_view_set_model( GTK_TREE_VIEW( data->view ), data->model );
575 g_object_unref( data->model );
585 GtkTreeModel * model,
590 gtk_tree_model_get( model, iter, FC_ENABLED, &enabled, -1 );
599 GtkTreeModel * model,
605 gtk_tree_model_get( model, iter, FC_PRIORITY, &priority, -1 );
615 /* build a filename from tr_torrentGetCurrentDir() + the model's FC_LABELs */
617 buildFilename( tr_torrent * tor, GtkTreeModel * model,
628 gtk_tree_model_get( model, &child, FC_LABEL, &tokens[n--], -1 );
629 } while( gtk_tree_model_iter_parent( model, &parent, &child ) );
646 GtkTreeModel * model = gtk_tree_view_get_model( view );
648 if( gtk_tree_model_get_iter( model, &iter, path ) )
651 char * filename = buildFilename( tor, model, path, &iter );
652 gtk_tree_model_get( model, &iter, FC_PROG, &prog, -1 );
691 GtkTreeModel * model = data->model;
693 gtk_tree_model_get_iter( model, &iter, path );
698 gtk_tree_model_get( model, &iter, FC_PRIORITY, &priority, -1 );
712 gtk_tree_model_get( model, &iter, FC_ENABLED, &enabled, -1 );