3 This file is part of the HandBrake source code.
\r
4 Homepage: <http://handbrake.fr>.
\r
5 It may be used under the terms of the GNU General Public License. */
\r
8 using System.Collections.Generic;
\r
9 using System.Collections.Specialized;
\r
10 using System.ComponentModel;
\r
12 using System.Drawing;
\r
14 using System.Windows.Forms;
\r
17 using System.Diagnostics;
\r
18 using System.Threading;
\r
19 using System.Runtime.InteropServices;
\r
20 using System.Globalization;
\r
25 static class Program
\r
28 /// The main entry point for the application.
\r
33 // Development Code Expiry.
\r
34 // Remember to comment out on public release!!!
\r
35 //if (DateTime.Now > DateTime.Parse("2008/02/25", new CultureInfo("en-US"))) { MessageBox.Show("Sorry, This development build of Handbrake has expired."); return; }
\r
37 // Check the system meets the system requirements.
\r
38 Boolean launch = true;
\r
41 // Make sure the screen resolution is not below 1024x768
\r
42 System.Windows.Forms.Screen scr = System.Windows.Forms.Screen.PrimaryScreen;
\r
43 if ((scr.Bounds.Width < 1024) || (scr.Bounds.Height < 720))
\r
45 MessageBox.Show("Your system does not meet the minimum requirements for HandBrake. \n" + "Your screen is running at: " + scr.Bounds.Width.ToString() + "x" + scr.Bounds.Height.ToString() + " \nScreen resolution is too Low. Must be 1024x720 or greater", "Error", MessageBoxButtons.OK, MessageBoxIcon.Error);
\r
49 // Make sure the system has enough RAM. 384MB or greater
\r
50 Functions.SystemInfo info = new Functions.SystemInfo();
\r
51 uint memory = info.TotalPhysicalMemory();
\r
55 MessageBox.Show("Your system does not meet the minimum requirements for HandBrake. \n Insufficient RAM. 384MB or greater required. You have: " + memory.ToString() + "MB", "Error", MessageBoxButtons.OK, MessageBoxIcon.Error);
\r
59 catch (Exception exc)
\r
61 MessageBox.Show("frmMain.cs - systemCheck() " + exc.ToString());
\r
64 // Either Launch or Close the Application
\r
67 Application.EnableVisualStyles();
\r
68 Application.SetCompatibleTextRenderingDefault(false);
\r
69 Application.Run(new frmMain());
\r