using System; using System.Collections.Generic; using System.Linq; using System.Web; using System.Web.UI; using System.Web.UI.WebControls; using RemoteController; using System.Text; using System.Collections; using RemoteController.ReceiverClasses; public partial class _Default : System.Web.UI.Page { private House h; protected void Page_Load(object sender, EventArgs e) { Slot0.BtnCmdClicked += new CommandSlot.BtnCommandClickedHandler(ApplianceDisplayID.CmdButtonWasClicked); Slot1.BtnCmdClicked += new CommandSlot.BtnCommandClickedHandler(ApplianceDisplayID.CmdButtonWasClicked); Slot2.BtnCmdClicked += new CommandSlot.BtnCommandClickedHandler(ApplianceDisplayID.CmdButtonWasClicked); Slot3.BtnCmdClicked += new CommandSlot.BtnCommandClickedHandler(ApplianceDisplayID.CmdButtonWasClicked); Slot4.BtnCmdClicked += new CommandSlot.BtnCommandClickedHandler(ApplianceDisplayID.CmdButtonWasClicked); Slot5.BtnCmdClicked += new CommandSlot.BtnCommandClickedHandler(ApplianceDisplayID.CmdButtonWasClicked); Slot6.BtnCmdClicked += new CommandSlot.BtnCommandClickedHandler(ApplianceDisplayID.CmdButtonWasClicked); if (Session["HOUSE"] == null) { h = new House(); Session["HOUSE"] = h; } } protected void BtnUndo_Click(object sender, EventArgs e) { h = (House)Session["HOUSE"]; h.undo_button_pushed(); Session["HOUSE"] = h; ApplianceDisplayID.CmdButtonWasClicked(sender, e); } }