public ConferenceIMTabWindow(RadegastInstance instance, UUID session, string sessionName) { InitializeComponent(); Disposed += new EventHandler(IMTabWindow_Disposed); this.instance = instance; client = instance.Client; SessionName = sessionName; netcom = this.instance.Netcom; SessionId = session; TextManager = new IMTextManager(this.instance, new RichTextBoxPrinter(rtbIMText), IMTextManagerType.Conference, SessionId, sessionName); // Callbacks netcom.ClientLoginStatus += new EventHandler <LoginProgressEventArgs>(netcom_ClientLoginStatus); netcom.ClientDisconnected += new EventHandler <DisconnectedEventArgs>(netcom_ClientDisconnected); instance.GlobalSettings.OnSettingChanged += new Settings.SettingChangedCallback(GlobalSettings_OnSettingChanged); if (!client.Self.GroupChatSessions.ContainsKey(session)) { client.Self.ChatterBoxAcceptInvite(session); } GUI.GuiHelpers.ApplyGuiFixes(this); }
public frmProfile(RadegastInstance instance, string fullName, UUID agentID) : base(instance) { InitializeComponent(); Disposed += new EventHandler(frmProfile_Disposed); AutoSavePosition = true; this.instance = instance; netcom = this.instance.Netcom; client = this.instance.Client; this.fullName = fullName; this.agentID = agentID; this.Text = fullName + " (profile) - " + Properties.Resources.ProgramName; txtUUID.Text = agentID.ToString(); if (client.Friends.FriendList.ContainsKey(agentID)) { btnFriend.Enabled = false; } if (instance.InventoryClipboard != null) { btnGive.Enabled = true; } if (agentID == client.Self.AgentID) { myProfile = true; rtbAbout.ReadOnly = false; rtbAboutFL.ReadOnly = false; txtWebURL.ReadOnly = false; pickTitle.ReadOnly = false; pickDetail.ReadOnly = false; btnRequestTeleport.Visible = false; btnDeletePick.Visible = true; btnNewPick.Visible = true; } // Callbacks client.Avatars.AvatarPropertiesReply += new EventHandler <AvatarPropertiesReplyEventArgs>(Avatars_AvatarPropertiesReply); client.Avatars.AvatarPicksReply += new EventHandler <AvatarPicksReplyEventArgs>(Avatars_AvatarPicksReply); client.Avatars.PickInfoReply += new EventHandler <PickInfoReplyEventArgs>(Avatars_PickInfoReply); client.Parcels.ParcelInfoReply += new EventHandler <ParcelInfoReplyEventArgs>(Parcels_ParcelInfoReply); client.Avatars.AvatarGroupsReply += new EventHandler <AvatarGroupsReplyEventArgs>(Avatars_AvatarGroupsReply); client.Self.MuteListUpdated += new EventHandler <EventArgs>(Self_MuteListUpdated); netcom.ClientDisconnected += new EventHandler <DisconnectedEventArgs>(netcom_ClientDisconnected); instance.InventoryClipboardUpdated += new EventHandler <EventArgs>(instance_InventoryClipboardUpdated); InitializeProfile(); Radegast.GUI.GuiHelpers.ApplyGuiFixes(this); }
public RegionSearchResultItem(RadegastInstance instance, GridRegion region, ListBox listBox) { this.instance = instance; netcom = this.instance.Netcom; client = this.instance.Client; this.region = region; this.listBox = listBox; agentCountWorker = new BackgroundWorker(); agentCountWorker.DoWork += new DoWorkEventHandler(agentCountWorker_DoWork); agentCountWorker.RunWorkerCompleted += new RunWorkerCompletedEventHandler(agentCountWorker_RunWorkerCompleted); AddClientEvents(); }
public FindPeopleConsole(RadegastInstance instance, UUID queryID) { InitializeComponent(); Disposed += new EventHandler(FindPeopleConsole_Disposed); findPeopleResults = new Dictionary <string, UUID>(); this.queryID = queryID; this.instance = instance; netcom = this.instance.Netcom; client = this.instance.Client; // Callbacks client.Directory.DirPeopleReply += new EventHandler <DirPeopleReplyEventArgs>(Directory_DirPeopleReply); }
public RadegastInstance(GridClient client0) { // incase something else calls GlobalInstance while we are loading globalInstance = this; if (!System.Diagnostics.Debugger.IsAttached) { Application.SetUnhandledExceptionMode(UnhandledExceptionMode.CatchException); Application.ThreadException += HandleThreadException; } client = client0; // Initialize current time zone, and mark when we started GetWorldTimeZone(); StartupTimeUTC = DateTime.UtcNow; // Are we running mono? monoRuntime = Type.GetType("Mono.Runtime") != null; Keyboard = new Keyboard(); Application.AddMessageFilter(Keyboard); netcom = new RadegastNetcom(this); state = new StateManager(this); mediaManager = new MediaManager(this); commandsManager = new CommandsManager(this); ContextActionManager = new ContextActionsManager(this); RegisterContextActions(); movement = new RadegastMovement(this); InitializeLoggingAndConfig(); InitializeClient(client); rlv = new RLVManager(this); gridManager = new GridManager(); gridManager.LoadGrids(); names = new NameManager(this); COF = new CurrentOutfitFolder(this); mainForm = new frmMain(this); mainForm.InitializeControls(); mainForm.Load += new EventHandler(mainForm_Load); pluginManager = new PluginManager(this); pluginManager.ScanAndLoadPlugins(); }
public frmTeleport(RadegastInstance instance) { InitializeComponent(); Disposed += new EventHandler(frmTeleport_Disposed); this.instance = instance; netcom = this.instance.Netcom; client = this.instance.Client; // Callbacks netcom.ClientDisconnected += new EventHandler <DisconnectedEventArgs>(netcom_ClientDisconnected); client.Grid.GridRegion += new EventHandler <GridRegionEventArgs>(Grid_GridRegion); client.Self.TeleportProgress += new EventHandler <TeleportEventArgs>(Self_TeleportProgress); SetDefaultValues(); }
public void CleanUp() { MarkEndExecution(); if (COF != null) { COF.Dispose(); COF = null; } if (names != null) { names.Dispose(); names = null; } if (gridManager != null) { gridManager.Dispose(); gridManager = null; } if (rlv != null) { rlv.Dispose(); rlv = null; } if (client != null) { UnregisterClientEvents(client); } if (pluginManager != null) { pluginManager.Dispose(); pluginManager = null; } if (movement != null) { movement.Dispose(); movement = null; } if (commandsManager != null) { commandsManager.Dispose(); commandsManager = null; } if (ContextActionManager != null) { ContextActionManager.Dispose(); ContextActionManager = null; } if (mediaManager != null) { mediaManager.Dispose(); mediaManager = null; } if (state != null) { state.Dispose(); state = null; } if (netcom != null) { netcom.Dispose(); netcom = null; } if (mainForm != null) { mainForm.Load -= new EventHandler(mainForm_Load); } Logger.Log("RadegastInstance finished cleaning up.", Helpers.LogLevel.Debug); }