[longomatch] Fix disposing of timeline objects
- From: Andoni Morales Alastruey <amorales src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [longomatch] Fix disposing of timeline objects
- Date: Wed, 24 Sep 2014 20:17:33 +0000 (UTC)
commit 7f886120599c4a113f60d379aab9a83f085a40d1
Author: Andoni Morales Alastruey <ylatuya gmail com>
Date: Wed Aug 27 20:21:05 2014 +0200
Fix disposing of timeline objects
LongoMatch.Drawing/CanvasObjects/TimelineObject.cs | 3 +++
LongoMatch.Drawing/Widgets/PlaysTimeline.cs | 8 ++++++++
2 files changed, 11 insertions(+), 0 deletions(-)
---
diff --git a/LongoMatch.Drawing/CanvasObjects/TimelineObject.cs
b/LongoMatch.Drawing/CanvasObjects/TimelineObject.cs
index b6d46b0..a96e2fe 100644
--- a/LongoMatch.Drawing/CanvasObjects/TimelineObject.cs
+++ b/LongoMatch.Drawing/CanvasObjects/TimelineObject.cs
@@ -50,6 +50,9 @@ namespace LongoMatch.Drawing.CanvasObjects
protected override void Dispose (bool disposing)
{
+ foreach (TimeNodeObject tn in nodes) {
+ tn.Dispose ();
+ }
selectionBorderL.Dispose ();
selectionBorderR.Dispose ();
base.Dispose (disposing);
diff --git a/LongoMatch.Drawing/Widgets/PlaysTimeline.cs b/LongoMatch.Drawing/Widgets/PlaysTimeline.cs
index ff96824..fa737f3 100644
--- a/LongoMatch.Drawing/Widgets/PlaysTimeline.cs
+++ b/LongoMatch.Drawing/Widgets/PlaysTimeline.cs
@@ -45,6 +45,14 @@ namespace LongoMatch.Drawing.Widgets
Accuracy = Constants.TIMELINE_ACCURACY;
SelectionMode = MultiSelectionMode.MultipleWithModifier;
}
+
+ protected override void Dispose (bool disposing)
+ {
+ foreach (CategoryTimeline ct in categories.Values) {
+ ct.Dispose ();
+ }
+ base.Dispose (disposing);
+ }
public void LoadProject (Project project, PlaysFilter filter)
{
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]