Exemplo n.º 1
0
        public void Drop(Point dropLocation, out bool dropHandled)
        {
            dropHandled = false;
            this.UpdateMouseLocation(dropLocation);
            ILayoutRoot root = (this._floatingWindow.Model as LayoutFloatingWindow).Root;

            if (this._currentHost != null)
            {
                this._currentHost.HideOverlayWindow();
            }
            if (this._currentDropTarget != null)
            {
                this._currentWindow.DragDrop(this._currentDropTarget);
                root.CollectGarbage();
                dropHandled = true;
            }
            this._currentWindowAreas.ForEach((IDropArea a) => this._currentWindow.DragLeave(a));
            if (this._currentDropTarget != null)
            {
                this._currentWindow.DragLeave(this._currentDropTarget);
            }
            if (this._currentWindow != null)
            {
                this._currentWindow.DragLeave(this._floatingWindow);
            }
            this._currentWindow = null;
            this._currentHost   = null;
        }
Exemplo n.º 2
0
        internal void CloseInternal()
        {
            ILayoutRoot root = base.Root;

            base.Parent.RemoveChild(this);
            if (root != null)
            {
                root.CollectGarbage();
            }
            this.OnClosed();
        }
Exemplo n.º 3
0
        protected override void OnClosed(EventArgs e)
        {
            ILayoutRoot root = this.Model.Root;

            root.Manager.RemoveFloatingWindow(this);
            root.CollectGarbage();
            base.OnClosed(e);
            if (!base.CloseInitiatedByUser)
            {
                root.FloatingWindows.Remove(this._model);
            }
            this._model.RootDocumentChanged -= new EventHandler(this._model_RootDocumentChanged);
        }
Exemplo n.º 4
0
        protected override void OnClosed(EventArgs e)
        {
            ILayoutRoot root = this.Model.Root;

            root.Manager.RemoveFloatingWindow(this);
            root.CollectGarbage();
            if (this._overlayWindow != null)
            {
                this._overlayWindow.Close();
                this._overlayWindow = null;
            }
            base.OnClosed(e);
            if (!base.CloseInitiatedByUser)
            {
                root.FloatingWindows.Remove(this._model);
            }
            this._model.PropertyChanged -= new PropertyChangedEventHandler(this._model_PropertyChanged);
        }