using System; using System.Drawing; // The 'windowHandle' parameter will contain the window handle for the: // - Active window when run by hotkey // - Window Location target when run by a Window Location rule // - TitleBar Button owner when run by a TitleBar Button // - Jump List owner when run from a Taskbar Jump List // - Currently focused window if none of these match public static class DisplayFusionFunction { public static void Run(IntPtr windowHandle) { //these are all of the functions from the "Window Management" functions list //the function are just called by their namess. to find their names, you can copy them //from the context menus, or type "BFS.DisplayFusion.RunFunction(" and a window will come up //with all of the available functions string[] functions = { "Highlight Window", "Highlight Window: Disable All Highlights", "Maximize Window", "Maximize Window (ignore monitor splits)", "Minimize Window", "Minimize Window To System Tray", "Prevent Window Deactivation (keeps game windows focused)", "Restore Window", "Restore Window Positions From Last Save", "Rollup Window to Hat", "Rollup Window to Icon", "Rollup Window to TitleBar", "Save Window Positions", "Send Window to Back", "Send Windows Store (Metro) app to desktop window", "Toggle Window Always on Top", "Toggle Window Transparency", }; //show a popup window with the list of functions string input = BFS.Dialog.GetUserInputList("Select a function to run:", functions); //if the input is empty, the user hit cancel if(string.IsNullOrEmpty(input)) return; //run the selected function from the list BFS.DisplayFusion.RunFunction(input); } }