private void msgSetButton_Click(object sender, RoutedEventArgs e)
        {
            InstanceAnswerPro.Core.Community.Community community = this.CurrentSessionTabItem.CommunitySession.Community;
            ItemCollection items = this.msgSetButton.DropDown.Items;

            Util_Group.SetMenuStatus(community, items);
        }
        private void MsgSet_Executed(object sender, ExecutedRoutedEventArgs args)
        {
            MenuItem    parameter = args.Parameter as MenuItem;
            MsgRecvType tag       = (MsgRecvType)parameter.Tag;

            Util_Group.SetMsgType(this.CurrentSessionTabItem.CommunitySession.Community, tag);
        }
 private void Grid_MouseLeftButtonUp(object sender, MouseButtonEventArgs e)
 {
     if ((sender == this.mail) && (this.CurrentSessionTabItem != null))
     {
         Util_Group.SendMail(this.CurrentSessionTabItem.CommunitySession.Community);
     }
 }
Пример #4
0
        /// <summary>
        /// 执行群组成员管理
        /// </summary>
        /// <param name="sender"></param>
        /// <param name="e"></param>
        private void CommunitymemberMgr_Executed(object sender, ExecutedRoutedEventArgs e)
        {
            DependencyObject originalSource = e.OriginalSource as DependencyObject;

            if (originalSource != null)
            {
                ListBox     ancestorByType = VisualTree.GetAncestorByType(originalSource, typeof(ListBox)) as ListBox;
                ListBoxItem container      = VisualTree.GetAncestorByType(originalSource, typeof(ListBoxItem)) as ListBoxItem;
                if ((ancestorByType != null) && (container != null))
                {
                    InstanceAnswerPro.Core.Community.Community community = ancestorByType.ItemContainerGenerator.ItemFromContainer(container) as InstanceAnswerPro.Core.Community.Community;
                    if ((community != null) && Util_Group.IsManager(community, Util_Buddy.GetCurrentBuddy().Uin))
                    {
                        Util_Group.OpenCommunityInfoWindow(community, Util_Group.CommunityInfoWindowPageTag.PageMemberInfo);
                    }
                }
            }
        }
Пример #5
0
        private void CreateCommunitySessionWindow(uint communityID, object parameter)
        {
            List <InstanceAnswerPro.Core.Message> list = Util_Group.PopMessages(communityID);
            CommunitySession       communitySession    = this._communitySessionManager.GetCommunitySession(communityID, true);
            CommunitySessionWindow window = new CommunitySessionWindow(communitySession);

            foreach (InstanceAnswerPro.Core.Message message in list)
            {
                window.ReceiveMessage(communitySession, message);
            }
            Util_Buddy.BuddySessionParameter parameter2 = parameter as Util_Buddy.BuddySessionParameter;
            if (parameter2 != null)
            {
                window.Left = parameter2.WindowPosition.X;
                window.Top  = parameter2.WindowPosition.Y;
            }
            window.Show();
            window.Activate();
        }
 private void SearchCommunity_Executed(object sender, ExecutedRoutedEventArgs args)
 {
     Util_Group.SearchCommunity();
 }
 private void CreateCommunity_Executed(object sender, ExecutedRoutedEventArgs args)
 {
     Util_Group.CreateCommunity();
 }