-
Notifications
You must be signed in to change notification settings - Fork 326
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #411 from stewienj/Anchorable-Close-Notifications
Add anchorable hide and close notifications to DockingManager
- Loading branch information
Showing
9 changed files
with
414 additions
and
13 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,35 @@ | ||
/************************************************************************ | ||
AvalonDock | ||
Copyright (C) 2007-2013 Xceed Software Inc. | ||
This program is provided to you under the terms of the Microsoft Public | ||
License (Ms-PL) as published at https://opensource.org/licenses/MS-PL | ||
************************************************************************/ | ||
|
||
using AvalonDock.Layout; | ||
using System; | ||
|
||
namespace AvalonDock | ||
{ | ||
/// <summary> | ||
/// Implements an event that can be raised to inform the client application about an | ||
/// anchorable that been closed and removed its content (viewmodel) from the docking framework. | ||
/// </summary> | ||
public class AnchorableClosedEventArgs : EventArgs | ||
{ | ||
/// <summary> | ||
/// Class constructor from the anchorables layout model. | ||
/// </summary> | ||
/// <param name="document"></param> | ||
public AnchorableClosedEventArgs(LayoutAnchorable anchorable) | ||
{ | ||
Anchorable = anchorable; | ||
} | ||
|
||
/// <summary> | ||
/// Gets the model of the anchorable that has been closed. | ||
/// </summary> | ||
public LayoutAnchorable Anchorable { get; private set; } | ||
} | ||
} |
35 changes: 35 additions & 0 deletions
35
source/Components/AvalonDock/AnchorableClosingEventArgs.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,35 @@ | ||
/************************************************************************ | ||
AvalonDock | ||
Copyright (C) 2007-2013 Xceed Software Inc. | ||
This program is provided to you under the terms of the Microsoft Public | ||
License (Ms-PL) as published at https://opensource.org/licenses/MS-PL | ||
************************************************************************/ | ||
|
||
using AvalonDock.Layout; | ||
using System.ComponentModel; | ||
|
||
namespace AvalonDock | ||
{ | ||
/// <summary> | ||
/// Implements a Cancelable event that can be raised to ask the client application whether closing this anchorable | ||
/// and removing its content (viewmodel) is OK or not. | ||
/// </summary> | ||
public class AnchorableClosingEventArgs : CancelEventArgs | ||
{ | ||
/// <summary> | ||
/// Class constructor from the anchorable layout model. | ||
/// </summary> | ||
/// <param name="document"></param> | ||
public AnchorableClosingEventArgs(LayoutAnchorable anchorable) | ||
{ | ||
Anchorable = anchorable; | ||
} | ||
|
||
/// <summary> | ||
/// Gets the model of the anchorable that is about to be closed. | ||
/// </summary> | ||
public LayoutAnchorable Anchorable { get; private set; } | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,35 @@ | ||
/************************************************************************ | ||
AvalonDock | ||
Copyright (C) 2007-2013 Xceed Software Inc. | ||
This program is provided to you under the terms of the Microsoft Public | ||
License (Ms-PL) as published at https://opensource.org/licenses/MS-PL | ||
************************************************************************/ | ||
|
||
using AvalonDock.Layout; | ||
using System; | ||
|
||
namespace AvalonDock | ||
{ | ||
/// <summary> | ||
/// Implements an event that can be raised to inform the client application about an | ||
/// anchorable that been hidden. | ||
/// </summary> | ||
public class AnchorableHiddenEventArgs : EventArgs | ||
{ | ||
/// <summary> | ||
/// Class constructor from the anchorables layout model. | ||
/// </summary> | ||
/// <param name="document"></param> | ||
public AnchorableHiddenEventArgs(LayoutAnchorable anchorable) | ||
{ | ||
Anchorable = anchorable; | ||
} | ||
|
||
/// <summary> | ||
/// Gets the model of the anchorable that has been hidden. | ||
/// </summary> | ||
public LayoutAnchorable Anchorable { get; private set; } | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,40 @@ | ||
/************************************************************************ | ||
AvalonDock | ||
Copyright (C) 2007-2013 Xceed Software Inc. | ||
This program is provided to you under the terms of the Microsoft Public | ||
License (Ms-PL) as published at https://opensource.org/licenses/MS-PL | ||
************************************************************************/ | ||
|
||
using AvalonDock.Layout; | ||
using System.ComponentModel; | ||
|
||
namespace AvalonDock | ||
{ | ||
/// <summary> | ||
/// Implements a Cancelable event that can be raised to ask the client application whether hiding this anchorable | ||
/// is OK or not. | ||
/// </summary> | ||
public class AnchorableHidingEventArgs : CancelEventArgs | ||
{ | ||
/// <summary> | ||
/// Class constructor from the anchorable layout model. | ||
/// </summary> | ||
/// <param name="document"></param> | ||
public AnchorableHidingEventArgs(LayoutAnchorable anchorable) | ||
{ | ||
Anchorable = anchorable; | ||
} | ||
|
||
/// <summary> | ||
/// Gets the model of the anchorable that is about to be hidden. | ||
/// </summary> | ||
public LayoutAnchorable Anchorable { get; private set; } | ||
|
||
/// <summary> | ||
/// Gets or sets a value indicating whether an anchorable should be closed instead of hidden | ||
/// </summary> | ||
public bool CloseInsteadOfHide { get; set; } | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.