2005-05-13 16:47:18 -04:00
// Generated by gtkmmproc -- DO NOT MODIFY!
2007-11-12 18:44:49 -05:00
2005-05-13 16:47:18 -04:00
# include <gtkmm/treeview.h>
# include <gtkmm/private/treeview_p.h>
# include <gtk/gtktypebuiltins.h>
2007-12-18 01:05:55 -05:00
// -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*-
2005-05-13 16:47:18 -04:00
/* $Id$ */
/* Copyright 2002 The gtkmm Development Team
*
* This library is free software ; you can redistribute it and / or
* modify it under the terms of the GNU Library General Public
* License as published by the Free Software Foundation ; either
* version 2 of the License , or ( at your option ) any later version .
*
* This library is distributed in the hope that it will be useful ,
* but WITHOUT ANY WARRANTY ; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE . See the GNU
* Library General Public License for more details .
*
* You should have received a copy of the GNU Library General Public
* License along with this library ; if not , write to the Free
* Software Foundation , Inc . , 675 Mass Ave , Cambridge , MA 0213 9 , USA .
*/
# include <gtkmm/treeviewcolumn.h>
# include <gtkmm/treeview_private.h>
# include <gtkmm/treemodel.h>
# include <gtkmm/treemodelfilter.h>
2007-11-12 18:44:49 -05:00
# include <gtkmm/entry.h>
# include <gtk/gtktreeview.h>
2005-05-13 16:47:18 -04:00
namespace
{
//This target name is used in the GTK+ implementation:
2007-11-12 18:44:49 -05:00
static const char treeview_target_row [ ] = " GTK_TREE_MODEL_ROW " ;
2005-05-13 16:47:18 -04:00
} // anonymous namespace
2007-11-12 18:44:49 -05:00
static void SignalProxy_Mapping_gtk_callback ( GtkTreeView * tree_view , GtkTreePath * path , void * data )
2005-05-13 16:47:18 -04:00
{
2007-11-12 18:44:49 -05:00
Gtk : : TreeView : : SlotMapping * the_slot = static_cast < Gtk : : TreeView : : SlotMapping * > ( data ) ;
2005-05-13 16:47:18 -04:00
2007-11-12 18:44:49 -05:00
# ifdef GLIBMM_EXCEPTIONS_ENABLED
2005-05-13 16:47:18 -04:00
try
{
2007-11-12 18:44:49 -05:00
# endif //GLIBMM_EXCEPTIONS_ENABLED
( * the_slot ) ( Glib : : wrap ( tree_view ) , Gtk : : TreePath ( path , true ) ) ;
# ifdef GLIBMM_EXCEPTIONS_ENABLED
2005-05-13 16:47:18 -04:00
}
catch ( . . . )
{
Glib : : exception_handlers_invoke ( ) ;
}
2007-11-12 18:44:49 -05:00
# endif //GLIBMM_EXCEPTIONS_ENABLED
2005-05-13 16:47:18 -04:00
}
2007-11-12 18:44:49 -05:00
static gboolean SignalProxy_SearchEqual_gtk_callback ( GtkTreeModel * model , int column , const char * key ,
2005-05-13 16:47:18 -04:00
GtkTreeIter * iter , void * data )
{
2007-11-12 18:44:49 -05:00
Gtk : : TreeView : : SlotSearchEqual * the_slot = static_cast < Gtk : : TreeView : : SlotSearchEqual * > ( data ) ;
2005-05-13 16:47:18 -04:00
2007-11-12 18:44:49 -05:00
# ifdef GLIBMM_EXCEPTIONS_ENABLED
2005-05-13 16:47:18 -04:00
try
{
2007-11-12 18:44:49 -05:00
# endif //GLIBMM_EXCEPTIONS_ENABLED
return ( * the_slot ) ( Glib : : wrap ( model , true ) , column , key , Gtk : : TreeIter ( model , iter ) ) ;
# ifdef GLIBMM_EXCEPTIONS_ENABLED
2005-05-13 16:47:18 -04:00
}
catch ( . . . )
{
Glib : : exception_handlers_invoke ( ) ;
}
return 0 ; // arbitrary value
2007-11-12 18:44:49 -05:00
# endif //GLIBMM_EXCEPTIONS_ENABLED
2005-05-13 16:47:18 -04:00
}
2007-11-12 18:44:49 -05:00
static void SignalProxy_SearchEqual_gtk_callback_destroy ( void * data )
2005-05-13 16:47:18 -04:00
{
2007-11-12 18:44:49 -05:00
delete static_cast < Gtk : : TreeView : : SlotSearchEqual * > ( data ) ;
2005-05-13 16:47:18 -04:00
}
2007-11-12 18:44:49 -05:00
static gboolean SignalProxy_ColumnDrop_gtk_callback ( GtkTreeView * tree_view , GtkTreeViewColumn * column ,
2005-05-13 16:47:18 -04:00
GtkTreeViewColumn * prev_column ,
GtkTreeViewColumn * next_column , void * data )
{
2007-11-12 18:44:49 -05:00
Gtk : : TreeView : : SlotColumnDrop * the_slot = static_cast < Gtk : : TreeView : : SlotColumnDrop * > ( data ) ;
2005-05-13 16:47:18 -04:00
2007-11-12 18:44:49 -05:00
# ifdef GLIBMM_EXCEPTIONS_ENABLED
2005-05-13 16:47:18 -04:00
try
{
2007-11-12 18:44:49 -05:00
# endif //GLIBMM_EXCEPTIONS_ENABLED
return ( * the_slot ) ( Glib : : wrap ( tree_view ) , Glib : : wrap ( column ) ,
2005-05-13 16:47:18 -04:00
Glib : : wrap ( prev_column ) , Glib : : wrap ( next_column ) ) ;
2007-11-12 18:44:49 -05:00
# ifdef GLIBMM_EXCEPTIONS_ENABLED
2005-05-13 16:47:18 -04:00
}
catch ( . . . )
{
Glib : : exception_handlers_invoke ( ) ;
}
2007-11-12 18:44:49 -05:00
# endif //GLIBMM_EXCEPTIONS_ENABLED
2005-05-13 16:47:18 -04:00
return 0 ; // arbitrary value
}
2007-11-12 18:44:49 -05:00
static void SignalProxy_ColumnDrop_gtk_callback_destroy ( void * data )
2005-05-13 16:47:18 -04:00
{
2007-11-12 18:44:49 -05:00
delete static_cast < Gtk : : TreeView : : SlotColumnDrop * > ( data ) ;
2005-05-13 16:47:18 -04:00
}
2007-11-12 18:44:49 -05:00
static void SignalProxy_SearchPosition_gtk_callback ( GtkTreeView * /* tree_view */ , GtkWidget * search_dialog , gpointer user_data )
{
Gtk : : TreeView : : SlotSearchPosition * the_slot = static_cast < Gtk : : TreeView : : SlotSearchPosition * > ( user_data ) ;
# ifdef GLIBMM_EXCEPTIONS_ENABLED
try
{
# endif //GLIBMM_EXCEPTIONS_ENABLED
( * the_slot ) ( Glib : : wrap ( search_dialog ) ) ;
# ifdef GLIBMM_EXCEPTIONS_ENABLED
}
catch ( . . . )
{
Glib : : exception_handlers_invoke ( ) ;
}
# endif //GLIBMM_EXCEPTIONS_ENABLED
}
static void SignalProxy_SearchPosition_gtk_callback_destroy ( void * data )
{
delete static_cast < Gtk : : TreeView : : SlotSearchPosition * > ( data ) ;
}
2005-05-13 16:47:18 -04:00
namespace Gtk
{
void TreeView : : unset_hadjustment ( )
{
gtk_tree_view_set_hadjustment ( gobj ( ) , 0 ) ;
}
void TreeView : : unset_vadjustment ( )
{
gtk_tree_view_set_vadjustment ( gobj ( ) , 0 ) ;
}
int TreeView : : insert_column_with_data_func ( int position , const Glib : : ustring & title , CellRenderer & cell , const SlotCellData & slot )
{
2007-11-12 18:44:49 -05:00
//Create a copy of the slot. A pointer to this will be passed through the callback's data parameter.
//It will be deleted when TreeView_Private::SignalProxy_CellData_gtk_callback_destroy() is called.
SlotCellData * slot_copy = new SlotCellData ( slot ) ;
2005-05-13 16:47:18 -04:00
return gtk_tree_view_insert_column_with_data_func (
gobj ( ) , position , title . c_str ( ) , cell . gobj ( ) ,
2007-11-12 18:44:49 -05:00
& TreeView_Private : : SignalProxy_CellData_gtk_callback , slot_copy ,
& TreeView_Private : : SignalProxy_CellData_gtk_callback_destroy ) ;
2005-05-13 16:47:18 -04:00
}
void TreeView : : set_cursor ( const TreeModel : : Path & path )
{
gtk_tree_view_set_cursor ( gobj ( ) , const_cast < GtkTreePath * > ( path . gobj ( ) ) , 0 , false ) ;
}
void TreeView : : get_cursor ( TreeModel : : Path & path , TreeViewColumn * & focus_column )
{
GtkTreePath * pTreePath = 0 ;
GtkTreeViewColumn * pTreeViewColumn = 0 ;
gtk_tree_view_get_cursor ( gobj ( ) , & pTreePath , & pTreeViewColumn ) ;
2007-12-18 01:05:55 -05:00
path = TreeModel : : Path ( pTreePath , false ) ; /* Use the existing underlying GtkTreePath instance without copying and freeing, because gtk_tree_view_get_cursor() gives us ownernship. */
2005-05-13 16:47:18 -04:00
focus_column = Glib : : wrap ( pTreeViewColumn ) ;
}
void TreeView : : enable_model_drag_source ( const ArrayHandle_TargetEntry & targets ,
Gdk : : ModifierType start_button_mask ,
Gdk : : DragAction actions )
{
gtk_tree_view_enable_model_drag_source (
gobj ( ) , ( GdkModifierType ) start_button_mask ,
targets . data ( ) , targets . size ( ) , ( GdkDragAction ) actions ) ;
}
void TreeView : : enable_model_drag_source ( Gdk : : ModifierType start_button_mask , Gdk : : DragAction actions )
{
std : : list < TargetEntry > listTargets ;
listTargets . push_back ( TargetEntry ( treeview_target_row ) ) ;
enable_model_drag_source ( listTargets , start_button_mask , actions ) ;
}
void TreeView : : enable_model_drag_dest ( const ArrayHandle_TargetEntry & targets , Gdk : : DragAction actions )
{
gtk_tree_view_enable_model_drag_dest (
gobj ( ) , targets . data ( ) , targets . size ( ) , ( GdkDragAction ) actions ) ;
}
void TreeView : : enable_model_drag_dest ( Gdk : : DragAction actions )
{
std : : list < TargetEntry > listTargets ;
listTargets . push_back ( TargetEntry ( treeview_target_row ) ) ;
enable_model_drag_dest ( listTargets , actions ) ;
}
2007-11-12 18:44:49 -05:00
# ifndef GTKMM_DISABLE_DEPRECATED
2005-05-13 16:47:18 -04:00
bool TreeView : : get_path_at_pos ( int x , int y , TreeModel : : Path & path , TreeViewColumn * & column , int & cell_x , int & cell_y )
{
GtkTreePath * pTreePath = 0 ;
GtkTreeViewColumn * pTreeViewColumn = 0 ;
bool result = gtk_tree_view_get_path_at_pos ( gobj ( ) , x , y , & pTreePath , & pTreeViewColumn , & cell_x , & cell_y ) ;
path = TreeModel : : Path ( pTreePath , false /* don't take a copy, because the gtk_tree_view_get_path_at_pos() docs say that we must free the path */ ) ;
column = Glib : : wrap ( pTreeViewColumn ) ;
return result ;
}
2007-11-12 18:44:49 -05:00
# endif // GTKMM_DISABLE_DEPRECATED
bool TreeView : : get_path_at_pos ( int x , int y , TreeModel : : Path & path , TreeViewColumn * & column , int & cell_x , int & cell_y ) const
{
GtkTreePath * pTreePath = 0 ;
GtkTreeViewColumn * pTreeViewColumn = 0 ;
bool result = gtk_tree_view_get_path_at_pos ( const_cast < GtkTreeView * > ( gobj ( ) ) , x , y , & pTreePath , & pTreeViewColumn , & cell_x , & cell_y ) ;
path = TreeModel : : Path ( pTreePath , false /* don't take a copy, because the gtk_tree_view_get_path_at_pos() docs say that we must free the path */ ) ;
column = Glib : : wrap ( pTreeViewColumn ) ;
return result ;
}
2005-05-13 16:47:18 -04:00
int TreeView : : insert_column ( const Glib : : ustring & title , CellRenderer & cell , int position )
{
return gtk_tree_view_insert_column_with_attributes (
gobj ( ) , position , const_cast < char * > ( title . c_str ( ) ) , cell . gobj ( ) , ( void * ) 0 ) ; //Note that some compilers need the extra (void*) clue.
}
int TreeView : : append_column ( const Glib : : ustring & title , CellRenderer & cell )
{
return insert_column ( title , cell , - 1 /* at the end */ ) ;
}
void TreeView : : get_drag_dest_row ( TreeModel : : Path & path , TreeViewDropPosition & pos ) const
{
GtkTreePath * pTreePath = 0 ;
gtk_tree_view_get_drag_dest_row ( const_cast < GtkTreeView * > ( gobj ( ) ) , & pTreePath , ( GtkTreeViewDropPosition * ) & pos ) ;
path = TreeModel : : Path ( pTreePath , true ) ; //true = take_copy.
}
bool TreeView : : get_dest_row_at_pos ( int drag_x , int drag_y , TreeModel : : Path & path , TreeViewDropPosition & pos ) const
{
GtkTreePath * pTreePath = 0 ;
const bool bResult = gtk_tree_view_get_dest_row_at_pos (
const_cast < GtkTreeView * > ( gobj ( ) ) , drag_x , drag_y , & pTreePath , ( GtkTreeViewDropPosition * ) & pos ) ;
path = TreeModel : : Path ( pTreePath , true ) ; //true = take_copy.
return bResult ;
}
void TreeView : : map_expanded_rows ( const SlotMapping & slot )
{
2007-11-12 18:44:49 -05:00
gtk_tree_view_map_expanded_rows ( gobj ( ) , & SignalProxy_Mapping_gtk_callback , const_cast < SlotMapping * > ( & slot ) ) ;
2005-05-13 16:47:18 -04:00
}
void TreeView : : set_search_equal_func ( const SlotSearchEqual & slot )
{
2007-11-12 18:44:49 -05:00
//Create a copy of the slot. A pointer to this will be passed through the callback's data parameter.
//It will be deleted when SignalProxy_SearchEqual_gtk_callback_destroy() is called.
SlotSearchEqual * slot_copy = new SlotSearchEqual ( slot ) ;
2005-05-13 16:47:18 -04:00
gtk_tree_view_set_search_equal_func ( gobj ( ) ,
2007-11-12 18:44:49 -05:00
& SignalProxy_SearchEqual_gtk_callback , slot_copy ,
& SignalProxy_SearchEqual_gtk_callback_destroy ) ;
2005-05-13 16:47:18 -04:00
}
void TreeView : : set_column_drag_function ( const SlotColumnDrop & slot )
{
2007-11-12 18:44:49 -05:00
//Create a copt of the slot. A pointer to this will be passed through the callback's data parameter.
//It will be deleted when SignalProxy_ColumnDrop_gtk_callback_destroy() is called.
SlotColumnDrop * slot_copy = new SlotColumnDrop ( slot ) ;
2005-05-13 16:47:18 -04:00
gtk_tree_view_set_column_drag_function ( gobj ( ) ,
2007-11-12 18:44:49 -05:00
& SignalProxy_ColumnDrop_gtk_callback , slot_copy ,
& SignalProxy_ColumnDrop_gtk_callback_destroy ) ;
2005-05-13 16:47:18 -04:00
}
void TreeView : : unset_column_drag_function ( )
{
gtk_tree_view_set_column_drag_function ( gobj ( ) ,
0 , 0 , 0 ) ; /* See GTK+ docs about the 0s. */
}
void TreeView : : scroll_to_cell ( const TreeModel : : Path & path , TreeViewColumn & column , float row_align , float col_align )
{
gtk_tree_view_scroll_to_cell ( gobj ( ) , const_cast < GtkTreePath * > ( path . gobj ( ) ) , column . gobj ( ) , TRUE , row_align , col_align ) ;
}
void TreeView : : scroll_to_cell ( const TreeModel : : Path & path , TreeViewColumn & column )
{
gtk_tree_view_scroll_to_cell ( gobj ( ) , const_cast < GtkTreePath * > ( path . gobj ( ) ) , column . gobj ( ) , FALSE , 0.0 , 0.0 ) ;
}
void TreeView : : scroll_to_row ( const TreeModel : : Path & path , float row_align )
{
gtk_tree_view_scroll_to_cell ( gobj ( ) , const_cast < GtkTreePath * > ( path . gobj ( ) ) , 0 , TRUE , row_align , 0.0 ) ;
}
void TreeView : : scroll_to_row ( const TreeModel : : Path & path )
{
gtk_tree_view_scroll_to_cell ( gobj ( ) , const_cast < GtkTreePath * > ( path . gobj ( ) ) , 0 , FALSE , 0.0 , 0.0 ) ;
}
void TreeView : : scroll_to_column ( TreeViewColumn & column , float col_align )
{
gtk_tree_view_scroll_to_cell ( gobj ( ) , 0 , column . gobj ( ) , TRUE , 0.0 , col_align ) ;
}
void TreeView : : scroll_to_column ( TreeViewColumn & column )
{
gtk_tree_view_scroll_to_cell ( gobj ( ) , 0 , column . gobj ( ) , FALSE , 0.0 , 0.0 ) ;
}
void TreeView : : remove_all_columns ( )
{
//This method is not in GTK+, but it seems useful.
//Remove all View columns:
typedef std : : list < Gtk : : TreeView : : Column * > type_vecViewColumns ;
type_vecViewColumns vecViewColumns = get_columns ( ) ;
for ( type_vecViewColumns : : iterator iter = vecViewColumns . begin ( ) ; iter ! = vecViewColumns . end ( ) ; + + iter )
{
Gtk : : TreeView : : Column * pViewColumn = * iter ;
if ( pViewColumn )
remove_column ( * pViewColumn ) ;
}
}
CellRenderer * TreeView : : get_column_cell_renderer ( int n )
{
TreeViewColumn * pColumn = get_column ( n ) ;
if ( pColumn )
return pColumn - > get_first_cell_renderer ( ) ;
else
return 0 ;
}
const CellRenderer * TreeView : : get_column_cell_renderer ( int n ) const
{
//Do some const_cast-ing to avoid repetition of code:
CellRenderer * pRenderer = const_cast < TreeView * > ( this ) - > get_column_cell_renderer ( n ) ;
return pRenderer ;
}
void TreeView : : reset_expander_column ( )
{
gtk_tree_view_set_expander_column ( gobj ( ) , 0 /* see C docs */ ) ;
}
Glib : : RefPtr < Gtk : : TreeModel > TreeView : : _get_base_model ( )
{
Glib : : RefPtr < TreeModel > refModel = get_model ( ) ;
bool get_child = true ;
while ( get_child & & refModel )
{
Glib : : RefPtr < Gtk : : TreeModelFilter > refModelFilter = Glib : : RefPtr < Gtk : : TreeModelFilter > : : cast_dynamic ( refModel ) ;
if ( refModelFilter )
refModel = refModelFilter - > get_model ( ) ;
else
get_child = false ;
}
return refModel ;
}
void TreeView : : _auto_store_on_cellrenderer_toggle_edited ( const Glib : : ustring & path_string ,
int model_column )
2007-11-12 18:44:49 -05:00
{
_auto_store_on_cellrenderer_toggle_edited_with_model ( path_string , model_column , _get_base_model ( ) ) ;
}
void TreeView : : _auto_store_on_cellrenderer_toggle_edited_with_model ( const Glib : : ustring & path_string ,
int model_column , const Glib : : RefPtr < Gtk : : TreeModel > & model )
2005-05-13 16:47:18 -04:00
{
Gtk : : TreePath path ( path_string ) ;
//Get the row from the path:
2007-11-12 18:44:49 -05:00
if ( model )
2005-05-13 16:47:18 -04:00
{
2007-11-12 18:44:49 -05:00
Gtk : : TreeModel : : iterator iter = model - > get_iter ( path ) ;
if ( iter )
{
2005-05-13 16:47:18 -04:00
Gtk : : TreeRow row = * iter ;
2007-11-12 18:44:49 -05:00
2005-05-13 16:47:18 -04:00
//Get the new value:
//This seems to get the old value, not the new one,
//so we will just NOT the model value ourselves.
//bool bActive = cell_renderer->get_active();
bool bActive = false ;
row . get_value ( model_column , bActive ) ;
bActive = ! bActive ;
2007-11-12 18:44:49 -05:00
//Store the user's new text in the model:
2005-05-13 16:47:18 -04:00
row . set_value ( model_column , bActive ) ;
2007-11-12 18:44:49 -05:00
}
2005-05-13 16:47:18 -04:00
}
}
void TreeView : : move_column_to_start ( TreeViewColumn & column )
{
gtk_tree_view_move_column_after ( gobj ( ) , ( column ) . gobj ( ) , 0 /* See C docs */ ) ;
}
void TreeView : : set_row_separator_func ( const SlotRowSeparator & slot )
{
2007-11-12 18:44:49 -05:00
//Create a copy of the slot. A pointer to this will be passed through the callback's data parameter.
//It will be deleted when SignalProxy_RowSeparator_gtk_callback_destroy() is called.
SlotRowSeparator * slot_copy = new SlotRowSeparator ( slot ) ;
2005-05-13 16:47:18 -04:00
gtk_tree_view_set_row_separator_func ( gobj ( ) ,
2007-11-12 18:44:49 -05:00
& TreeView_Private : : SignalProxy_RowSeparator_gtk_callback , slot_copy ,
& TreeView_Private : : SignalProxy_RowSeparator_gtk_callback_destroy ) ;
}
void TreeView : : set_search_position_func ( const SlotSearchPosition & slot )
{
//Create a copy of the slot. A pointer to this will be passed through the callback's data parameter.
//It will be deleted when SignalProxy_SearchPosition_gtk_callback_destroy() is called.
SlotSearchPosition * slot_copy = new SlotSearchPosition ( slot ) ;
gtk_tree_view_set_search_position_func ( gobj ( ) ,
& SignalProxy_SearchPosition_gtk_callback , slot_copy ,
& SignalProxy_SearchPosition_gtk_callback_destroy ) ;
}
bool TreeView : : get_visible_range ( TreeModel : : Path & start_path , TreeModel : : Path & end_path ) const
{
GtkTreePath * pTreePathStart = 0 ;
GtkTreePath * pTreePathEnd = 0 ;
bool result = gtk_tree_view_get_visible_range ( const_cast < GtkTreeView * > ( gobj ( ) ) , & pTreePathStart , & pTreePathEnd ) ;
start_path = TreeModel : : Path ( pTreePathStart , false /* don't take a copy, because the gtk_tree_view_get_visible_range() docs say that we must free the path */ ) ;
end_path = TreeModel : : Path ( pTreePathEnd , false /* don't take a copy, because the gtk_tree_view_get_visible_range() docs say that we must free the path */ ) ;
return result ;
}
void TreeView : : unset_model ( )
{
gtk_tree_view_set_model ( gobj ( ) , 0 ) ;
2005-05-13 16:47:18 -04:00
}
2007-12-18 01:05:55 -05:00
bool
TreeView : : get_tooltip_context_path ( int & x , int & y ,
bool keyboard_tip ,
TreeModel : : Path & path )
{
//It's cleaner to use a temporary C++ object and get a C pointer to it,
//because GtkTreePath is a simple struct, not a GtkObject, so
//gtk_tree_path_new() would be necessary. markoa.
TreeModel : : Path tmp_path ;
GtkTreePath * cpath = tmp_path . gobj ( ) ;
gboolean result =
gtk_tree_view_get_tooltip_context ( gobj ( ) ,
& x , & y ,
keyboard_tip ,
0 ,
& cpath ,
0 ) ;
path = Glib : : wrap ( cpath , false /* take_copy=false */ ) ;
return result ;
}
bool
TreeView : : get_tooltip_context_iter ( int & x , int & y ,
bool keyboard_tip ,
Gtk : : TreeModel : : iterator & iter )
{
GtkTreeIter src_iter ;
gboolean result =
gtk_tree_view_get_tooltip_context ( gobj ( ) ,
& x , & y ,
keyboard_tip ,
0 ,
0 ,
& src_iter ) ;
2005-05-13 16:47:18 -04:00
2007-12-18 01:05:55 -05:00
iter = TreeIter ( gtk_tree_view_get_model ( this - > gobj ( ) ) , & src_iter ) ;
return result ;
}
} // namespace Gtk
2005-05-13 16:47:18 -04:00
namespace
{
2007-11-12 18:44:49 -05:00
static void TreeView_signal_set_scroll_adjustments_callback ( GtkTreeView * self , GtkAdjustment * p0 , GtkAdjustment * p1 , void * data )
2005-05-13 16:47:18 -04:00
{
using namespace Gtk ;
typedef sigc : : slot < void , Adjustment * , Adjustment * > SlotType ;
// Do not try to call a signal on a disassociated wrapper.
if ( Glib : : ObjectBase : : _get_current_wrapper ( ( GObject * ) self ) )
{
2007-11-12 18:44:49 -05:00
# ifdef GLIBMM_EXCEPTIONS_ENABLED
2005-05-13 16:47:18 -04:00
try
{
2007-11-12 18:44:49 -05:00
# endif //GLIBMM_EXCEPTIONS_ENABLED
2005-05-13 16:47:18 -04:00
if ( sigc : : slot_base * const slot = Glib : : SignalProxyNormal : : data_to_slot ( data ) )
( * static_cast < SlotType * > ( slot ) ) ( Glib : : wrap ( p0 )
, Glib : : wrap ( p1 )
) ;
2007-11-12 18:44:49 -05:00
# ifdef GLIBMM_EXCEPTIONS_ENABLED
2005-05-13 16:47:18 -04:00
}
catch ( . . . )
{
Glib : : exception_handlers_invoke ( ) ;
}
2007-11-12 18:44:49 -05:00
# endif //GLIBMM_EXCEPTIONS_ENABLED
2005-05-13 16:47:18 -04:00
}
}
2007-11-12 18:44:49 -05:00
static const Glib : : SignalProxyInfo TreeView_signal_set_scroll_adjustments_info =
2005-05-13 16:47:18 -04:00
{
" set-scroll-adjustments " ,
( GCallback ) & TreeView_signal_set_scroll_adjustments_callback ,
( GCallback ) & TreeView_signal_set_scroll_adjustments_callback
} ;
2007-11-12 18:44:49 -05:00
static void TreeView_signal_row_activated_callback ( GtkTreeView * self , GtkTreePath * p0 , GtkTreeViewColumn * p1 , void * data )
2005-05-13 16:47:18 -04:00
{
using namespace Gtk ;
typedef sigc : : slot < void , const TreeModel : : Path & , TreeViewColumn * > SlotType ;
// Do not try to call a signal on a disassociated wrapper.
if ( Glib : : ObjectBase : : _get_current_wrapper ( ( GObject * ) self ) )
{
2007-11-12 18:44:49 -05:00
# ifdef GLIBMM_EXCEPTIONS_ENABLED
2005-05-13 16:47:18 -04:00
try
{
2007-11-12 18:44:49 -05:00
# endif //GLIBMM_EXCEPTIONS_ENABLED
2005-05-13 16:47:18 -04:00
if ( sigc : : slot_base * const slot = Glib : : SignalProxyNormal : : data_to_slot ( data ) )
( * static_cast < SlotType * > ( slot ) ) ( Gtk : : TreePath ( p0 , true )
, Glib : : wrap ( p1 )
) ;
2007-11-12 18:44:49 -05:00
# ifdef GLIBMM_EXCEPTIONS_ENABLED
2005-05-13 16:47:18 -04:00
}
catch ( . . . )
{
Glib : : exception_handlers_invoke ( ) ;
}
2007-11-12 18:44:49 -05:00
# endif //GLIBMM_EXCEPTIONS_ENABLED
2005-05-13 16:47:18 -04:00
}
}
2007-11-12 18:44:49 -05:00
static const Glib : : SignalProxyInfo TreeView_signal_row_activated_info =
2005-05-13 16:47:18 -04:00
{
" row-activated " ,
( GCallback ) & TreeView_signal_row_activated_callback ,
( GCallback ) & TreeView_signal_row_activated_callback
} ;
2007-11-12 18:44:49 -05:00
static gboolean TreeView_signal_test_expand_row_callback ( GtkTreeView * self , GtkTreeIter * p0 , GtkTreePath * p1 , void * data )
2005-05-13 16:47:18 -04:00
{
using namespace Gtk ;
typedef sigc : : slot < bool , const TreeModel : : iterator & , const TreeModel : : Path & > SlotType ;
// Do not try to call a signal on a disassociated wrapper.
if ( Glib : : ObjectBase : : _get_current_wrapper ( ( GObject * ) self ) )
{
2007-11-12 18:44:49 -05:00
# ifdef GLIBMM_EXCEPTIONS_ENABLED
2005-05-13 16:47:18 -04:00
try
{
2007-11-12 18:44:49 -05:00
# endif //GLIBMM_EXCEPTIONS_ENABLED
2005-05-13 16:47:18 -04:00
if ( sigc : : slot_base * const slot = Glib : : SignalProxyNormal : : data_to_slot ( data ) )
return static_cast < int > ( ( * static_cast < SlotType * > ( slot ) ) ( TreeModel : : iterator ( gtk_tree_view_get_model ( self ) , p0 )
, Gtk : : TreePath ( p1 , true )
) ) ;
2007-11-12 18:44:49 -05:00
# ifdef GLIBMM_EXCEPTIONS_ENABLED
2005-05-13 16:47:18 -04:00
}
catch ( . . . )
{
Glib : : exception_handlers_invoke ( ) ;
}
2007-11-12 18:44:49 -05:00
# endif //GLIBMM_EXCEPTIONS_ENABLED
2005-05-13 16:47:18 -04:00
}
typedef gboolean RType ;
return RType ( ) ;
}
2007-11-12 18:44:49 -05:00
static gboolean TreeView_signal_test_expand_row_notify_callback ( GtkTreeView * self , GtkTreeIter * p0 , GtkTreePath * p1 , void * data )
2005-05-13 16:47:18 -04:00
{
using namespace Gtk ;
typedef sigc : : slot < void , const TreeModel : : iterator & , const TreeModel : : Path & > SlotType ;
// Do not try to call a signal on a disassociated wrapper.
if ( Glib : : ObjectBase : : _get_current_wrapper ( ( GObject * ) self ) )
{
2007-11-12 18:44:49 -05:00
# ifdef GLIBMM_EXCEPTIONS_ENABLED
2005-05-13 16:47:18 -04:00
try
{
2007-11-12 18:44:49 -05:00
# endif //GLIBMM_EXCEPTIONS_ENABLED
2005-05-13 16:47:18 -04:00
if ( sigc : : slot_base * const slot = Glib : : SignalProxyNormal : : data_to_slot ( data ) )
( * static_cast < SlotType * > ( slot ) ) ( TreeModel : : iterator ( gtk_tree_view_get_model ( self ) , p0 )
, Gtk : : TreePath ( p1 , true )
) ;
2007-11-12 18:44:49 -05:00
# ifdef GLIBMM_EXCEPTIONS_ENABLED
2005-05-13 16:47:18 -04:00
}
catch ( . . . )
{
Glib : : exception_handlers_invoke ( ) ;
}
2007-11-12 18:44:49 -05:00
# endif //GLIBMM_EXCEPTIONS_ENABLED
2005-05-13 16:47:18 -04:00
}
typedef gboolean RType ;
return RType ( ) ;
}
2007-11-12 18:44:49 -05:00
static const Glib : : SignalProxyInfo TreeView_signal_test_expand_row_info =
2005-05-13 16:47:18 -04:00
{
" test-expand-row " ,
( GCallback ) & TreeView_signal_test_expand_row_callback ,
( GCallback ) & TreeView_signal_test_expand_row_notify_callback
} ;
2007-11-12 18:44:49 -05:00
static gboolean TreeView_signal_test_collapse_row_callback ( GtkTreeView * self , GtkTreeIter * p0 , GtkTreePath * p1 , void * data )
2005-05-13 16:47:18 -04:00
{
using namespace Gtk ;
typedef sigc : : slot < bool , const TreeModel : : iterator & , const TreeModel : : Path & > SlotType ;
// Do not try to call a signal on a disassociated wrapper.
if ( Glib : : ObjectBase : : _get_current_wrapper ( ( GObject * ) self ) )
{
2007-11-12 18:44:49 -05:00
# ifdef GLIBMM_EXCEPTIONS_ENABLED
2005-05-13 16:47:18 -04:00
try
{
2007-11-12 18:44:49 -05:00
# endif //GLIBMM_EXCEPTIONS_ENABLED
2005-05-13 16:47:18 -04:00
if ( sigc : : slot_base * const slot = Glib : : SignalProxyNormal : : data_to_slot ( data ) )
return static_cast < int > ( ( * static_cast < SlotType * > ( slot ) ) ( TreeModel : : iterator ( gtk_tree_view_get_model ( self ) , p0 )
, Gtk : : TreePath ( p1 , true )
) ) ;
2007-11-12 18:44:49 -05:00
# ifdef GLIBMM_EXCEPTIONS_ENABLED
2005-05-13 16:47:18 -04:00
}
catch ( . . . )
{
Glib : : exception_handlers_invoke ( ) ;
}
2007-11-12 18:44:49 -05:00
# endif //GLIBMM_EXCEPTIONS_ENABLED
2005-05-13 16:47:18 -04:00
}
typedef gboolean RType ;
return RType ( ) ;
}
2007-11-12 18:44:49 -05:00
static gboolean TreeView_signal_test_collapse_row_notify_callback ( GtkTreeView * self , GtkTreeIter * p0 , GtkTreePath * p1 , void * data )
2005-05-13 16:47:18 -04:00
{
using namespace Gtk ;
typedef sigc : : slot < void , const TreeModel : : iterator & , const TreeModel : : Path & > SlotType ;
// Do not try to call a signal on a disassociated wrapper.
if ( Glib : : ObjectBase : : _get_current_wrapper ( ( GObject * ) self ) )
{
2007-11-12 18:44:49 -05:00
# ifdef GLIBMM_EXCEPTIONS_ENABLED
2005-05-13 16:47:18 -04:00
try
{
2007-11-12 18:44:49 -05:00
# endif //GLIBMM_EXCEPTIONS_ENABLED
2005-05-13 16:47:18 -04:00
if ( sigc : : slot_base * const slot = Glib : : SignalProxyNormal : : data_to_slot ( data ) )
( * static_cast < SlotType * > ( slot ) ) ( TreeModel : : iterator ( gtk_tree_view_get_model ( self ) , p0 )
, Gtk : : TreePath ( p1 , true )
) ;
2007-11-12 18:44:49 -05:00
# ifdef GLIBMM_EXCEPTIONS_ENABLED
2005-05-13 16:47:18 -04:00
}
catch ( . . . )
{
Glib : : exception_handlers_invoke ( ) ;
}
2007-11-12 18:44:49 -05:00
# endif //GLIBMM_EXCEPTIONS_ENABLED
2005-05-13 16:47:18 -04:00
}
typedef gboolean RType ;
return RType ( ) ;
}
2007-11-12 18:44:49 -05:00
static const Glib : : SignalProxyInfo TreeView_signal_test_collapse_row_info =
2005-05-13 16:47:18 -04:00
{
" test-collapse-row " ,
( GCallback ) & TreeView_signal_test_collapse_row_callback ,
( GCallback ) & TreeView_signal_test_collapse_row_notify_callback
} ;
2007-11-12 18:44:49 -05:00
static void TreeView_signal_row_expanded_callback ( GtkTreeView * self , GtkTreeIter * p0 , GtkTreePath * p1 , void * data )
2005-05-13 16:47:18 -04:00
{
using namespace Gtk ;
typedef sigc : : slot < void , const TreeModel : : iterator & , const TreeModel : : Path & > SlotType ;
// Do not try to call a signal on a disassociated wrapper.
if ( Glib : : ObjectBase : : _get_current_wrapper ( ( GObject * ) self ) )
{
2007-11-12 18:44:49 -05:00
# ifdef GLIBMM_EXCEPTIONS_ENABLED
2005-05-13 16:47:18 -04:00
try
{
2007-11-12 18:44:49 -05:00
# endif //GLIBMM_EXCEPTIONS_ENABLED
2005-05-13 16:47:18 -04:00
if ( sigc : : slot_base * const slot = Glib : : SignalProxyNormal : : data_to_slot ( data ) )
( * static_cast < SlotType * > ( slot ) ) ( TreeModel : : iterator ( gtk_tree_view_get_model ( self ) , p0 )
, Gtk : : TreePath ( p1 , true )
) ;
2007-11-12 18:44:49 -05:00
# ifdef GLIBMM_EXCEPTIONS_ENABLED
2005-05-13 16:47:18 -04:00
}
catch ( . . . )
{
Glib : : exception_handlers_invoke ( ) ;
}
2007-11-12 18:44:49 -05:00
# endif //GLIBMM_EXCEPTIONS_ENABLED
2005-05-13 16:47:18 -04:00
}
}
2007-11-12 18:44:49 -05:00
static const Glib : : SignalProxyInfo TreeView_signal_row_expanded_info =
2005-05-13 16:47:18 -04:00
{
" row-expanded " ,
( GCallback ) & TreeView_signal_row_expanded_callback ,
( GCallback ) & TreeView_signal_row_expanded_callback
} ;
2007-11-12 18:44:49 -05:00
static void TreeView_signal_row_collapsed_callback ( GtkTreeView * self , GtkTreeIter * p0 , GtkTreePath * p1 , void * data )
2005-05-13 16:47:18 -04:00
{
using namespace Gtk ;
typedef sigc : : slot < void , const TreeModel : : iterator & , const TreeModel : : Path & > SlotType ;
// Do not try to call a signal on a disassociated wrapper.
if ( Glib : : ObjectBase : : _get_current_wrapper ( ( GObject * ) self ) )
{
2007-11-12 18:44:49 -05:00
# ifdef GLIBMM_EXCEPTIONS_ENABLED
2005-05-13 16:47:18 -04:00
try
{
2007-11-12 18:44:49 -05:00
# endif //GLIBMM_EXCEPTIONS_ENABLED
2005-05-13 16:47:18 -04:00
if ( sigc : : slot_base * const slot = Glib : : SignalProxyNormal : : data_to_slot ( data ) )
( * static_cast < SlotType * > ( slot ) ) ( TreeModel : : iterator ( gtk_tree_view_get_model ( self ) , p0 )
, Gtk : : TreePath ( p1 , true )
) ;
2007-11-12 18:44:49 -05:00
# ifdef GLIBMM_EXCEPTIONS_ENABLED
2005-05-13 16:47:18 -04:00
}
catch ( . . . )
{
Glib : : exception_handlers_invoke ( ) ;
}
2007-11-12 18:44:49 -05:00
# endif //GLIBMM_EXCEPTIONS_ENABLED
2005-05-13 16:47:18 -04:00
}
}
2007-11-12 18:44:49 -05:00
static const Glib : : SignalProxyInfo TreeView_signal_row_collapsed_info =
2005-05-13 16:47:18 -04:00
{
" row-collapsed " ,
( GCallback ) & TreeView_signal_row_collapsed_callback ,
( GCallback ) & TreeView_signal_row_collapsed_callback
} ;
2007-11-12 18:44:49 -05:00
static const Glib : : SignalProxyInfo TreeView_signal_cursor_changed_info =
2005-05-13 16:47:18 -04:00
{
" cursor-changed " ,
( GCallback ) & Glib : : SignalProxyNormal : : slot0_void_callback ,
( GCallback ) & Glib : : SignalProxyNormal : : slot0_void_callback
} ;
2007-11-12 18:44:49 -05:00
static const Glib : : SignalProxyInfo TreeView_signal_columns_changed_info =
2005-05-13 16:47:18 -04:00
{
" columns-changed " ,
( GCallback ) & Glib : : SignalProxyNormal : : slot0_void_callback ,
( GCallback ) & Glib : : SignalProxyNormal : : slot0_void_callback
} ;
2007-11-12 18:44:49 -05:00
2005-05-13 16:47:18 -04:00
} // anonymous namespace
// static
GType Glib : : Value < Gtk : : TreeViewDropPosition > : : value_type ( )
{
return gtk_tree_view_drop_position_get_type ( ) ;
}
2007-11-12 18:44:49 -05:00
// static
GType Glib : : Value < Gtk : : TreeViewGridLines > : : value_type ( )
{
return gtk_tree_view_grid_lines_get_type ( ) ;
}
2005-05-13 16:47:18 -04:00
namespace Glib
{
Gtk : : TreeView * wrap ( GtkTreeView * object , bool take_copy )
{
return dynamic_cast < Gtk : : TreeView * > ( Glib : : wrap_auto ( ( GObject * ) ( object ) , take_copy ) ) ;
}
} /* namespace Glib */
namespace Gtk
{
/* The *_Class implementation: */
const Glib : : Class & TreeView_Class : : init ( )
{
if ( ! gtype_ ) // create the GType if necessary
{
// Glib::Class has to know the class init function to clone custom types.
class_init_func_ = & TreeView_Class : : class_init_function ;
// This is actually just optimized away, apparently with no harm.
// Make sure that the parent type has been created.
//CppClassParent::CppObjectType::get_type();
// Create the wrapper type, with the same class/instance size as the base type.
register_derived_type ( gtk_tree_view_get_type ( ) ) ;
// Add derived versions of interfaces, if the C type implements any interfaces:
}
return * this ;
}
void TreeView_Class : : class_init_function ( void * g_class , void * class_data )
{
BaseClassType * const klass = static_cast < BaseClassType * > ( g_class ) ;
CppClassParent : : class_init_function ( klass , class_data ) ;
2007-11-12 18:44:49 -05:00
# ifdef GLIBMM_VFUNCS_ENABLED
# endif //GLIBMM_VFUNCS_ENABLED
# ifdef GLIBMM_DEFAULT_SIGNAL_HANDLERS_ENABLED
2005-05-13 16:47:18 -04:00
klass - > set_scroll_adjustments = & set_scroll_adjustments_callback ;
klass - > row_activated = & row_activated_callback ;
klass - > test_expand_row = & test_expand_row_callback ;
klass - > test_collapse_row = & test_collapse_row_callback ;
klass - > row_expanded = & row_expanded_callback ;
klass - > row_collapsed = & row_collapsed_callback ;
klass - > cursor_changed = & cursor_changed_callback ;
klass - > columns_changed = & columns_changed_callback ;
2007-11-12 18:44:49 -05:00
# endif //GLIBMM_DEFAULT_SIGNAL_HANDLERS_ENABLED
2005-05-13 16:47:18 -04:00
}
2007-11-12 18:44:49 -05:00
# ifdef GLIBMM_VFUNCS_ENABLED
# endif //GLIBMM_VFUNCS_ENABLED
2005-05-13 16:47:18 -04:00
2007-11-12 18:44:49 -05:00
# ifdef GLIBMM_DEFAULT_SIGNAL_HANDLERS_ENABLED
2005-05-13 16:47:18 -04:00
void TreeView_Class : : set_scroll_adjustments_callback ( GtkTreeView * self , GtkAdjustment * p0 , GtkAdjustment * p1 )
{
2007-12-18 01:05:55 -05:00
Glib : : ObjectBase * const obj_base = static_cast < Glib : : ObjectBase * > (
2005-05-13 16:47:18 -04:00
Glib : : ObjectBase : : _get_current_wrapper ( ( GObject * ) self ) ) ;
// Non-gtkmmproc-generated custom classes implicitly call the default
// Glib::ObjectBase constructor, which sets is_derived_. But gtkmmproc-
// generated classes can use this optimisation, which avoids the unnecessary
// parameter conversions if there is no possibility of the virtual function
// being overridden:
2007-12-18 01:05:55 -05:00
if ( obj_base & & obj_base - > is_derived_ ( ) )
2005-05-13 16:47:18 -04:00
{
2007-12-18 01:05:55 -05:00
CppObjectType * const obj = dynamic_cast < CppObjectType * const > ( obj_base ) ;
if ( obj ) // This can be NULL during destruction.
2005-05-13 16:47:18 -04:00
{
2007-12-18 01:05:55 -05:00
# ifdef GLIBMM_EXCEPTIONS_ENABLED
try // Trap C++ exceptions which would normally be lost because this is a C callback.
{
# endif //GLIBMM_EXCEPTIONS_ENABLED
// Call the virtual member method, which derived classes might override.
obj - > on_set_scroll_adjustments ( Glib : : wrap ( p0 )
2005-05-13 16:47:18 -04:00
, Glib : : wrap ( p1 )
) ;
2007-12-18 01:05:55 -05:00
return ;
# ifdef GLIBMM_EXCEPTIONS_ENABLED
}
catch ( . . . )
{
Glib : : exception_handlers_invoke ( ) ;
}
# endif //GLIBMM_EXCEPTIONS_ENABLED
2005-05-13 16:47:18 -04:00
}
}
2007-12-18 01:05:55 -05:00
BaseClassType * const base = static_cast < BaseClassType * > (
2005-05-13 16:47:18 -04:00
g_type_class_peek_parent ( G_OBJECT_GET_CLASS ( self ) ) // Get the parent class of the object class (The original underlying C class).
) ;
2007-12-18 01:05:55 -05:00
// Call the original underlying C function:
if ( base & & base - > set_scroll_adjustments )
( * base - > set_scroll_adjustments ) ( self , p0 , p1 ) ;
2005-05-13 16:47:18 -04:00
}
void TreeView_Class : : row_activated_callback ( GtkTreeView * self , GtkTreePath * p0 , GtkTreeViewColumn * p1 )
{
2007-12-18 01:05:55 -05:00
Glib : : ObjectBase * const obj_base = static_cast < Glib : : ObjectBase * > (
2005-05-13 16:47:18 -04:00
Glib : : ObjectBase : : _get_current_wrapper ( ( GObject * ) self ) ) ;
// Non-gtkmmproc-generated custom classes implicitly call the default
// Glib::ObjectBase constructor, which sets is_derived_. But gtkmmproc-
// generated classes can use this optimisation, which avoids the unnecessary
// parameter conversions if there is no possibility of the virtual function
// being overridden:
2007-12-18 01:05:55 -05:00
if ( obj_base & & obj_base - > is_derived_ ( ) )
2005-05-13 16:47:18 -04:00
{
2007-12-18 01:05:55 -05:00
CppObjectType * const obj = dynamic_cast < CppObjectType * const > ( obj_base ) ;
if ( obj ) // This can be NULL during destruction.
2005-05-13 16:47:18 -04:00
{
2007-12-18 01:05:55 -05:00
# ifdef GLIBMM_EXCEPTIONS_ENABLED
try // Trap C++ exceptions which would normally be lost because this is a C callback.
{
# endif //GLIBMM_EXCEPTIONS_ENABLED
// Call the virtual member method, which derived classes might override.
obj - > on_row_activated ( Gtk : : TreePath ( p0 , true )
2005-05-13 16:47:18 -04:00
, Glib : : wrap ( p1 )
) ;
2007-12-18 01:05:55 -05:00
return ;
# ifdef GLIBMM_EXCEPTIONS_ENABLED
}
catch ( . . . )
{
Glib : : exception_handlers_invoke ( ) ;
}
# endif //GLIBMM_EXCEPTIONS_ENABLED
2005-05-13 16:47:18 -04:00
}
}
2007-12-18 01:05:55 -05:00
BaseClassType * const base = static_cast < BaseClassType * > (
2005-05-13 16:47:18 -04:00
g_type_class_peek_parent ( G_OBJECT_GET_CLASS ( self ) ) // Get the parent class of the object class (The original underlying C class).
) ;
2007-12-18 01:05:55 -05:00
// Call the original underlying C function:
if ( base & & base - > row_activated )
( * base - > row_activated ) ( self , p0 , p1 ) ;
2005-05-13 16:47:18 -04:00
}
gboolean TreeView_Class : : test_expand_row_callback ( GtkTreeView * self , GtkTreeIter * p0 , GtkTreePath * p1 )
{
2007-12-18 01:05:55 -05:00
Glib : : ObjectBase * const obj_base = static_cast < Glib : : ObjectBase * > (
2005-05-13 16:47:18 -04:00
Glib : : ObjectBase : : _get_current_wrapper ( ( GObject * ) self ) ) ;
// Non-gtkmmproc-generated custom classes implicitly call the default
// Glib::ObjectBase constructor, which sets is_derived_. But gtkmmproc-
// generated classes can use this optimisation, which avoids the unnecessary
// parameter conversions if there is no possibility of the virtual function
// being overridden:
2007-12-18 01:05:55 -05:00
if ( obj_base & & obj_base - > is_derived_ ( ) )
2005-05-13 16:47:18 -04:00
{
2007-12-18 01:05:55 -05:00
CppObjectType * const obj = dynamic_cast < CppObjectType * const > ( obj_base ) ;
if ( obj ) // This can be NULL during destruction.
2005-05-13 16:47:18 -04:00
{
2007-12-18 01:05:55 -05:00
# ifdef GLIBMM_EXCEPTIONS_ENABLED
try // Trap C++ exceptions which would normally be lost because this is a C callback.
{
# endif //GLIBMM_EXCEPTIONS_ENABLED
// Call the virtual member method, which derived classes might override.
return static_cast < int > ( obj - > on_test_expand_row ( TreeModel : : iterator ( gtk_tree_view_get_model ( self ) , p0 )
2005-05-13 16:47:18 -04:00
, Gtk : : TreePath ( p1 , true )
) ) ;
2007-12-18 01:05:55 -05:00
# ifdef GLIBMM_EXCEPTIONS_ENABLED
}
catch ( . . . )
{
Glib : : exception_handlers_invoke ( ) ;
}
# endif //GLIBMM_EXCEPTIONS_ENABLED
2005-05-13 16:47:18 -04:00
}
}
2007-12-18 01:05:55 -05:00
BaseClassType * const base = static_cast < BaseClassType * > (
2005-05-13 16:47:18 -04:00
g_type_class_peek_parent ( G_OBJECT_GET_CLASS ( self ) ) // Get the parent class of the object class (The original underlying C class).
) ;
2007-12-18 01:05:55 -05:00
// Call the original underlying C function:
if ( base & & base - > test_expand_row )
return ( * base - > test_expand_row ) ( self , p0 , p1 ) ;
2005-05-13 16:47:18 -04:00
typedef gboolean RType ;
return RType ( ) ;
}
gboolean TreeView_Class : : test_collapse_row_callback ( GtkTreeView * self , GtkTreeIter * p0 , GtkTreePath * p1 )
{
2007-12-18 01:05:55 -05:00
Glib : : ObjectBase * const obj_base = static_cast < Glib : : ObjectBase * > (
2005-05-13 16:47:18 -04:00
Glib : : ObjectBase : : _get_current_wrapper ( ( GObject * ) self ) ) ;
// Non-gtkmmproc-generated custom classes implicitly call the default
// Glib::ObjectBase constructor, which sets is_derived_. But gtkmmproc-
// generated classes can use this optimisation, which avoids the unnecessary
// parameter conversions if there is no possibility of the virtual function
// being overridden:
2007-12-18 01:05:55 -05:00
if ( obj_base & & obj_base - > is_derived_ ( ) )
2005-05-13 16:47:18 -04:00
{
2007-12-18 01:05:55 -05:00
CppObjectType * const obj = dynamic_cast < CppObjectType * const > ( obj_base ) ;
if ( obj ) // This can be NULL during destruction.
2005-05-13 16:47:18 -04:00
{
2007-12-18 01:05:55 -05:00
# ifdef GLIBMM_EXCEPTIONS_ENABLED
try // Trap C++ exceptions which would normally be lost because this is a C callback.
{
# endif //GLIBMM_EXCEPTIONS_ENABLED
// Call the virtual member method, which derived classes might override.
return static_cast < int > ( obj - > on_test_collapse_row ( TreeModel : : iterator ( gtk_tree_view_get_model ( self ) , p0 )
2005-05-13 16:47:18 -04:00
, Gtk : : TreePath ( p1 , true )
) ) ;
2007-12-18 01:05:55 -05:00
# ifdef GLIBMM_EXCEPTIONS_ENABLED
}
catch ( . . . )
{
Glib : : exception_handlers_invoke ( ) ;
}
# endif //GLIBMM_EXCEPTIONS_ENABLED
2005-05-13 16:47:18 -04:00
}
}
2007-12-18 01:05:55 -05:00
BaseClassType * const base = static_cast < BaseClassType * > (
2005-05-13 16:47:18 -04:00
g_type_class_peek_parent ( G_OBJECT_GET_CLASS ( self ) ) // Get the parent class of the object class (The original underlying C class).
) ;
2007-12-18 01:05:55 -05:00
// Call the original underlying C function:
if ( base & & base - > test_collapse_row )
return ( * base - > test_collapse_row ) ( self , p0 , p1 ) ;
2005-05-13 16:47:18 -04:00
typedef gboolean RType ;
return RType ( ) ;
}
void TreeView_Class : : row_expanded_callback ( GtkTreeView * self , GtkTreeIter * p0 , GtkTreePath * p1 )
{
2007-12-18 01:05:55 -05:00
Glib : : ObjectBase * const obj_base = static_cast < Glib : : ObjectBase * > (
2005-05-13 16:47:18 -04:00
Glib : : ObjectBase : : _get_current_wrapper ( ( GObject * ) self ) ) ;
// Non-gtkmmproc-generated custom classes implicitly call the default
// Glib::ObjectBase constructor, which sets is_derived_. But gtkmmproc-
// generated classes can use this optimisation, which avoids the unnecessary
// parameter conversions if there is no possibility of the virtual function
// being overridden:
2007-12-18 01:05:55 -05:00
if ( obj_base & & obj_base - > is_derived_ ( ) )
2005-05-13 16:47:18 -04:00
{
2007-12-18 01:05:55 -05:00
CppObjectType * const obj = dynamic_cast < CppObjectType * const > ( obj_base ) ;
if ( obj ) // This can be NULL during destruction.
2005-05-13 16:47:18 -04:00
{
2007-12-18 01:05:55 -05:00
# ifdef GLIBMM_EXCEPTIONS_ENABLED
try // Trap C++ exceptions which would normally be lost because this is a C callback.
{
# endif //GLIBMM_EXCEPTIONS_ENABLED
// Call the virtual member method, which derived classes might override.
obj - > on_row_expanded ( TreeModel : : iterator ( gtk_tree_view_get_model ( self ) , p0 )
2005-05-13 16:47:18 -04:00
, Gtk : : TreePath ( p1 , true )
) ;
2007-12-18 01:05:55 -05:00
return ;
# ifdef GLIBMM_EXCEPTIONS_ENABLED
}
catch ( . . . )
{
Glib : : exception_handlers_invoke ( ) ;
}
# endif //GLIBMM_EXCEPTIONS_ENABLED
2005-05-13 16:47:18 -04:00
}
}
2007-12-18 01:05:55 -05:00
BaseClassType * const base = static_cast < BaseClassType * > (
2005-05-13 16:47:18 -04:00
g_type_class_peek_parent ( G_OBJECT_GET_CLASS ( self ) ) // Get the parent class of the object class (The original underlying C class).
) ;
2007-12-18 01:05:55 -05:00
// Call the original underlying C function:
if ( base & & base - > row_expanded )
( * base - > row_expanded ) ( self , p0 , p1 ) ;
2005-05-13 16:47:18 -04:00
}
void TreeView_Class : : row_collapsed_callback ( GtkTreeView * self , GtkTreeIter * p0 , GtkTreePath * p1 )
{
2007-12-18 01:05:55 -05:00
Glib : : ObjectBase * const obj_base = static_cast < Glib : : ObjectBase * > (
2005-05-13 16:47:18 -04:00
Glib : : ObjectBase : : _get_current_wrapper ( ( GObject * ) self ) ) ;
// Non-gtkmmproc-generated custom classes implicitly call the default
// Glib::ObjectBase constructor, which sets is_derived_. But gtkmmproc-
// generated classes can use this optimisation, which avoids the unnecessary
// parameter conversions if there is no possibility of the virtual function
// being overridden:
2007-12-18 01:05:55 -05:00
if ( obj_base & & obj_base - > is_derived_ ( ) )
2005-05-13 16:47:18 -04:00
{
2007-12-18 01:05:55 -05:00
CppObjectType * const obj = dynamic_cast < CppObjectType * const > ( obj_base ) ;
if ( obj ) // This can be NULL during destruction.
2005-05-13 16:47:18 -04:00
{
2007-12-18 01:05:55 -05:00
# ifdef GLIBMM_EXCEPTIONS_ENABLED
try // Trap C++ exceptions which would normally be lost because this is a C callback.
{
# endif //GLIBMM_EXCEPTIONS_ENABLED
// Call the virtual member method, which derived classes might override.
obj - > on_row_collapsed ( TreeModel : : iterator ( gtk_tree_view_get_model ( self ) , p0 )
2005-05-13 16:47:18 -04:00
, Gtk : : TreePath ( p1 , true )
) ;
2007-12-18 01:05:55 -05:00
return ;
# ifdef GLIBMM_EXCEPTIONS_ENABLED
}
catch ( . . . )
{
Glib : : exception_handlers_invoke ( ) ;
}
# endif //GLIBMM_EXCEPTIONS_ENABLED
2005-05-13 16:47:18 -04:00
}
}
2007-12-18 01:05:55 -05:00
BaseClassType * const base = static_cast < BaseClassType * > (
2005-05-13 16:47:18 -04:00
g_type_class_peek_parent ( G_OBJECT_GET_CLASS ( self ) ) // Get the parent class of the object class (The original underlying C class).
) ;
2007-12-18 01:05:55 -05:00
// Call the original underlying C function:
if ( base & & base - > row_collapsed )
( * base - > row_collapsed ) ( self , p0 , p1 ) ;
2005-05-13 16:47:18 -04:00
}
void TreeView_Class : : cursor_changed_callback ( GtkTreeView * self )
{
2007-12-18 01:05:55 -05:00
Glib : : ObjectBase * const obj_base = static_cast < Glib : : ObjectBase * > (
2005-05-13 16:47:18 -04:00
Glib : : ObjectBase : : _get_current_wrapper ( ( GObject * ) self ) ) ;
// Non-gtkmmproc-generated custom classes implicitly call the default
// Glib::ObjectBase constructor, which sets is_derived_. But gtkmmproc-
// generated classes can use this optimisation, which avoids the unnecessary
// parameter conversions if there is no possibility of the virtual function
// being overridden:
2007-12-18 01:05:55 -05:00
if ( obj_base & & obj_base - > is_derived_ ( ) )
2005-05-13 16:47:18 -04:00
{
2007-12-18 01:05:55 -05:00
CppObjectType * const obj = dynamic_cast < CppObjectType * const > ( obj_base ) ;
if ( obj ) // This can be NULL during destruction.
2005-05-13 16:47:18 -04:00
{
2007-12-18 01:05:55 -05:00
# ifdef GLIBMM_EXCEPTIONS_ENABLED
try // Trap C++ exceptions which would normally be lost because this is a C callback.
{
# endif //GLIBMM_EXCEPTIONS_ENABLED
// Call the virtual member method, which derived classes might override.
obj - > on_cursor_changed ( ) ;
return ;
# ifdef GLIBMM_EXCEPTIONS_ENABLED
}
catch ( . . . )
{
Glib : : exception_handlers_invoke ( ) ;
}
# endif //GLIBMM_EXCEPTIONS_ENABLED
2005-05-13 16:47:18 -04:00
}
}
2007-12-18 01:05:55 -05:00
BaseClassType * const base = static_cast < BaseClassType * > (
2005-05-13 16:47:18 -04:00
g_type_class_peek_parent ( G_OBJECT_GET_CLASS ( self ) ) // Get the parent class of the object class (The original underlying C class).
) ;
2007-12-18 01:05:55 -05:00
// Call the original underlying C function:
if ( base & & base - > cursor_changed )
( * base - > cursor_changed ) ( self ) ;
2005-05-13 16:47:18 -04:00
}
void TreeView_Class : : columns_changed_callback ( GtkTreeView * self )
{
2007-12-18 01:05:55 -05:00
Glib : : ObjectBase * const obj_base = static_cast < Glib : : ObjectBase * > (
2005-05-13 16:47:18 -04:00
Glib : : ObjectBase : : _get_current_wrapper ( ( GObject * ) self ) ) ;
// Non-gtkmmproc-generated custom classes implicitly call the default
// Glib::ObjectBase constructor, which sets is_derived_. But gtkmmproc-
// generated classes can use this optimisation, which avoids the unnecessary
// parameter conversions if there is no possibility of the virtual function
// being overridden:
2007-12-18 01:05:55 -05:00
if ( obj_base & & obj_base - > is_derived_ ( ) )
2005-05-13 16:47:18 -04:00
{
2007-12-18 01:05:55 -05:00
CppObjectType * const obj = dynamic_cast < CppObjectType * const > ( obj_base ) ;
if ( obj ) // This can be NULL during destruction.
2005-05-13 16:47:18 -04:00
{
2007-12-18 01:05:55 -05:00
# ifdef GLIBMM_EXCEPTIONS_ENABLED
try // Trap C++ exceptions which would normally be lost because this is a C callback.
{
# endif //GLIBMM_EXCEPTIONS_ENABLED
// Call the virtual member method, which derived classes might override.
obj - > on_columns_changed ( ) ;
return ;
# ifdef GLIBMM_EXCEPTIONS_ENABLED
}
catch ( . . . )
{
Glib : : exception_handlers_invoke ( ) ;
}
# endif //GLIBMM_EXCEPTIONS_ENABLED
2005-05-13 16:47:18 -04:00
}
}
2007-12-18 01:05:55 -05:00
BaseClassType * const base = static_cast < BaseClassType * > (
2005-05-13 16:47:18 -04:00
g_type_class_peek_parent ( G_OBJECT_GET_CLASS ( self ) ) // Get the parent class of the object class (The original underlying C class).
) ;
2007-12-18 01:05:55 -05:00
// Call the original underlying C function:
if ( base & & base - > columns_changed )
( * base - > columns_changed ) ( self ) ;
2005-05-13 16:47:18 -04:00
}
2007-11-12 18:44:49 -05:00
# endif //GLIBMM_DEFAULT_SIGNAL_HANDLERS_ENABLED
2005-05-13 16:47:18 -04:00
Glib : : ObjectBase * TreeView_Class : : wrap_new ( GObject * o )
{
return manage ( new TreeView ( ( GtkTreeView * ) ( o ) ) ) ;
}
/* The implementation: */
TreeView : : TreeView ( const Glib : : ConstructParams & construct_params )
:
Gtk : : Container ( construct_params )
{
}
TreeView : : TreeView ( GtkTreeView * castitem )
:
Gtk : : Container ( ( GtkContainer * ) ( castitem ) )
{
}
TreeView : : ~ TreeView ( )
{
destroy_ ( ) ;
}
TreeView : : CppClassType TreeView : : treeview_class_ ; // initialize static member
GType TreeView : : get_type ( )
{
return treeview_class_ . init ( ) . get_type ( ) ;
}
GType TreeView : : get_base_type ( )
{
return gtk_tree_view_get_type ( ) ;
}
TreeView : : TreeView ( )
:
2007-12-18 01:05:55 -05:00
// Mark this class as non-derived to allow C++ vfuncs to be skipped.
Glib : : ObjectBase ( 0 ) ,
2005-05-13 16:47:18 -04:00
Gtk : : Container ( Glib : : ConstructParams ( treeview_class_ . init ( ) ) )
{
}
TreeView : : TreeView ( const Glib : : RefPtr < TreeModel > & model )
:
2007-12-18 01:05:55 -05:00
// Mark this class as non-derived to allow C++ vfuncs to be skipped.
Glib : : ObjectBase ( 0 ) ,
Gtk : : Container ( Glib : : ConstructParams ( treeview_class_ . init ( ) , " model " , Glib : : unwrap ( model ) , static_cast < char * > ( 0 ) ) )
2005-05-13 16:47:18 -04:00
{
}
Glib : : RefPtr < TreeModel > TreeView : : get_model ( )
{
Glib : : RefPtr < TreeModel > retvalue = Glib : : wrap ( gtk_tree_view_get_model ( gobj ( ) ) ) ;
if ( retvalue )
retvalue - > reference ( ) ; //The function does not do a ref for us.
return retvalue ;
2007-11-12 18:44:49 -05:00
2005-05-13 16:47:18 -04:00
}
Glib : : RefPtr < const TreeModel > TreeView : : get_model ( ) const
{
Glib : : RefPtr < const TreeModel > retvalue = Glib : : wrap ( gtk_tree_view_get_model ( const_cast < GtkTreeView * > ( gobj ( ) ) ) ) ;
if ( retvalue )
retvalue - > reference ( ) ; //The function does not do a ref for us.
return retvalue ;
2007-11-12 18:44:49 -05:00
2005-05-13 16:47:18 -04:00
}
void TreeView : : set_model ( const Glib : : RefPtr < TreeModel > & model )
{
2007-11-12 18:44:49 -05:00
gtk_tree_view_set_model ( gobj ( ) , Glib : : unwrap ( model ) ) ;
2005-05-13 16:47:18 -04:00
}
Glib : : RefPtr < TreeSelection > TreeView : : get_selection ( )
{
Glib : : RefPtr < TreeSelection > retvalue = Glib : : wrap ( gtk_tree_view_get_selection ( gobj ( ) ) ) ;
if ( retvalue )
retvalue - > reference ( ) ; //The function does not do a ref for us.
return retvalue ;
2007-11-12 18:44:49 -05:00
2005-05-13 16:47:18 -04:00
}
Glib : : RefPtr < const TreeSelection > TreeView : : get_selection ( ) const
{
2007-11-12 18:44:49 -05:00
return const_cast < TreeView * > ( this ) - > get_selection ( ) ;
2005-05-13 16:47:18 -04:00
}
Adjustment * TreeView : : get_hadjustment ( )
{
return Glib : : wrap ( gtk_tree_view_get_hadjustment ( gobj ( ) ) ) ;
}
const Adjustment * TreeView : : get_hadjustment ( ) const
{
2007-11-12 18:44:49 -05:00
return const_cast < TreeView * > ( this ) - > get_hadjustment ( ) ;
2005-05-13 16:47:18 -04:00
}
void TreeView : : set_hadjustment ( Adjustment & adjustment )
{
2007-11-12 18:44:49 -05:00
gtk_tree_view_set_hadjustment ( gobj ( ) , ( adjustment ) . gobj ( ) ) ;
2005-05-13 16:47:18 -04:00
}
Adjustment * TreeView : : get_vadjustment ( )
{
return Glib : : wrap ( gtk_tree_view_get_vadjustment ( gobj ( ) ) ) ;
}
const Adjustment * TreeView : : get_vadjustment ( ) const
{
2007-11-12 18:44:49 -05:00
return const_cast < TreeView * > ( this ) - > get_vadjustment ( ) ;
2005-05-13 16:47:18 -04:00
}
void TreeView : : set_vadjustment ( Adjustment & adjustment )
{
2007-11-12 18:44:49 -05:00
gtk_tree_view_set_vadjustment ( gobj ( ) , ( adjustment ) . gobj ( ) ) ;
2005-05-13 16:47:18 -04:00
}
bool TreeView : : get_headers_visible ( ) const
{
return gtk_tree_view_get_headers_visible ( const_cast < GtkTreeView * > ( gobj ( ) ) ) ;
}
void TreeView : : set_headers_visible ( bool headers_visible )
{
2007-11-12 18:44:49 -05:00
gtk_tree_view_set_headers_visible ( gobj ( ) , static_cast < int > ( headers_visible ) ) ;
2005-05-13 16:47:18 -04:00
}
void TreeView : : columns_autosize ( )
{
2007-11-12 18:44:49 -05:00
gtk_tree_view_columns_autosize ( gobj ( ) ) ;
}
bool TreeView : : get_headers_clickable ( ) const
{
return gtk_tree_view_get_headers_clickable ( const_cast < GtkTreeView * > ( gobj ( ) ) ) ;
2005-05-13 16:47:18 -04:00
}
void TreeView : : set_headers_clickable ( bool setting )
{
2007-11-12 18:44:49 -05:00
gtk_tree_view_set_headers_clickable ( gobj ( ) , static_cast < int > ( setting ) ) ;
2005-05-13 16:47:18 -04:00
}
void TreeView : : set_rules_hint ( bool setting )
{
2007-11-12 18:44:49 -05:00
gtk_tree_view_set_rules_hint ( gobj ( ) , static_cast < int > ( setting ) ) ;
2005-05-13 16:47:18 -04:00
}
bool TreeView : : get_rules_hint ( ) const
{
return gtk_tree_view_get_rules_hint ( const_cast < GtkTreeView * > ( gobj ( ) ) ) ;
}
int TreeView : : append_column ( TreeViewColumn & column )
{
return gtk_tree_view_append_column ( gobj ( ) , ( column ) . gobj ( ) ) ;
}
int TreeView : : remove_column ( TreeViewColumn & column )
{
return gtk_tree_view_remove_column ( gobj ( ) , ( column ) . gobj ( ) ) ;
}
int TreeView : : insert_column ( TreeViewColumn & column , int position )
{
return gtk_tree_view_insert_column ( gobj ( ) , ( column ) . gobj ( ) , position ) ;
}
TreeViewColumn * TreeView : : get_column ( int n )
{
return Glib : : wrap ( gtk_tree_view_get_column ( gobj ( ) , n ) ) ;
}
const TreeViewColumn * TreeView : : get_column ( int n ) const
{
2007-11-12 18:44:49 -05:00
return const_cast < TreeView * > ( this ) - > get_column ( n ) ;
2005-05-13 16:47:18 -04:00
}
Glib : : ListHandle < TreeViewColumn * > TreeView : : get_columns ( )
{
return Glib : : ListHandle < TreeViewColumn * > ( gtk_tree_view_get_columns ( gobj ( ) ) , Glib : : OWNERSHIP_SHALLOW ) ;
}
Glib : : ListHandle < const TreeViewColumn * > TreeView : : get_columns ( ) const
{
return Glib : : ListHandle < const TreeViewColumn * > ( gtk_tree_view_get_columns ( const_cast < GtkTreeView * > ( gobj ( ) ) ) , Glib : : OWNERSHIP_SHALLOW ) ;
}
void TreeView : : move_column_after ( TreeViewColumn & column , TreeViewColumn & base_column )
{
2007-11-12 18:44:49 -05:00
gtk_tree_view_move_column_after ( gobj ( ) , ( column ) . gobj ( ) , ( base_column ) . gobj ( ) ) ;
2005-05-13 16:47:18 -04:00
}
void TreeView : : set_expander_column ( TreeViewColumn & column )
{
2007-11-12 18:44:49 -05:00
gtk_tree_view_set_expander_column ( gobj ( ) , ( column ) . gobj ( ) ) ;
2005-05-13 16:47:18 -04:00
}
TreeViewColumn * TreeView : : get_expander_column ( )
{
return Glib : : wrap ( gtk_tree_view_get_expander_column ( gobj ( ) ) ) ;
}
const TreeViewColumn * TreeView : : get_expander_column ( ) const
{
2007-11-12 18:44:49 -05:00
return const_cast < TreeView * > ( this ) - > get_expander_column ( ) ;
2005-05-13 16:47:18 -04:00
}
void TreeView : : scroll_to_point ( int tree_x , int tree_y )
{
2007-11-12 18:44:49 -05:00
gtk_tree_view_scroll_to_point ( gobj ( ) , tree_x , tree_y ) ;
2005-05-13 16:47:18 -04:00
}
void TreeView : : row_activated ( const TreeModel : : Path & path , TreeViewColumn & column )
{
2007-11-12 18:44:49 -05:00
gtk_tree_view_row_activated ( gobj ( ) , const_cast < GtkTreePath * > ( ( path ) . gobj ( ) ) , ( column ) . gobj ( ) ) ;
2005-05-13 16:47:18 -04:00
}
void TreeView : : expand_all ( )
{
2007-11-12 18:44:49 -05:00
gtk_tree_view_expand_all ( gobj ( ) ) ;
2005-05-13 16:47:18 -04:00
}
void TreeView : : collapse_all ( )
{
2007-11-12 18:44:49 -05:00
gtk_tree_view_collapse_all ( gobj ( ) ) ;
2005-05-13 16:47:18 -04:00
}
void TreeView : : expand_to_path ( const TreeModel : : Path & path )
{
2007-11-12 18:44:49 -05:00
gtk_tree_view_expand_to_path ( gobj ( ) , const_cast < GtkTreePath * > ( ( path ) . gobj ( ) ) ) ;
2005-05-13 16:47:18 -04:00
}
bool TreeView : : expand_row ( const TreeModel : : Path & path , bool open_all )
{
return gtk_tree_view_expand_row ( gobj ( ) , const_cast < GtkTreePath * > ( ( path ) . gobj ( ) ) , static_cast < int > ( open_all ) ) ;
}
bool TreeView : : collapse_row ( const TreeModel : : Path & path )
{
return gtk_tree_view_collapse_row ( gobj ( ) , const_cast < GtkTreePath * > ( ( path ) . gobj ( ) ) ) ;
}
bool TreeView : : row_expanded ( const TreeModel : : Path & path )
{
return gtk_tree_view_row_expanded ( gobj ( ) , const_cast < GtkTreePath * > ( ( path ) . gobj ( ) ) ) ;
}
void TreeView : : set_reorderable ( bool reorderable )
{
2007-11-12 18:44:49 -05:00
gtk_tree_view_set_reorderable ( gobj ( ) , static_cast < int > ( reorderable ) ) ;
2005-05-13 16:47:18 -04:00
}
bool TreeView : : get_reorderable ( ) const
{
return gtk_tree_view_get_reorderable ( const_cast < GtkTreeView * > ( gobj ( ) ) ) ;
}
void TreeView : : set_cursor ( const TreeModel : : Path & path , TreeViewColumn & focus_column , bool start_editing )
{
2007-11-12 18:44:49 -05:00
gtk_tree_view_set_cursor ( gobj ( ) , const_cast < GtkTreePath * > ( ( path ) . gobj ( ) ) , ( focus_column ) . gobj ( ) , static_cast < int > ( start_editing ) ) ;
2005-05-13 16:47:18 -04:00
}
void TreeView : : set_cursor ( const TreeModel : : Path & path , TreeViewColumn & focus_column , CellRenderer & focus_cell , bool start_editing )
{
2007-11-12 18:44:49 -05:00
gtk_tree_view_set_cursor_on_cell ( gobj ( ) , const_cast < GtkTreePath * > ( ( path ) . gobj ( ) ) , ( focus_column ) . gobj ( ) , ( focus_cell ) . gobj ( ) , static_cast < int > ( start_editing ) ) ;
2005-05-13 16:47:18 -04:00
}
Glib : : RefPtr < Gdk : : Window > TreeView : : get_bin_window ( )
{
Glib : : RefPtr < Gdk : : Window > retvalue = Glib : : wrap ( ( GdkWindowObject * ) ( gtk_tree_view_get_bin_window ( gobj ( ) ) ) ) ;
if ( retvalue )
retvalue - > reference ( ) ; //The function does not do a ref for us.
return retvalue ;
2007-11-12 18:44:49 -05:00
2005-05-13 16:47:18 -04:00
}
Glib : : RefPtr < const Gdk : : Window > TreeView : : get_bin_window ( ) const
{
2007-11-12 18:44:49 -05:00
return const_cast < TreeView * > ( this ) - > get_bin_window ( ) ;
}
2005-05-13 16:47:18 -04:00
2007-11-12 18:44:49 -05:00
# ifndef GTKMM_DISABLE_DEPRECATED
2005-05-13 16:47:18 -04:00
2007-11-12 18:44:49 -05:00
void TreeView : : get_cell_area ( const TreeModel : : Path & path , TreeViewColumn & column , Gdk : : Rectangle & rect )
{
gtk_tree_view_get_cell_area ( gobj ( ) , const_cast < GtkTreePath * > ( ( path ) . gobj ( ) ) , ( column ) . gobj ( ) , ( rect ) . gobj ( ) ) ;
2005-05-13 16:47:18 -04:00
}
2007-11-12 18:44:49 -05:00
# endif // GTKMM_DISABLE_DEPRECATED
void TreeView : : get_cell_area ( const TreeModel : : Path & path , TreeViewColumn & column , Gdk : : Rectangle & rect ) const
2005-05-13 16:47:18 -04:00
{
2007-11-12 18:44:49 -05:00
gtk_tree_view_get_cell_area ( const_cast < GtkTreeView * > ( gobj ( ) ) , const_cast < GtkTreePath * > ( ( path ) . gobj ( ) ) , ( column ) . gobj ( ) , ( rect ) . gobj ( ) ) ;
2005-05-13 16:47:18 -04:00
}
2007-11-12 18:44:49 -05:00
# ifndef GTKMM_DISABLE_DEPRECATED
2005-05-13 16:47:18 -04:00
void TreeView : : get_background_area ( const TreeModel : : Path & path , TreeViewColumn & column , Gdk : : Rectangle & rect )
{
2007-11-12 18:44:49 -05:00
gtk_tree_view_get_background_area ( gobj ( ) , const_cast < GtkTreePath * > ( ( path ) . gobj ( ) ) , ( column ) . gobj ( ) , ( rect ) . gobj ( ) ) ;
2005-05-13 16:47:18 -04:00
}
2007-11-12 18:44:49 -05:00
# endif // GTKMM_DISABLE_DEPRECATED
void TreeView : : get_background_area ( const TreeModel : : Path & path , TreeViewColumn & column , Gdk : : Rectangle & rect ) const
{
gtk_tree_view_get_background_area ( const_cast < GtkTreeView * > ( gobj ( ) ) , const_cast < GtkTreePath * > ( ( path ) . gobj ( ) ) , ( column ) . gobj ( ) , ( rect ) . gobj ( ) ) ;
}
# ifndef GTKMM_DISABLE_DEPRECATED
2005-05-13 16:47:18 -04:00
void TreeView : : get_visible_rect ( Gdk : : Rectangle & visible_rect )
{
2007-11-12 18:44:49 -05:00
gtk_tree_view_get_visible_rect ( gobj ( ) , ( visible_rect ) . gobj ( ) ) ;
2005-05-13 16:47:18 -04:00
}
2007-11-12 18:44:49 -05:00
# endif // GTKMM_DISABLE_DEPRECATED
void TreeView : : get_visible_rect ( Gdk : : Rectangle & visible_rect ) const
{
gtk_tree_view_get_visible_rect ( const_cast < GtkTreeView * > ( gobj ( ) ) , ( visible_rect ) . gobj ( ) ) ;
}
# ifndef GTKMM_DISABLE_DEPRECATED
2005-05-13 16:47:18 -04:00
void TreeView : : widget_to_tree_coords ( int wx , int wy , int & tx , int & ty )
{
2007-11-12 18:44:49 -05:00
gtk_tree_view_widget_to_tree_coords ( gobj ( ) , wx , wy , & tx , & ty ) ;
2005-05-13 16:47:18 -04:00
}
2007-11-12 18:44:49 -05:00
# endif // GTKMM_DISABLE_DEPRECATED
void TreeView : : widget_to_tree_coords ( int wx , int wy , int & tx , int & ty ) const
{
gtk_tree_view_widget_to_tree_coords ( const_cast < GtkTreeView * > ( gobj ( ) ) , wx , wy , & tx , & ty ) ;
}
# ifndef GTKMM_DISABLE_DEPRECATED
2005-05-13 16:47:18 -04:00
void TreeView : : tree_to_widget_coords ( int tx , int ty , int & wx , int & wy )
{
2007-11-12 18:44:49 -05:00
gtk_tree_view_tree_to_widget_coords ( gobj ( ) , tx , ty , & wx , & wy ) ;
}
# endif // GTKMM_DISABLE_DEPRECATED
void TreeView : : tree_to_widget_coords ( int tx , int ty , int & wx , int & wy ) const
{
gtk_tree_view_tree_to_widget_coords ( const_cast < GtkTreeView * > ( gobj ( ) ) , tx , ty , & wx , & wy ) ;
2005-05-13 16:47:18 -04:00
}
void TreeView : : unset_rows_drag_source ( )
{
2007-11-12 18:44:49 -05:00
gtk_tree_view_unset_rows_drag_source ( gobj ( ) ) ;
2005-05-13 16:47:18 -04:00
}
void TreeView : : unset_rows_drag_dest ( )
{
2007-11-12 18:44:49 -05:00
gtk_tree_view_unset_rows_drag_dest ( gobj ( ) ) ;
2005-05-13 16:47:18 -04:00
}
void TreeView : : set_drag_dest_row ( const TreeModel : : Path & path , TreeViewDropPosition pos )
{
2007-11-12 18:44:49 -05:00
gtk_tree_view_set_drag_dest_row ( gobj ( ) , const_cast < GtkTreePath * > ( ( path ) . gobj ( ) ) , ( ( GtkTreeViewDropPosition ) ( pos ) ) ) ;
2005-05-13 16:47:18 -04:00
}
Glib : : RefPtr < Gdk : : Pixmap > TreeView : : create_row_drag_icon ( const TreeModel : : Path & path )
{
return Glib : : wrap ( ( GdkPixmapObject * ) ( gtk_tree_view_create_row_drag_icon ( gobj ( ) , const_cast < GtkTreePath * > ( ( path ) . gobj ( ) ) ) ) ) ;
}
void TreeView : : set_enable_search ( bool enable_search )
{
2007-11-12 18:44:49 -05:00
gtk_tree_view_set_enable_search ( gobj ( ) , static_cast < int > ( enable_search ) ) ;
2005-05-13 16:47:18 -04:00
}
bool TreeView : : get_enable_search ( ) const
{
return gtk_tree_view_get_enable_search ( const_cast < GtkTreeView * > ( gobj ( ) ) ) ;
}
int TreeView : : get_search_column ( ) const
{
return gtk_tree_view_get_search_column ( const_cast < GtkTreeView * > ( gobj ( ) ) ) ;
}
void TreeView : : set_search_column ( const TreeModelColumnBase & column )
{
2007-11-12 18:44:49 -05:00
gtk_tree_view_set_search_column ( gobj ( ) , ( column ) . index ( ) ) ;
2005-05-13 16:47:18 -04:00
}
void TreeView : : set_search_column ( int column )
{
2007-11-12 18:44:49 -05:00
gtk_tree_view_set_search_column ( gobj ( ) , column ) ;
}
Entry * TreeView : : get_search_entry ( )
{
return Glib : : wrap ( gtk_tree_view_get_search_entry ( gobj ( ) ) ) ;
}
const Entry * TreeView : : get_search_entry ( ) const
{
return const_cast < TreeView * > ( this ) - > get_search_entry ( ) ;
}
void TreeView : : set_search_entry ( Entry & entry )
{
gtk_tree_view_set_search_entry ( gobj ( ) , ( entry ) . gobj ( ) ) ;
2005-05-13 16:47:18 -04:00
}
2007-12-18 01:05:55 -05:00
void TreeView : : convert_widget_to_tree_coords ( int wx , int wy , int & tx , int & ty ) const
{
gtk_tree_view_convert_widget_to_tree_coords ( const_cast < GtkTreeView * > ( gobj ( ) ) , wx , wy , & tx , & ty ) ;
}
void TreeView : : convert_tree_to_widget_coords ( int tx , int ty , int & wx , int & wy ) const
{
gtk_tree_view_convert_tree_to_widget_coords ( const_cast < GtkTreeView * > ( gobj ( ) ) , tx , ty , & wx , & wy ) ;
}
void TreeView : : convert_widget_to_bin_window_coords ( int wx , int wy , int & bx , int & by ) const
{
gtk_tree_view_convert_widget_to_bin_window_coords ( const_cast < GtkTreeView * > ( gobj ( ) ) , wx , wy , & bx , & by ) ;
}
void TreeView : : convert_bin_window_to_widget_coords ( int bx , int by , int & wx , int & wy ) const
{
gtk_tree_view_convert_bin_window_to_widget_coords ( const_cast < GtkTreeView * > ( gobj ( ) ) , bx , by , & wx , & wy ) ;
}
void TreeView : : convert_tree_to_bin_window_coords ( int tx , int ty , int & bx , int & by ) const
{
gtk_tree_view_convert_tree_to_bin_window_coords ( const_cast < GtkTreeView * > ( gobj ( ) ) , tx , ty , & bx , & by ) ;
}
void TreeView : : convert_bin_window_to_tree_coords ( int bx , int by , int & tx , int & ty ) const
{
gtk_tree_view_convert_bin_window_to_tree_coords ( const_cast < GtkTreeView * > ( gobj ( ) ) , bx , by , & tx , & ty ) ;
}
2005-05-13 16:47:18 -04:00
void TreeView : : set_fixed_height_mode ( bool enable )
{
2007-11-12 18:44:49 -05:00
gtk_tree_view_set_fixed_height_mode ( gobj ( ) , static_cast < int > ( enable ) ) ;
2005-05-13 16:47:18 -04:00
}
bool TreeView : : get_fixed_height_mode ( ) const
{
return gtk_tree_view_get_fixed_height_mode ( const_cast < GtkTreeView * > ( gobj ( ) ) ) ;
}
void TreeView : : set_hover_selection ( bool hover )
{
2007-11-12 18:44:49 -05:00
gtk_tree_view_set_hover_selection ( gobj ( ) , static_cast < int > ( hover ) ) ;
2005-05-13 16:47:18 -04:00
}
bool TreeView : : get_hover_selection ( ) const
{
return gtk_tree_view_get_hover_selection ( const_cast < GtkTreeView * > ( gobj ( ) ) ) ;
}
void TreeView : : set_hover_expand ( bool expand )
{
2007-11-12 18:44:49 -05:00
gtk_tree_view_set_hover_expand ( gobj ( ) , static_cast < int > ( expand ) ) ;
2005-05-13 16:47:18 -04:00
}
bool TreeView : : get_hover_expand ( ) const
{
return gtk_tree_view_get_hover_expand ( const_cast < GtkTreeView * > ( gobj ( ) ) ) ;
}
2007-11-12 18:44:49 -05:00
void TreeView : : set_rubber_banding ( bool enable )
{
gtk_tree_view_set_rubber_banding ( gobj ( ) , static_cast < int > ( enable ) ) ;
}
bool TreeView : : get_rubber_banding ( ) const
{
return gtk_tree_view_get_rubber_banding ( const_cast < GtkTreeView * > ( gobj ( ) ) ) ;
}
2007-12-18 01:05:55 -05:00
bool TreeView : : is_rubber_banding_active ( ) const
{
return gtk_tree_view_is_rubber_banding_active ( const_cast < GtkTreeView * > ( gobj ( ) ) ) ;
}
2007-11-12 18:44:49 -05:00
void TreeView : : set_grid_lines ( TreeViewGridLines grid_lines )
{
gtk_tree_view_set_grid_lines ( gobj ( ) , ( ( GtkTreeViewGridLines ) ( grid_lines ) ) ) ;
}
TreeViewGridLines TreeView : : get_grid_lines ( ) const
{
return ( ( TreeViewGridLines ) ( gtk_tree_view_get_grid_lines ( const_cast < GtkTreeView * > ( gobj ( ) ) ) ) ) ;
}
void TreeView : : set_enable_tree_lines ( bool enable )
{
gtk_tree_view_set_enable_tree_lines ( gobj ( ) , static_cast < int > ( enable ) ) ;
}
bool TreeView : : get_enable_tree_lines ( ) const
{
return gtk_tree_view_get_enable_tree_lines ( const_cast < GtkTreeView * > ( gobj ( ) ) ) ;
}
2007-12-18 01:05:55 -05:00
void TreeView : : set_show_expanders ( bool enabled )
{
gtk_tree_view_set_show_expanders ( gobj ( ) , static_cast < int > ( enabled ) ) ;
}
bool TreeView : : get_show_expanders ( ) const
{
return gtk_tree_view_get_show_expanders ( const_cast < GtkTreeView * > ( gobj ( ) ) ) ;
}
void TreeView : : set_level_indentation ( int indentation )
{
gtk_tree_view_set_level_indentation ( gobj ( ) , indentation ) ;
}
int TreeView : : get_level_indentation ( ) const
{
return gtk_tree_view_get_level_indentation ( const_cast < GtkTreeView * > ( gobj ( ) ) ) ;
}
void TreeView : : set_tooltip_row ( const Glib : : RefPtr < Tooltip > & tooltip , const TreePath & path )
{
gtk_tree_view_set_tooltip_row ( gobj ( ) , Glib : : unwrap ( tooltip ) , const_cast < GtkTreePath * > ( ( path ) . gobj ( ) ) ) ;
}
void TreeView : : set_tooltip_cell ( const Glib : : RefPtr < Tooltip > & tooltip , const TreeModel : : Path * path , TreeViewColumn * column , CellRenderer * cell )
{
gtk_tree_view_set_tooltip_cell ( gobj ( ) , Glib : : unwrap ( tooltip ) , ( ( path ) ? const_cast < GtkTreePath * > ( ( path ) - > gobj ( ) ) : 0 ) , ( GtkTreeViewColumn * ) Glib : : unwrap ( column ) , ( GtkCellRenderer * ) Glib : : unwrap ( cell ) ) ;
}
void TreeView : : set_tooltip_column ( int column )
{
gtk_tree_view_set_tooltip_column ( gobj ( ) , column ) ;
}
int TreeView : : get_tooltip_column ( ) const
{
return gtk_tree_view_get_tooltip_column ( const_cast < GtkTreeView * > ( gobj ( ) ) ) ;
}
2005-05-13 16:47:18 -04:00
Glib : : SignalProxy2 < void , Adjustment * , Adjustment * > TreeView : : signal_set_scroll_adjustments ( )
{
return Glib : : SignalProxy2 < void , Adjustment * , Adjustment * > ( this , & TreeView_signal_set_scroll_adjustments_info ) ;
}
2007-11-12 18:44:49 -05:00
2005-05-13 16:47:18 -04:00
Glib : : SignalProxy2 < void , const TreeModel : : Path & , TreeViewColumn * > TreeView : : signal_row_activated ( )
{
return Glib : : SignalProxy2 < void , const TreeModel : : Path & , TreeViewColumn * > ( this , & TreeView_signal_row_activated_info ) ;
}
2007-11-12 18:44:49 -05:00
2005-05-13 16:47:18 -04:00
Glib : : SignalProxy2 < bool , const TreeModel : : iterator & , const TreeModel : : Path & > TreeView : : signal_test_expand_row ( )
{
return Glib : : SignalProxy2 < bool , const TreeModel : : iterator & , const TreeModel : : Path & > ( this , & TreeView_signal_test_expand_row_info ) ;
}
2007-11-12 18:44:49 -05:00
2005-05-13 16:47:18 -04:00
Glib : : SignalProxy2 < bool , const TreeModel : : iterator & , const TreeModel : : Path & > TreeView : : signal_test_collapse_row ( )
{
return Glib : : SignalProxy2 < bool , const TreeModel : : iterator & , const TreeModel : : Path & > ( this , & TreeView_signal_test_collapse_row_info ) ;
}
2007-11-12 18:44:49 -05:00
2005-05-13 16:47:18 -04:00
Glib : : SignalProxy2 < void , const TreeModel : : iterator & , const TreeModel : : Path & > TreeView : : signal_row_expanded ( )
{
return Glib : : SignalProxy2 < void , const TreeModel : : iterator & , const TreeModel : : Path & > ( this , & TreeView_signal_row_expanded_info ) ;
}
2007-11-12 18:44:49 -05:00
2005-05-13 16:47:18 -04:00
Glib : : SignalProxy2 < void , const TreeModel : : iterator & , const TreeModel : : Path & > TreeView : : signal_row_collapsed ( )
{
return Glib : : SignalProxy2 < void , const TreeModel : : iterator & , const TreeModel : : Path & > ( this , & TreeView_signal_row_collapsed_info ) ;
}
2007-11-12 18:44:49 -05:00
2005-05-13 16:47:18 -04:00
Glib : : SignalProxy0 < void > TreeView : : signal_cursor_changed ( )
{
return Glib : : SignalProxy0 < void > ( this , & TreeView_signal_cursor_changed_info ) ;
}
2007-11-12 18:44:49 -05:00
2005-05-13 16:47:18 -04:00
Glib : : SignalProxy0 < void > TreeView : : signal_columns_changed ( )
{
return Glib : : SignalProxy0 < void > ( this , & TreeView_signal_columns_changed_info ) ;
}
2007-11-12 18:44:49 -05:00
# ifdef GLIBMM_PROPERTIES_ENABLED
2005-05-13 16:47:18 -04:00
Glib : : PropertyProxy < Glib : : RefPtr < TreeModel > > TreeView : : property_model ( )
{
return Glib : : PropertyProxy < Glib : : RefPtr < TreeModel > > ( this , " model " ) ;
}
2007-11-12 18:44:49 -05:00
# endif //GLIBMM_PROPERTIES_ENABLED
2005-05-13 16:47:18 -04:00
2007-11-12 18:44:49 -05:00
# ifdef GLIBMM_PROPERTIES_ENABLED
2005-05-13 16:47:18 -04:00
Glib : : PropertyProxy_ReadOnly < Glib : : RefPtr < TreeModel > > TreeView : : property_model ( ) const
{
return Glib : : PropertyProxy_ReadOnly < Glib : : RefPtr < TreeModel > > ( this , " model " ) ;
}
2007-11-12 18:44:49 -05:00
# endif //GLIBMM_PROPERTIES_ENABLED
2005-05-13 16:47:18 -04:00
2007-11-12 18:44:49 -05:00
# ifdef GLIBMM_PROPERTIES_ENABLED
2005-05-13 16:47:18 -04:00
Glib : : PropertyProxy < Adjustment * > TreeView : : property_hadjustment ( )
{
return Glib : : PropertyProxy < Adjustment * > ( this , " hadjustment " ) ;
}
2007-11-12 18:44:49 -05:00
# endif //GLIBMM_PROPERTIES_ENABLED
2005-05-13 16:47:18 -04:00
2007-11-12 18:44:49 -05:00
# ifdef GLIBMM_PROPERTIES_ENABLED
2005-05-13 16:47:18 -04:00
Glib : : PropertyProxy_ReadOnly < Adjustment * > TreeView : : property_hadjustment ( ) const
{
return Glib : : PropertyProxy_ReadOnly < Adjustment * > ( this , " hadjustment " ) ;
}
2007-11-12 18:44:49 -05:00
# endif //GLIBMM_PROPERTIES_ENABLED
2005-05-13 16:47:18 -04:00
2007-11-12 18:44:49 -05:00
# ifdef GLIBMM_PROPERTIES_ENABLED
2005-05-13 16:47:18 -04:00
Glib : : PropertyProxy < Adjustment * > TreeView : : property_vadjustment ( )
{
return Glib : : PropertyProxy < Adjustment * > ( this , " vadjustment " ) ;
}
2007-11-12 18:44:49 -05:00
# endif //GLIBMM_PROPERTIES_ENABLED
2005-05-13 16:47:18 -04:00
2007-11-12 18:44:49 -05:00
# ifdef GLIBMM_PROPERTIES_ENABLED
2005-05-13 16:47:18 -04:00
Glib : : PropertyProxy_ReadOnly < Adjustment * > TreeView : : property_vadjustment ( ) const
{
return Glib : : PropertyProxy_ReadOnly < Adjustment * > ( this , " vadjustment " ) ;
}
2007-11-12 18:44:49 -05:00
# endif //GLIBMM_PROPERTIES_ENABLED
2005-05-13 16:47:18 -04:00
2007-11-12 18:44:49 -05:00
# ifdef GLIBMM_PROPERTIES_ENABLED
2005-05-13 16:47:18 -04:00
Glib : : PropertyProxy < bool > TreeView : : property_headers_visible ( )
{
return Glib : : PropertyProxy < bool > ( this , " headers-visible " ) ;
}
2007-11-12 18:44:49 -05:00
# endif //GLIBMM_PROPERTIES_ENABLED
2005-05-13 16:47:18 -04:00
2007-11-12 18:44:49 -05:00
# ifdef GLIBMM_PROPERTIES_ENABLED
2005-05-13 16:47:18 -04:00
Glib : : PropertyProxy_ReadOnly < bool > TreeView : : property_headers_visible ( ) const
{
return Glib : : PropertyProxy_ReadOnly < bool > ( this , " headers-visible " ) ;
}
2007-11-12 18:44:49 -05:00
# endif //GLIBMM_PROPERTIES_ENABLED
2005-05-13 16:47:18 -04:00
2007-11-12 18:44:49 -05:00
# ifdef GLIBMM_PROPERTIES_ENABLED
2005-05-13 16:47:18 -04:00
Glib : : PropertyProxy < bool > TreeView : : property_headers_clickable ( )
{
return Glib : : PropertyProxy < bool > ( this , " headers-clickable " ) ;
}
2007-11-12 18:44:49 -05:00
# endif //GLIBMM_PROPERTIES_ENABLED
2005-05-13 16:47:18 -04:00
2007-11-12 18:44:49 -05:00
# ifdef GLIBMM_PROPERTIES_ENABLED
2005-05-13 16:47:18 -04:00
Glib : : PropertyProxy_ReadOnly < bool > TreeView : : property_headers_clickable ( ) const
{
return Glib : : PropertyProxy_ReadOnly < bool > ( this , " headers-clickable " ) ;
}
2007-11-12 18:44:49 -05:00
# endif //GLIBMM_PROPERTIES_ENABLED
2005-05-13 16:47:18 -04:00
2007-11-12 18:44:49 -05:00
# ifdef GLIBMM_PROPERTIES_ENABLED
2005-05-13 16:47:18 -04:00
Glib : : PropertyProxy < TreeViewColumn * > TreeView : : property_expander_column ( )
{
return Glib : : PropertyProxy < TreeViewColumn * > ( this , " expander-column " ) ;
}
2007-11-12 18:44:49 -05:00
# endif //GLIBMM_PROPERTIES_ENABLED
2005-05-13 16:47:18 -04:00
2007-11-12 18:44:49 -05:00
# ifdef GLIBMM_PROPERTIES_ENABLED
2005-05-13 16:47:18 -04:00
Glib : : PropertyProxy_ReadOnly < TreeViewColumn * > TreeView : : property_expander_column ( ) const
{
return Glib : : PropertyProxy_ReadOnly < TreeViewColumn * > ( this , " expander-column " ) ;
}
2007-11-12 18:44:49 -05:00
# endif //GLIBMM_PROPERTIES_ENABLED
2005-05-13 16:47:18 -04:00
2007-11-12 18:44:49 -05:00
# ifdef GLIBMM_PROPERTIES_ENABLED
2005-05-13 16:47:18 -04:00
Glib : : PropertyProxy < bool > TreeView : : property_reorderable ( )
{
return Glib : : PropertyProxy < bool > ( this , " reorderable " ) ;
}
2007-11-12 18:44:49 -05:00
# endif //GLIBMM_PROPERTIES_ENABLED
2005-05-13 16:47:18 -04:00
2007-11-12 18:44:49 -05:00
# ifdef GLIBMM_PROPERTIES_ENABLED
2005-05-13 16:47:18 -04:00
Glib : : PropertyProxy_ReadOnly < bool > TreeView : : property_reorderable ( ) const
{
return Glib : : PropertyProxy_ReadOnly < bool > ( this , " reorderable " ) ;
}
2007-11-12 18:44:49 -05:00
# endif //GLIBMM_PROPERTIES_ENABLED
2005-05-13 16:47:18 -04:00
2007-11-12 18:44:49 -05:00
# ifdef GLIBMM_PROPERTIES_ENABLED
2005-05-13 16:47:18 -04:00
Glib : : PropertyProxy < bool > TreeView : : property_rules_hint ( )
{
return Glib : : PropertyProxy < bool > ( this , " rules-hint " ) ;
}
2007-11-12 18:44:49 -05:00
# endif //GLIBMM_PROPERTIES_ENABLED
2005-05-13 16:47:18 -04:00
2007-11-12 18:44:49 -05:00
# ifdef GLIBMM_PROPERTIES_ENABLED
2005-05-13 16:47:18 -04:00
Glib : : PropertyProxy_ReadOnly < bool > TreeView : : property_rules_hint ( ) const
{
return Glib : : PropertyProxy_ReadOnly < bool > ( this , " rules-hint " ) ;
}
2007-11-12 18:44:49 -05:00
# endif //GLIBMM_PROPERTIES_ENABLED
2005-05-13 16:47:18 -04:00
2007-11-12 18:44:49 -05:00
# ifdef GLIBMM_PROPERTIES_ENABLED
2005-05-13 16:47:18 -04:00
Glib : : PropertyProxy < bool > TreeView : : property_enable_search ( )
{
return Glib : : PropertyProxy < bool > ( this , " enable-search " ) ;
}
2007-11-12 18:44:49 -05:00
# endif //GLIBMM_PROPERTIES_ENABLED
2005-05-13 16:47:18 -04:00
2007-11-12 18:44:49 -05:00
# ifdef GLIBMM_PROPERTIES_ENABLED
2005-05-13 16:47:18 -04:00
Glib : : PropertyProxy_ReadOnly < bool > TreeView : : property_enable_search ( ) const
{
return Glib : : PropertyProxy_ReadOnly < bool > ( this , " enable-search " ) ;
}
2007-11-12 18:44:49 -05:00
# endif //GLIBMM_PROPERTIES_ENABLED
2005-05-13 16:47:18 -04:00
2007-11-12 18:44:49 -05:00
# ifdef GLIBMM_PROPERTIES_ENABLED
2005-05-13 16:47:18 -04:00
Glib : : PropertyProxy < int > TreeView : : property_search_column ( )
{
return Glib : : PropertyProxy < int > ( this , " search-column " ) ;
}
2007-11-12 18:44:49 -05:00
# endif //GLIBMM_PROPERTIES_ENABLED
2005-05-13 16:47:18 -04:00
2007-11-12 18:44:49 -05:00
# ifdef GLIBMM_PROPERTIES_ENABLED
2005-05-13 16:47:18 -04:00
Glib : : PropertyProxy_ReadOnly < int > TreeView : : property_search_column ( ) const
{
return Glib : : PropertyProxy_ReadOnly < int > ( this , " search-column " ) ;
}
2007-11-12 18:44:49 -05:00
# endif //GLIBMM_PROPERTIES_ENABLED
2005-05-13 16:47:18 -04:00
2007-11-12 18:44:49 -05:00
# ifdef GLIBMM_PROPERTIES_ENABLED
2005-05-13 16:47:18 -04:00
Glib : : PropertyProxy < bool > TreeView : : property_fixed_height_mode ( )
{
return Glib : : PropertyProxy < bool > ( this , " fixed-height-mode " ) ;
}
2007-11-12 18:44:49 -05:00
# endif //GLIBMM_PROPERTIES_ENABLED
2005-05-13 16:47:18 -04:00
2007-11-12 18:44:49 -05:00
# ifdef GLIBMM_PROPERTIES_ENABLED
2005-05-13 16:47:18 -04:00
Glib : : PropertyProxy_ReadOnly < bool > TreeView : : property_fixed_height_mode ( ) const
{
return Glib : : PropertyProxy_ReadOnly < bool > ( this , " fixed-height-mode " ) ;
}
2007-11-12 18:44:49 -05:00
# endif //GLIBMM_PROPERTIES_ENABLED
2005-05-13 16:47:18 -04:00
2007-11-12 18:44:49 -05:00
# ifdef GLIBMM_PROPERTIES_ENABLED
2005-05-13 16:47:18 -04:00
Glib : : PropertyProxy < bool > TreeView : : property_hover_selection ( )
{
return Glib : : PropertyProxy < bool > ( this , " hover-selection " ) ;
}
2007-11-12 18:44:49 -05:00
# endif //GLIBMM_PROPERTIES_ENABLED
2005-05-13 16:47:18 -04:00
2007-11-12 18:44:49 -05:00
# ifdef GLIBMM_PROPERTIES_ENABLED
2005-05-13 16:47:18 -04:00
Glib : : PropertyProxy_ReadOnly < bool > TreeView : : property_hover_selection ( ) const
{
return Glib : : PropertyProxy_ReadOnly < bool > ( this , " hover-selection " ) ;
}
2007-11-12 18:44:49 -05:00
# endif //GLIBMM_PROPERTIES_ENABLED
2005-05-13 16:47:18 -04:00
2007-11-12 18:44:49 -05:00
# ifdef GLIBMM_PROPERTIES_ENABLED
2005-05-13 16:47:18 -04:00
Glib : : PropertyProxy < bool > TreeView : : property_hover_expand ( )
{
return Glib : : PropertyProxy < bool > ( this , " hover-expand " ) ;
}
2007-11-12 18:44:49 -05:00
# endif //GLIBMM_PROPERTIES_ENABLED
2005-05-13 16:47:18 -04:00
2007-11-12 18:44:49 -05:00
# ifdef GLIBMM_PROPERTIES_ENABLED
2005-05-13 16:47:18 -04:00
Glib : : PropertyProxy_ReadOnly < bool > TreeView : : property_hover_expand ( ) const
{
return Glib : : PropertyProxy_ReadOnly < bool > ( this , " hover-expand " ) ;
}
2007-11-12 18:44:49 -05:00
# endif //GLIBMM_PROPERTIES_ENABLED
2005-05-13 16:47:18 -04:00
2007-11-12 18:44:49 -05:00
# ifdef GLIBMM_PROPERTIES_ENABLED
Glib : : PropertyProxy < bool > TreeView : : property_show_expanders ( )
{
return Glib : : PropertyProxy < bool > ( this , " show-expanders " ) ;
}
# endif //GLIBMM_PROPERTIES_ENABLED
2005-05-13 16:47:18 -04:00
2007-11-12 18:44:49 -05:00
# ifdef GLIBMM_PROPERTIES_ENABLED
Glib : : PropertyProxy_ReadOnly < bool > TreeView : : property_show_expanders ( ) const
{
return Glib : : PropertyProxy_ReadOnly < bool > ( this , " show-expanders " ) ;
}
# endif //GLIBMM_PROPERTIES_ENABLED
# ifdef GLIBMM_PROPERTIES_ENABLED
Glib : : PropertyProxy < bool > TreeView : : property_level_indentation ( )
{
return Glib : : PropertyProxy < bool > ( this , " level-indentation " ) ;
}
# endif //GLIBMM_PROPERTIES_ENABLED
# ifdef GLIBMM_PROPERTIES_ENABLED
Glib : : PropertyProxy_ReadOnly < bool > TreeView : : property_level_indentation ( ) const
{
return Glib : : PropertyProxy_ReadOnly < bool > ( this , " level-indentation " ) ;
}
# endif //GLIBMM_PROPERTIES_ENABLED
# ifdef GLIBMM_PROPERTIES_ENABLED
Glib : : PropertyProxy < bool > TreeView : : property_rubber_banding ( )
{
return Glib : : PropertyProxy < bool > ( this , " rubber-banding " ) ;
}
# endif //GLIBMM_PROPERTIES_ENABLED
# ifdef GLIBMM_PROPERTIES_ENABLED
Glib : : PropertyProxy_ReadOnly < bool > TreeView : : property_rubber_banding ( ) const
{
return Glib : : PropertyProxy_ReadOnly < bool > ( this , " rubber-banding " ) ;
}
# endif //GLIBMM_PROPERTIES_ENABLED
# ifdef GLIBMM_PROPERTIES_ENABLED
Glib : : PropertyProxy < bool > TreeView : : property_enable_grid_lines ( )
{
return Glib : : PropertyProxy < bool > ( this , " enable-grid-lines " ) ;
}
# endif //GLIBMM_PROPERTIES_ENABLED
# ifdef GLIBMM_PROPERTIES_ENABLED
Glib : : PropertyProxy_ReadOnly < bool > TreeView : : property_enable_grid_lines ( ) const
{
return Glib : : PropertyProxy_ReadOnly < bool > ( this , " enable-grid-lines " ) ;
}
# endif //GLIBMM_PROPERTIES_ENABLED
# ifdef GLIBMM_PROPERTIES_ENABLED
Glib : : PropertyProxy < bool > TreeView : : property_enable_tree_lines ( )
{
return Glib : : PropertyProxy < bool > ( this , " enable-tree-lines " ) ;
}
# endif //GLIBMM_PROPERTIES_ENABLED
# ifdef GLIBMM_PROPERTIES_ENABLED
Glib : : PropertyProxy_ReadOnly < bool > TreeView : : property_enable_tree_lines ( ) const
{
return Glib : : PropertyProxy_ReadOnly < bool > ( this , " enable-tree-lines " ) ;
}
# endif //GLIBMM_PROPERTIES_ENABLED
# ifdef GLIBMM_DEFAULT_SIGNAL_HANDLERS_ENABLED
2005-05-13 16:47:18 -04:00
void Gtk : : TreeView : : on_set_scroll_adjustments ( Adjustment * hadjustment , Adjustment * vadjustment )
{
BaseClassType * const base = static_cast < BaseClassType * > (
g_type_class_peek_parent ( G_OBJECT_GET_CLASS ( gobject_ ) ) // Get the parent class of the object class (The original underlying C class).
) ;
if ( base & & base - > set_scroll_adjustments )
( * base - > set_scroll_adjustments ) ( gobj ( ) , ( GtkAdjustment * ) Glib : : unwrap ( hadjustment ) , ( GtkAdjustment * ) Glib : : unwrap ( vadjustment ) ) ;
}
void Gtk : : TreeView : : on_row_activated ( const TreeModel : : Path & path , TreeViewColumn * column )
{
BaseClassType * const base = static_cast < BaseClassType * > (
g_type_class_peek_parent ( G_OBJECT_GET_CLASS ( gobject_ ) ) // Get the parent class of the object class (The original underlying C class).
) ;
if ( base & & base - > row_activated )
( * base - > row_activated ) ( gobj ( ) , const_cast < GtkTreePath * > ( ( path ) . gobj ( ) ) , ( GtkTreeViewColumn * ) Glib : : unwrap ( column ) ) ;
}
bool Gtk : : TreeView : : on_test_expand_row ( const TreeModel : : iterator & iter , const TreeModel : : Path & path )
{
BaseClassType * const base = static_cast < BaseClassType * > (
g_type_class_peek_parent ( G_OBJECT_GET_CLASS ( gobject_ ) ) // Get the parent class of the object class (The original underlying C class).
) ;
if ( base & & base - > test_expand_row )
return ( * base - > test_expand_row ) ( gobj ( ) , const_cast < GtkTreeIter * > ( ( iter ) . gobj ( ) ) , const_cast < GtkTreePath * > ( ( path ) . gobj ( ) ) ) ;
typedef bool RType ;
return RType ( ) ;
}
bool Gtk : : TreeView : : on_test_collapse_row ( const TreeModel : : iterator & iter , const TreeModel : : Path & path )
{
BaseClassType * const base = static_cast < BaseClassType * > (
g_type_class_peek_parent ( G_OBJECT_GET_CLASS ( gobject_ ) ) // Get the parent class of the object class (The original underlying C class).
) ;
if ( base & & base - > test_collapse_row )
return ( * base - > test_collapse_row ) ( gobj ( ) , const_cast < GtkTreeIter * > ( ( iter ) . gobj ( ) ) , const_cast < GtkTreePath * > ( ( path ) . gobj ( ) ) ) ;
typedef bool RType ;
return RType ( ) ;
}
void Gtk : : TreeView : : on_row_expanded ( const TreeModel : : iterator & iter , const TreeModel : : Path & path )
{
BaseClassType * const base = static_cast < BaseClassType * > (
g_type_class_peek_parent ( G_OBJECT_GET_CLASS ( gobject_ ) ) // Get the parent class of the object class (The original underlying C class).
) ;
if ( base & & base - > row_expanded )
( * base - > row_expanded ) ( gobj ( ) , const_cast < GtkTreeIter * > ( ( iter ) . gobj ( ) ) , const_cast < GtkTreePath * > ( ( path ) . gobj ( ) ) ) ;
}
void Gtk : : TreeView : : on_row_collapsed ( const TreeModel : : iterator & iter , const TreeModel : : Path & path )
{
BaseClassType * const base = static_cast < BaseClassType * > (
g_type_class_peek_parent ( G_OBJECT_GET_CLASS ( gobject_ ) ) // Get the parent class of the object class (The original underlying C class).
) ;
if ( base & & base - > row_collapsed )
( * base - > row_collapsed ) ( gobj ( ) , const_cast < GtkTreeIter * > ( ( iter ) . gobj ( ) ) , const_cast < GtkTreePath * > ( ( path ) . gobj ( ) ) ) ;
}
void Gtk : : TreeView : : on_cursor_changed ( )
{
BaseClassType * const base = static_cast < BaseClassType * > (
g_type_class_peek_parent ( G_OBJECT_GET_CLASS ( gobject_ ) ) // Get the parent class of the object class (The original underlying C class).
) ;
if ( base & & base - > cursor_changed )
( * base - > cursor_changed ) ( gobj ( ) ) ;
}
void Gtk : : TreeView : : on_columns_changed ( )
{
BaseClassType * const base = static_cast < BaseClassType * > (
g_type_class_peek_parent ( G_OBJECT_GET_CLASS ( gobject_ ) ) // Get the parent class of the object class (The original underlying C class).
) ;
if ( base & & base - > columns_changed )
( * base - > columns_changed ) ( gobj ( ) ) ;
}
2007-11-12 18:44:49 -05:00
# endif //GLIBMM_DEFAULT_SIGNAL_HANDLERS_ENABLED
# ifdef GLIBMM_VFUNCS_ENABLED
# endif //GLIBMM_VFUNCS_ENABLED
2005-05-13 16:47:18 -04:00
} // namespace Gtk