コード例 #1
0
ファイル: ListForm.cs プロジェクト: Bulletz4mysa/NBTrade
        private void ListForm_KeyDown(object sender, KeyEventArgs e)
        {
            Keys keys1 = e.KeyCode;

            if (keys1 != Keys.Escape)
            {
                switch (keys1)
                {
                case Keys.Add:
                {
                    if (this.dgList.Font.Size < 15f)
                    {
                        this.dgList.Font = new Font(this.dgList.Font.FontFamily, this.dgList.Font.Size + 1f);
                    }
                    return;
                }

                case Keys.Separator:
                {
                    return;
                }

                case Keys.Subtract:
                {
                    if (this.dgList.Font.Size > 7f)
                    {
                        this.dgList.Font = new Font(this.dgList.Font.FontFamily, this.dgList.Font.Size - 1f);
                    }
                    return;
                }
                }
            }
            else if (this.FolderId != 0)
            {
                this.FolderId   = 0;
                this.FolderName = StockDB.LookupFolderName(this.FolderId);
            }
        }