Exemple #1
0
        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 void Reconnect()
        {
            TabConsole.DisplayNotificationInChat("Attempting to reconnect...", ChatBufferTextStyle.StatusDarkBlue);
            Logger.Log("Attemting to reconnect", Helpers.LogLevel.Info, Client);
            GridClient oldClient = Client;

            Client = new GridClient();
            UnregisterClientEvents(oldClient);
            InitializeClient(Client);
            OnClientChanged(new ClientChangedEventArgs(oldClient, Client));
            Netcom.Login();
        }
        public FindPeopleConsole(RadegastInstance instance, UUID queryID)
        {
            InitializeComponent();
            Disposed += new EventHandler(FindPeopleConsole_Disposed);

            LLUUIDs = new Dictionary <string, UUID>();
            QueryID = queryID;

            this.instance = instance;
            netcom        = this.instance.Netcom;
            client        = this.instance.Client;

            // Callbacks
            client.Directory.DirPeopleReply += new EventHandler <DirPeopleReplyEventArgs>(Directory_DirPeopleReply);

            GUI.GuiHelpers.ApplyGuiFixes(this);
        }
Exemple #4
0
        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;
            AgentID       = agentID;

            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;

                txtWantTo.ReadOnly    = false;
                txtSkills.ReadOnly    = false;
                txtLanguages.ReadOnly = false;

                checkBoxBuild.Enabled            = true;
                checkBoxExplore.Enabled          = true;
                checkBoxMeet.Enabled             = true;
                checkBoxGroup.Enabled            = true;
                checkBoxBuy.Enabled              = true;
                checkBoxSell.Enabled             = true;
                checkBoxBeHired.Enabled          = true;
                checkBoxHire.Enabled             = true;
                checkBoxTextures.Enabled         = true;
                checkBoxArchitecture.Enabled     = true;
                checkBoxEventPlanning.Enabled    = true;
                checkBoxModeling.Enabled         = true;
                checkBoxScripting.Enabled        = true;
                checkBoxCustomCharacters.Enabled = true;
            }

            // Callbacks
            client.Avatars.AvatarPropertiesReply += new EventHandler <AvatarPropertiesReplyEventArgs>(Avatars_AvatarPropertiesReply);
            client.Avatars.AvatarPicksReply      += new EventHandler <AvatarPicksReplyEventArgs>(Avatars_AvatarPicksReply);
            //client.Avatars.AvatarClassifiedReply += new EventHandler<AvatarClassifiedReplyEventArgs>(Avatars_AvatarClassifiedsReply);
            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.Avatars.AvatarInterestsReply += new EventHandler <AvatarInterestsReplyEventArgs>(Avatars_AvatarInterestsReply);
            client.Avatars.AvatarNotesReply     += new EventHandler <AvatarNotesReplyEventArgs>(Avatars_AvatarNotesReply);
            client.Self.MuteListUpdated         += new EventHandler <EventArgs>(Self_MuteListUpdated);
            netcom.ClientDisconnected           += new EventHandler <DisconnectedEventArgs>(netcom_ClientDisconnected);
            instance.InventoryClipboardUpdated  += new EventHandler <EventArgs>(instance_InventoryClipboardUpdated);
            InitializeProfile();

            GUI.GuiHelpers.ApplyGuiFixes(this);
        }
        public void CleanUp()
        {
            MarkEndExecution();

            if (COF != null)
            {
                COF.Dispose();
                COF = null;
            }

            if (Names != null)
            {
                Names.Dispose();
                Names = null;
            }

            if (GridManger != null)
            {
                GridManger.Dispose();
                GridManger = 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);
        }