Add version() to each plugin
And display it in the screensaver tool with the -l option.
This commit is contained in:
1 parent
37b17704f3
commit
bb03204f1c
6 files changed
+28
-2
No files matched your search
+3
-2
@@ -41,8 +41,9 @@ void print_help() {
|
||||
}
|
||||
|
||||
void list_plugins() {
|
||||
for (const std::string& name : sc::plugin<ScreensaverPlugin>::names()) {
|
||||
std::cout << name << '\n';
|
||||
for (const auto& elem : sc::plugin<ScreensaverPlugin>::all()) {
|
||||
|
||||
std::cout << elem.first << " (" << elem.second()->version() << ")\n";
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in new issue
Block a user