Files
mRemoteNG/mRemoteV1/Tree/TreeNodeDoubleClickHandler.cs
David Sparer 4c792308bb moved all click-actions for the tree to separate classes to make them easily composable
this has the nice effect of also pushing any calls to the settings class outside the classes that are actualy doing work, making them much easier to test in isolation
2017-01-12 12:47:23 -07:00

20 lines
532 B
C#

using System.Collections.Generic;
using mRemoteNG.Connection;
namespace mRemoteNG.Tree
{
public class TreeNodeDoubleClickHandler : ITreeNodeClickHandler
{
public IEnumerable<ITreeNodeClickHandler> ClickHandlers { get; set; } = new ITreeNodeClickHandler[0];
public void Execute(ConnectionInfo clickedNode)
{
if (clickedNode == null) return;
foreach (var handler in ClickHandlers)
{
handler.Execute(clickedNode);
}
}
}
}