using System.Windows;
using System.Windows.Input;

namespace QC.QTMApplication.Utilities;

public class HelpUtility
{
	public enum FocusedControl
	{
		None,
		ParameterView,
		PropertyView,
		LoopView,
		TestTree,
		TreeRegistry
	}

	public static FocusedControl CurrentFocusedControl { get; set; }

	internal static string GetHelpTopicId(DependencyObject window)
	{
		FocusManager.GetFocusedElement(window);
		return CurrentFocusedControl switch
		{
			FocusedControl.TestTree => "3", 
			FocusedControl.TreeRegistry => "5", 
			FocusedControl.LoopView => "17", 
			FocusedControl.ParameterView => "16", 
			FocusedControl.PropertyView => "13", 
			_ => "1", 
		};
	}
}
