From 3fb0631c4e597b9c16db7fd81e6db9be2f9102e6 Mon Sep 17 00:00:00 2001 From: Ben Maurer Date: Mon, 22 Aug 2005 17:06:01 +0000 Subject: [PATCH] 2005-08-22 Ben Maurer * gtk/NodeView.cs: Fix leak here. r=mkestner svn path=/trunk/gtk-sharp/; revision=48682 --- ChangeLog | 4 ++++ gtk/NodeView.cs | 5 ++++- 2 files changed, 8 insertions(+), 1 deletion(-) diff --git a/ChangeLog b/ChangeLog index 0e679415c..261083be5 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,7 @@ +2005-08-22 Ben Maurer + + * gtk/NodeView.cs: Fix leak here. r=mkestner + 2005-08-22 Mike Kestner * parser/gapi2xml.pl : handle "type const *" parameters. diff --git a/gtk/NodeView.cs b/gtk/NodeView.cs index 3c5981a65..c7a93deb5 100644 --- a/gtk/NodeView.cs +++ b/gtk/NodeView.cs @@ -31,6 +31,7 @@ namespace Gtk { public class NodeView : TreeView { NodeStore store; + NodeSelection selection; public NodeView (NodeStore store) : base (IntPtr.Zero) { @@ -49,7 +50,9 @@ namespace Gtk { public NodeSelection NodeSelection { get { - return new NodeSelection (Selection); + if (selection == null) + selection = new NodeSelection (Selection); + return selection; } }