Esempio n. 1
0
 public static void AddForm(MemoForm form)
 {
     lock (lockObject)
     {
         formTable.Add(form);
     }
 }
Esempio n. 2
0
        private void delNRmemo(int rowIndex)
        {
            try
            {
                NumberedMemoObj obj = (NumberedMemoObj)dgv_memo.Rows[rowIndex].Tag;
                //쪽지 보여줌
                MemoForm memoForm = new MemoForm(connection, obj.ToMemoObj());
                memoForm.Show();
                memoForm.Activate();

                //확인한 쪽지를 미확인목록에서 삭제
                MemoUtils.MemoFileWrite(ConfigHelper.Id, obj.ToMemoObj());
                dgv_memo.Rows.RemoveAt(rowIndex);
                connection.SendMsgDeleteUnReadOnChecked(obj.SeqNum);

                memoCnt = memoCnt - 1;
                if (memoCnt >= 0)
                {
                    if (memoCnt == 0)
                    {
                        panel_memo.Enabled = false;
                    }
                    label_memo.Text = "부재중 메모(" + memoCnt + ")";
                    connection.UpdateUnCheckedData(memoCnt, -1, -1, -1);
                }
            }
            catch (Exception ex)
            {
                Logger.error(ex.ToString());
            }
        }
Esempio n. 3
0
 private void CreateMemoFormOnMemoMsgReceived(object sender, CustomEventArgs e)
 {
     try
     {
         MemoObj  memoObj  = (MemoObj)e.GetItem;
         MemoForm memoForm = new MemoForm(connection, memoObj);
         memoForm.Show();
         memoForm.Activate();
     }
     catch (Exception ex)
     {
         Logger.error(ex.ToString());
     }
 }
Esempio n. 4
0
 private void CreateMemoFormOnMemoMsgReceived(object sender, CustomEventArgs e)
 {
     try
     {
         MemoObj memoObj = (MemoObj)e.GetItem;
         MemoForm memoForm = new MemoForm(connection, memoObj);
         memoForm.Show();
         memoForm.Activate();
     }
     catch (Exception ex)
     {
         Logger.error(ex.ToString());
     }
 }
Esempio n. 5
0
        private void listView_SelectedIndexChanged(object sender, EventArgs e)
        {
            try
            {
                if (listView.SelectedItems.Count != 0)
                {
                    MemoForm memoForm = new MemoForm(connection, (MemoObj)listView.SelectedItems[0].Tag);
                    memoForm.Show();
                    memoForm.Activate();

                    listView.SelectedItems[0].Selected = false;
                }
            }
            catch (Exception exception)
            {
                Logger.error(exception.ToString());
            }
        }
        private void delNRmemo(int rowIndex)
        {
            try
            {
                NumberedMemoObj obj = (NumberedMemoObj)dgv_memo.Rows[rowIndex].Tag;
                //쪽지 보여줌
                MemoForm memoForm = new MemoForm(connection, obj.ToMemoObj());
                memoForm.Show();
                memoForm.Activate();

                //확인한 쪽지를 미확인목록에서 삭제
                MemoUtils.MemoFileWrite(ConfigHelper.Id, obj.ToMemoObj());
                dgv_memo.Rows.RemoveAt(rowIndex);
                connection.SendMsgDeleteUnReadOnChecked(obj.SeqNum);

                memoCnt = memoCnt - 1;
                if (memoCnt >= 0)
                {
                    if (memoCnt == 0)
                        panel_memo.Enabled = false;
                    label_memo.Text = "부재중 메모(" + memoCnt + ")";
                    connection.UpdateUnCheckedData(memoCnt, -1, -1, -1);
                }
            }
            catch (Exception ex)
            {
                Logger.error(ex.ToString());
            }
        }
Esempio n. 7
0
 private void MakeMemo(string[] tempMemo) {//tempMemo(m|name|id|message)
 
     try {
     
         MemoForm memoForm = new MemoForm();
         //memoForm.Text = tempMemo[1] + "님의 쪽지";
         ////memoForm.MemoCont.Text = tempMemo[3];  
         //memoForm.MemoCont.Lines = tempMemo[3].Split(new string[] {Environment.NewLine}, StringSplitOptions.None); //줄바꿈 지원 2012.9.1
         //memoForm.senderid.Text = tempMemo[2];
         memoForm.setMemoInfo(tempMemo[2], tempMemo[1], tempMemo[3]);
         memoForm.MemoReplyDone += MemoReplyDone;
         memoForm.Show();
         memoForm.Activate();
         MemoTable.Add(memoForm);
     } catch (Exception e) {
         logWrite(e.ToString());
     }
 }
Esempio n. 8
0
        private void listView_SelectedIndexChanged(object sender, EventArgs e)
        {
            try
            {
                if (listView.SelectedItems.Count != 0)
                {
                    MemoForm memoForm = new MemoForm(connection, (MemoObj)listView.SelectedItems[0].Tag);
                    memoForm.Show();
                    memoForm.Activate();

                    listView.SelectedItems[0].Selected = false;
                }
            }
            catch (Exception exception)
            {
                Logger.error(exception.ToString());
            }
        }
Esempio n. 9
0
 //tempMemo(m|name|id|message)
 private void MakeMemo(string[] tempMemo)
 {
     try
     {
         MemoForm memoForm = new MemoForm();
         memoForm.Text = tempMemo[1] + "���� ����";
         //memoForm.MemoCont.Text = tempMemo[3];
         memoForm.MemoCont.Lines = tempMemo[3].Split(new string[] {Environment.NewLine}, StringSplitOptions.None); //�ٹٲ� ���� 2012.9.1
         memoForm.senderid.Text = tempMemo[2];
         memoForm.MemoRe.KeyUp += new KeyEventHandler(SendMemo);
         memoForm.Memobtn.MouseClick += new MouseEventHandler(Memobtn_Click);
         memoForm.Show(memolistform);
         memoForm.Activate();
         memoForm.TopMost = true;
         memoForm.MemoRe.Focus();
         MemoTable.Add(memoForm);
     }
     catch (Exception e)
     {
         logWrite(e.ToString());
     }
 }