Form in which the user can configure search parameters. This dialog performs the search itself and returns the result in the SearchResultsGroup property.
Inheritance: System.Windows.Forms.Form, IGwmWindow
コード例 #1
0
ファイル: MainForm.cs プロジェクト: amiryal/keepass2
        private void OnGroupsFind(object sender, EventArgs e)
        {
            PwGroup pg = GetSelectedGroup();
            Debug.Assert(pg != null); if(pg == null) return;

            SearchForm sf = new SearchForm();
            sf.InitEx(m_docMgr.ActiveDatabase, pg);

            if(sf.ShowDialog() == DialogResult.OK)
            {
                PwGroup pgResults = sf.SearchResultsGroup;
                UpdateEntryList(pgResults, false);
                UpdateUIState(false);
                ShowSearchResultsStatusMessage();
            }
            UIUtil.DestroyForm(sf);
        }
コード例 #2
0
ファイル: MainForm.cs プロジェクト: amiryal/keepass2
        private void OnPwListFind(object sender, EventArgs e)
        {
            SearchForm sf = new SearchForm();

            sf.InitEx(m_docMgr.ActiveDatabase, m_docMgr.ActiveDatabase.RootGroup);
            if(sf.ShowDialog() == DialogResult.OK)
            {
                PwGroup pg = sf.SearchResultsGroup;

                UpdateEntryList(pg, false);
                SelectFirstEntryIfNoneSelected();

                UpdateUIState(false);
                ShowSearchResultsStatusMessage();

                ResetDefaultFocus(m_lvEntries);
            }
            UIUtil.DestroyForm(sf);
        }
コード例 #3
0
ファイル: MainForm.cs プロジェクト: rdealexb/keepass
        private void OnPwListFind(object sender, EventArgs e)
        {
            PwDatabase pd = m_docMgr.ActiveDatabase;
            if(!pd.IsOpen) return;
            PwGroup pgRoot = pd.RootGroup;
            if(pgRoot == null) { Debug.Assert(false); return; }

            SearchForm sf = new SearchForm();
            sf.InitEx(pd, pgRoot);

            if(sf.ShowDialog() == DialogResult.OK)
            {
                PwGroup pg = sf.SearchResultsGroup;

                UpdateEntryList(pg, false);
                SelectFirstEntryIfNoneSelected();

                UpdateUIState(false);
                ShowSearchResultsStatusMessage(pgRoot);

                ResetDefaultFocus(m_lvEntries);
            }
            UIUtil.DestroyForm(sf);
        }