Пример #1
0
		public void SetCellDataFunc (CellRenderer cell_renderer, NodeCellDataFunc func)
		{
			if (func == null) {
				gtk_tree_view_column_set_cell_data_func (Handle, cell_renderer == null ? IntPtr.Zero : cell_renderer.Handle, (GtkSharp.TreeCellDataFuncNative) null, IntPtr.Zero, null);
				return;
			}

			NodeCellDataFuncWrapper func_wrapper = new NodeCellDataFuncWrapper (func);
			GCHandle gch = GCHandle.Alloc (func_wrapper);
			gtk_cell_layout_set_cell_data_func (Handle, cell_renderer == null ? IntPtr.Zero : cell_renderer.Handle, func_wrapper.NativeDelegate, (IntPtr) gch, GLib.DestroyHelper.NotifyHandler);
		}
Пример #2
0
		public NodeCellDataFuncWrapper (NodeCellDataFunc managed)
		{
			NativeDelegate = new GtkSharp.CellLayoutDataFuncNative (NativeCallback);
			this.managed = managed;
		}
Пример #3
0
 public NodeCellDataFuncWrapper(NodeCellDataFunc managed)
 {
     NativeDelegate = new GtkSharp.CellLayoutDataFuncNative(NativeCallback);
     this.managed   = managed;
 }