From cda826f8aa6e2d3e0f86b4bb29cb505379ff2968 Mon Sep 17 00:00:00 2001 From: jpbruyere Date: Tue, 8 Mar 2016 08:37:52 +0100 Subject: [PATCH] remove IGOLibHost --- src/GraphicObjects/IGOLibHost.cs | 19 ------------------- src/GraphicObjects/Popper.cs | 7 ++----- 2 files changed, 2 insertions(+), 24 deletions(-) delete mode 100644 src/GraphicObjects/IGOLibHost.cs diff --git a/src/GraphicObjects/IGOLibHost.cs b/src/GraphicObjects/IGOLibHost.cs deleted file mode 100644 index 5c842e32..00000000 --- a/src/GraphicObjects/IGOLibHost.cs +++ /dev/null @@ -1,19 +0,0 @@ -using System; -using System.Collections.Generic; - -namespace Crow -{ - public interface IGOLibHost - { - List gobjsToRedraw { get; } - GraphicObject activeWidget { get; set; } - GraphicObject hoverWidget { get; set; } - GraphicObject FocusedWidget { get; set; } - XCursor MouseCursor { set; } - void AddWidget (GraphicObject g); - void DeleteWidget(GraphicObject g); - void PutOnTop (GraphicObject g); - void Quit (); - } -} - diff --git a/src/GraphicObjects/Popper.cs b/src/GraphicObjects/Popper.cs index 5938fd8a..7c068085 100644 --- a/src/GraphicObjects/Popper.cs +++ b/src/GraphicObjects/Popper.cs @@ -92,11 +92,8 @@ namespace Crow { //ensure popped window is cleared if (Content != null) { - if (Content.Parent != null) { - IGOLibHost tc = Content.Parent as IGOLibHost; - if (tc != null) - tc.DeleteWidget (Content); - } + if (Content.Parent != null) + Interface.CurrentInterface.DeleteWidget (Content); } base.ClearBinding (); } -- 2.47.3