MCPcopy Create free account
hub / github.com/audacity/audacity / SelectPageByName

Method SelectPageByName

src/prefs/PrefsDialog.cpp:790–807  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

788}
789
790void PrefsDialog::SelectPageByName(const wxString &pageName)
791{
792 if (mCategories) {
793 size_t n = mCategories->GetPageCount();
794
795 for (size_t i = 0; i < n; i++) {
796 if (mCategories->GetPageText(i) == pageName) {
797 mCategories->SetSelection(i);
798 // This covers the case, when ShowModal is called
799 // after selecting the page.
800 // ShowModal will select the page previously used by
801 // user
802 SavePreferredPage();
803 return;
804 }
805 }
806 }
807}
808
809int PrefsDialog::GetSelectedPage() const
810{

Callers 3

UpdateNoticeDialogMethod · 0.80

Calls 1

SetSelectionMethod · 0.45

Tested by

no test coverage detected