| 135 | } |
| 136 | |
| 137 | void BatchMode::trigger_command() |
| 138 | { |
| 139 | sample_list = apps::get_samples(categories, tags); |
| 140 | |
| 141 | if (!skips.empty()) |
| 142 | { |
| 143 | std::vector<apps::AppInfo *> filtered_list; |
| 144 | filtered_list.reserve(sample_list.size() - skips.size()); |
| 145 | |
| 146 | std::copy_if( |
| 147 | sample_list.begin(), sample_list.end(), std::back_inserter(filtered_list), [&](const apps::AppInfo *app) { return !skips.count(app->id); }); |
| 148 | |
| 149 | if (filtered_list.size() != sample_list.size()) |
| 150 | { |
| 151 | sample_list.swap(filtered_list); |
| 152 | } |
| 153 | } |
| 154 | |
| 155 | if (sample_list.empty()) |
| 156 | { |
| 157 | LOGE("No samples found") |
| 158 | throw std::runtime_error{"Can not continue"}; |
| 159 | } |
| 160 | |
| 161 | sample_iter = sample_list.begin(); |
| 162 | |
| 163 | vkb::Window::OptionalProperties properties; |
| 164 | properties.resizable = false; |
| 165 | platform->set_window_properties(properties); |
| 166 | platform->disable_input_processing(); |
| 167 | platform->force_render(true); |
| 168 | request_app(); |
| 169 | } |
| 170 | |
| 171 | void BatchMode::on_update(float delta_time) |
| 172 | { |
nothing calls this directly
no test coverage detected