private void ShowConversationDialog(Conversation conversation, ContactInfo contactInfo, ConversationType conversationType)
 {
     Dispatcher.BeginInvoke((Action)(() =>
     {
         var window = new ConversationWindow(conversation, this.lyncService.Client, contactInfo, conversationType);
         this.currentConversationWindow = window;
         window.ShowDialog();
     }));
 }
        private void LyncServiceConversationEnded(object sender, ConversationEventArgs e)
        {
            Dispatcher.BeginInvoke((Action)(() =>
            {
                if (this.currentConversationWindow != null && this.currentConversationWindow.IsLoaded)
                {
                    this.currentConversationWindow.Close();
                    MessageBox.Show("The other participant declined the conversation!");
                }
                else
                {
                    MessageBox.Show("Conversation ended!");
                }

                this.currentConversationWindow = null;
            }));
        }