public Form1() { if (!SaveManager.Open((string)Properties.Settings.Default["LatestFilePath"])) { SaveManager.New(); } InitializeComponent(); LoadData(); (panel1 as Control).KeyDown += new KeyEventHandler(panel1_KeyDown); (panel1 as Control).KeyUp += new KeyEventHandler(panel1_KeyUp); SaveManager.DirtyChanged += new EventHandler(saveManager_DirtyChanged); myMap.GenerateAllLODs(); }