123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657 |
- using System;
- using System.Windows.Forms;
- namespace ScreenSaverEf
- {
-
- internal static class Program
- {
-
-
-
- [STAThread]
- private static void Main(string[] args)
- {
- Application.EnableVisualStyles();
- Application.SetCompatibleTextRenderingDefault(false);
- if (args.Length > 0)
- {
- if (args[0].Substring(0, 2).ToUpper().Equals("/C"))
- {
- MessageBox.Show("此屏幕保护没有可供设置的选项!", "Ef屏保",
- MessageBoxButtons.OK, MessageBoxIcon.Information);
- Application.Exit();
- }
- else if (args[0].ToUpper() == "/A")
- {
- MessageBox.Show("此屏幕保护没有可供设定口令的选项!", "Ef屏保",
- MessageBoxButtons.OK, MessageBoxIcon.Information);
- Application.Exit();
- }
- else if (args[0].ToUpper() == "/P")
- {
- var temp = args[1];
- var CPWindow = (IntPtr)Convert.ToInt32(temp);
- new PreviewForm(CPWindow).ShowDialog();
- }
- else if (args[0].ToUpper() == "/S")
- {
-
- for (var i = 1; i < Screen.AllScreens.Length; i++)
- {
- new MainForm(i).Show();
- }
- Application.Run(new MainForm());
- }
- }
- else
- {
- Application.Run(new MainForm());
- }
- }
- }
- }
|