コード例 #1
0
ファイル: SearchWeakForm.cs プロジェクト: mattlorimor/Bimil
        private void lsvEntries_ItemActivate(object sender, System.EventArgs e)
        {
            if ((this.Document == null) || (lsvEntries.SelectedItems.Count != 1))
            {
                return;
            }

            var entry = (Entry)(lsvEntries.SelectedItems[0].Tag);

            using (var frm = new ItemForm(this.Document, entry, this.Categories, startsAsEditable: Settings.EditableByDefault, hideAutotype: true)) {
                frm.ShowDialog(this);
            }
        }
コード例 #2
0
        private void lsvEntries_ItemActivate(object sender, EventArgs e)
        {
            if ((this.Document == null) || (lsvEntries.SelectedItems.Count != 1))
            {
                return;
            }

            var item = (Entry)(lsvEntries.SelectedItems[0].Tag);

            using (var frm2 = new ItemForm(this.Document, item, this.Categories, startsAsEditable: Settings.EditableByDefault, hideAutotype: true)) {
                if (frm2.ShowDialog(this) == DialogResult.OK)
                {
                    Helpers.PerformEntrySearch(this.Document, lsvEntries, cmbSearch.Text, entriesToSelect: new Entry[] { item }, extendedSearch: true, addMatchDescription: true);
                    Form_Resize(null, null); //to support both ListView full row with and without scrollbar
                }
            }
        }