reapack

Package manager for REAPER
Log | Files | Refs | Submodules | README | LICENSE

commit 87e8122e85a8543d6bee8220cc034718b8b80958
parent 9132e9bb76da25847bc692ddebc02137c55fdd37
Author: cfillion <cfillion@users.noreply.github.com>
Date:   Fri, 18 Dec 2020 14:27:46 -0500

about: add an option to browse packages in the repository's install/update menu

Diffstat:
Msrc/about.cpp | 13++++++++++++-
1 file changed, 12 insertions(+), 1 deletion(-)

diff --git a/src/about.cpp b/src/about.cpp @@ -454,10 +454,11 @@ void AboutIndexDelegate::itemCopy() void AboutIndexDelegate::install() { - enum { INSTALL_ALL = 80, UPDATE_ONLY }; + enum { INSTALL_ALL = 80, UPDATE_ONLY, OPEN_BROWSER }; Menu menu; menu.addAction("Install all packages in this repository", INSTALL_ALL); + menu.addAction("Install individual packages in this repository", OPEN_BROWSER); menu.addAction("Update installed packages only", UPDATE_ONLY); const int choice = menu.show(m_dialog->getControl(IDC_ACTION), m_dialog->handle()); @@ -475,6 +476,16 @@ void AboutIndexDelegate::install() return; } + if(choice == OPEN_BROWSER) { + if(Browser *browser = g_reapack->browsePackages()) { + std::ostringstream stream; + stream << '^' << quoted(m_index->name()) << '$'; + browser->setFilter(stream.str()); + } + + return; + } + const InstallOpts &installOpts = g_reapack->config()->install; if(choice == INSTALL_ALL && boost::logic::indeterminate(remote.autoInstall())