private void Form1_Load(object sender, EventArgs e) { this.SetStyle(ControlStyles.SupportsTransparentBackColor, true); RegistryKey key = Registry.CurrentUser.OpenSubKey("Software\\SkidSimulator"); if (key == null) { Registry.CurrentUser.CreateSubKey("Software\\SkidSimulator"); } key = Registry.CurrentUser.OpenSubKey("Software\\SkidSimulator"); if (key != null) { Object o = key.GetValue("BgPath"); if (o != null) { string path = o as String; try { if (File.Exists(path)) { this.BackgroundImage = Image.FromFile(path); } } catch { MessageBox.Show("Cannot load or find background image path."); } } Object o2 = key.GetValue("skidName"); if (o2 != null) { string name = o2 as String; Props.SetSkidName(name); } Object o3 = key.GetValue("newSkid"); if (o3 != null) { Props.ShowMessage("Welcome back " + skidName.Text); } else { Selector selector = new Selector(); Props.mainForm.Controls.Add(selector); } Object o4 = key.GetValue("hackerType"); if (o4 != null) { string hType = o4 as String; Props.hacker = (Props.hackerType)Enum.Parse(typeof(Props.hackerType), hType); } Object o5 = key.GetValue("Fullscreen"); if (o5 != null) { bool full = bool.Parse(o5 as string); if (full) { Props.HandleFullscreen(); } } } if (Props.hacker == Props.hackerType.Hecks) { Props.AddNotification("How does a condom work?"); } this.DoubleBuffered = true; Keyhook.Initialize(); Props.staticpad = new Textpad(); Props.staticmd = new CMD(); itemImage1.OpenForm = Props.staticmd; itemImage2.OpenForm = Props.staticpad; itemImage4.isGT = true; Props.doWeInit = true; UpdateTime(); }
private void fullScreen_Click(object sender, EventArgs e) { Props.HandleFullscreen(); }
private void ActionCentre_Click(object sender, EventArgs e) { Props.HandleNotifShow(); }
private void winbutton_Click(object sender, EventArgs e) { Props.HandleMenuShow(); }