using System; using System.Drawing; public static class DisplayFusionFunction { public static void Run() { IntPtr[] windows = BFS.Window.GetAllWindowHandles(); if (BFS.ScriptSettings.ReadValueBool("SkypeMinimized") == false) { foreach (IntPtr window in windows) { if (BFS.Application.GetMainFileByWindow(window).Contains("Skype.exe") && (BFS.Window.GetClass(window).Contains("tSkMainForm") || BFS.Window.GetClass(window).Contains("TConversationForm") || BFS.Window.GetClass(window).Contains("THomeForm"))) BFS.Window.Minimize(window); } BFS.ScriptSettings.WriteValueBool("SkypeMinimized", true); } else { foreach (IntPtr window in windows) { if (BFS.Application.GetMainFileByWindow(window).Contains("Skype.exe") && (BFS.Window.GetClass(window).Contains("tSkMainForm") || BFS.Window.GetClass(window).Contains("TConversationForm") || BFS.Window.GetClass(window).Contains("THomeForm"))) BFS.Window.Restore(window); } BFS.ScriptSettings.WriteValueBool("SkypeMinimized", false); } } }