当前位置: 首页>>代码示例>>C#>>正文


C# OpenMetaverse.DisconnectedEventArgs类代码示例

本文整理汇总了C#中OpenMetaverse.DisconnectedEventArgs的典型用法代码示例。如果您正苦于以下问题:C# DisconnectedEventArgs类的具体用法?C# DisconnectedEventArgs怎么用?C# DisconnectedEventArgs使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。


DisconnectedEventArgs类属于OpenMetaverse命名空间,在下文中一共展示了DisconnectedEventArgs类的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。

示例1: DisconnectHandler

 public static void DisconnectHandler(object sender, DisconnectedEventArgs e)
 {
     if (e.Reason == NetworkManager.DisconnectType.NetworkTimeout)
     {
         Console.WriteLine("Network connection timed out, disconnected");
     }
     else if (e.Reason == NetworkManager.DisconnectType.ServerInitiated)
     {
         Console.WriteLine("Server disconnected us: " + e.Message);
     }
 }
开发者ID:TooheyPaneer,项目名称:libopenmetaverse,代码行数:11,代码来源:PacketDump.cs

示例2: netcom_ClientDisconnected

 private void netcom_ClientDisconnected(object sender, DisconnectedEventArgs e)
 {
     this.Close();
 }
开发者ID:NullProjects,项目名称:METAbolt,代码行数:4,代码来源:Teleport.cs

示例3: Network_OnDisconnected

 private void Network_OnDisconnected(object sender, DisconnectedEventArgs e)
 {
     // Null out the cached fullName since it can change after logging
     // in again (with a different account name or different login
     // server but using the same GridClient object
     fullName = null;
 }
开发者ID:RavenB,项目名称:gridsearch,代码行数:7,代码来源:AgentManager.cs

示例4: netcom_ClientDisconnected

 void netcom_ClientDisconnected(object sender, DisconnectedEventArgs e)
 {
     if (InvokeRequired)
     {
         BeginInvoke(new MethodInvoker(Close));
     }
     else
     {
         Close();
     }
 }
开发者ID:TooheyPaneer,项目名称:radegast,代码行数:11,代码来源:Profile.cs

示例5: Network_OnDisconnected

        private void Network_OnDisconnected(object sender, DisconnectedEventArgs e)
        {
            if (RebakeScheduleTimer != null)
            {
                RebakeScheduleTimer.Dispose();
                RebakeScheduleTimer = null;
            }

            if (AppearanceThread != null)
            {
                if (AppearanceThread.IsAlive)
                {
                    AppearanceThread.Abort();
                }
                AppearanceThread = null;
                AppearanceThreadRunning = 0;
            }
        }
开发者ID:CCIR,项目名称:libopenmetaverse,代码行数:18,代码来源:AppearanceManager.cs

示例6: Netcom_Disconnected

 void Netcom_Disconnected(object sender, DisconnectedEventArgs e)
 {
     RefreshControls();
 }
开发者ID:RevolutionSmythe,项目名称:radegast,代码行数:4,代码来源:GroupIMTabWindow.cs

示例7: OnClientDisconnected

 protected virtual void OnClientDisconnected(DisconnectedEventArgs e)
 {
     if (ClientDisconnected != null) ClientDisconnected(this, e);
 }
开发者ID:Booser,项目名称:radegast,代码行数:4,代码来源:NetComEvents.cs

示例8: netcom_ClientDisconnected

 private void netcom_ClientDisconnected(object sender, DisconnectedEventArgs e)
 {
     RefreshControls();
 }
开发者ID:NullProjects,项目名称:METAbolt,代码行数:4,代码来源:IMTabWindow.cs

