コード例 #1
0
ファイル: ChatWindow.cs プロジェクト: vaginessa/WinApp.NET
 public void DoDispose()
 {
     if (this.InvokeRequired)
     {
         ParentDelegate f = new ParentDelegate(DoDispose);
         this.Invoke(f);
     }
     else
     {
         this.Dispose();
     }
 }
コード例 #2
0
ファイル: ChatWindow.cs プロジェクト: vaginessa/WinApp.NET
 protected void ScrollToBottom()
 {
     if (this.InvokeRequired)
     {
         ParentDelegate p = new ParentDelegate(ScrollToBottom);
         this.Invoke(p);
     }
     else
     {
         this.flowLayoutPanel1.VerticalScroll.Value = this.flowLayoutPanel1.VerticalScroll.Maximum;
     }
     //int visibleItems = this.listBox1.ClientSize.Height / this.listBox1.ItemHeight;
     //this.listBox1.TopIndex = Math.Max(this.listBox1.Items.Count - visibleItems + 1, 0);
 }
コード例 #3
0
ファイル: ChatWindow.cs プロジェクト: vaginessa/WinApp.NET
        public void DoActivate()
        {
            if (this.InvokeRequired)
            {
                ParentDelegate f = new ParentDelegate(DoActivate);
                this.Invoke(f);
            }
            else
            {
                //this.Show();
                bool focused = (this == Form.ActiveForm);

                if (this.sp != null && this.sp.IsLoadCompleted && !focused)
                {
                    this.sp.Play();
                }
                FlashWindow(this.Handle, true);
            }
        }
コード例 #4
0
ファイル: ChatWindow.cs プロジェクト: JeremyManz/WinApp.NET
        public void DoDispose()
        {
            if (this.InvokeRequired)
            {
                ParentDelegate f = new ParentDelegate(DoDispose);
                this.Invoke(f);
            }
            else
            {
                this.Dispose();
            }

        }
コード例 #5
0
ファイル: ChatWindow.cs プロジェクト: JeremyManz/WinApp.NET
 protected void ScrollToBottom()
 {
     if (this.InvokeRequired)
     {
         ParentDelegate p = new ParentDelegate(ScrollToBottom);
         this.Invoke(p);
     }
     else
     {
         this.flowLayoutPanel1.VerticalScroll.Value = this.flowLayoutPanel1.VerticalScroll.Maximum;
     }
     //int visibleItems = this.listBox1.ClientSize.Height / this.listBox1.ItemHeight;
     //this.listBox1.TopIndex = Math.Max(this.listBox1.Items.Count - visibleItems + 1, 0);
 }
コード例 #6
0
ファイル: ChatWindow.cs プロジェクト: JeremyManz/WinApp.NET
        public void DoActivate()
        {
            if (this.InvokeRequired)
            {
                ParentDelegate f = new ParentDelegate(DoActivate);
                this.Invoke(f);
            }
            else
            {
                //this.Show();
                bool focused = (this == Form.ActiveForm);

                if (this.sp != null && this.sp.IsLoadCompleted && !focused)
                { 
                    this.sp.Play(); 
                }
                FlashWindow(this.Handle, true);
            }
        }
コード例 #7
0
ファイル: ChatWindow.cs プロジェクト: GarethWright/WinApp.NET
 public void DoActivate()
 {
     if (this.InvokeRequired)
     {
         ParentDelegate f = new ParentDelegate(DoActivate);
         this.Invoke(f);
     }
     else
     {
         FlashWindow(this.Handle, true);
     }
 }