mirror of
https://github.com/mRemoteNG/mRemoteNG.git
synced 2026-02-17 22:11:48 +08:00
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
20 lines
532 B
C#
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);
|
|
}
|
|
}
|
|
}
|
|
} |