示例9: Network_OnDisconnected

        public void Network_OnDisconnected(object sender, DisconnectedEventArgs args)
        {
//            m_log.ErrorFormat("Fired Network_OnDisconnected");

//           if (
//               (args.Reason == NetworkManager.DisconnectType.SimShutdown
//                    || args.Reason == NetworkManager.DisconnectType.NetworkTimeout)
//               && OnDisconnected != null)

           if (
               (args.Reason == NetworkManager.DisconnectType.ClientInitiated
                    || args.Reason == NetworkManager.DisconnectType.ServerInitiated
                    || args.Reason == NetworkManager.DisconnectType.NetworkTimeout)
               && OnDisconnected != null)
//            if (OnDisconnected != null)
            {
                IsConnected = false;
                OnDisconnected(this, EventType.DISCONNECTED);
            }
        }
开发者ID:4U2NV,项目名称:opensim,代码行数:20,代码来源:Bot.cs

示例10: Netcom_ClientDisconnected

 void Netcom_ClientDisconnected(object sender, DisconnectedEventArgs e)
 {
     ParcelsDownloaded.Set();
 }
开发者ID:RevolutionSmythe,项目名称:radegast,代码行数:4,代码来源:ParcelInfoCommand.cs

示例11: Network_Disconnected

        void Network_Disconnected(object sender, DisconnectedEventArgs e)
        {
            Logger.Log("*** BONED WE HAVE BEEN BOOTED ***", Helpers.LogLevel.Error);
            Logger.Log(e.Message, Helpers.LogLevel.Error);
            Logger.Log(e.Reason, Helpers.LogLevel.Error);

            if (connected == true)
            {
                connected = false;
                client.Network.Logout(); //force logout to clean up libomv
            }
        }
开发者ID:RavenB,项目名称:gridsearch,代码行数:12,代码来源:GridConn.cs

示例12: Netcom_ClientDisconnected

        void Netcom_ClientDisconnected(object sender, DisconnectedEventArgs e)
        {
            if (InvokeRequired)
            {
                if (!instance.MonoRuntime || IsHandleCreated)
                {
                    BeginInvoke(new MethodInvoker(() => Netcom_ClientDisconnected(sender, e)));
                }
                return;
            }

            if (UploadThread != null && UploadThread.IsAlive)
            {
                try
                {
                    UploadThread.Abort();
                }
                catch { }
                UploadThread = null;
                Running = false;
            }

            UpdateButtons();
        }
开发者ID:nooperation,项目名称:radegast,代码行数:24,代码来源:MeshUploadConsole.cs

示例13: Netcom_ClientDisconnected

        void Netcom_ClientDisconnected(object sender, DisconnectedEventArgs e)
        {
            if (InvokeRequired)
            {
                if (!instance.MonoRuntime || IsHandleCreated)
                {
                    BeginInvoke(new MethodInvoker(() => Netcom_ClientDisconnected(sender, e)));
                }
                return;
            }

            if (instance.TabConsole.TabExists("objects"))
            {
                instance.TabConsole.Tabs["objects"].Close();
            }
        }
开发者ID:RevolutionSmythe,项目名称:radegast,代码行数:16,代码来源:ObjectsConsole.cs

示例14: Network_OnDisconnected

        // EVENT CALLBACK SECTION
        void Network_OnDisconnected(object sender, DisconnectedEventArgs e)
        {
            var message = e.Message;
            var reason = e.Reason;
            try
            {
                if (message.Length > 0)
                    WriteLine("Disconnected from server. Reason is " + message + ". " + reason);
                else
                    WriteLine("Disconnected from server. " + reason);

                SendNetworkEvent("On-Network-Disconnected", reason, message);
            }
            catch (Exception ex)
            {
                LogException("Network_OnDisconnected", ex);
            }
            EnsureConnectedCheck(reason);
        }
开发者ID:drzo,项目名称:opensim4opencog,代码行数:20,代码来源:BotConnection.cs

示例15: Network_Disconnected

 public void Network_Disconnected(object sender, DisconnectedEventArgs e)
 {
     Hashtable item = new Hashtable();
     item.Add("MessageType", "Disconnected");
     item.Add("Reason", e.Reason);
     item.Add("Message", e.Message);
     enqueue(item);
 }
开发者ID:AlphaStaxLLC,项目名称:AjaxLife,代码行数:8,代码来源:Events.cs


注:本文中的OpenMetaverse.DisconnectedEventArgs类示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。