MCPcopy Create free account
hub / github.com/GCWing/BitFun / confirm_selection

Method confirm_selection

src/apps/cli/src/ui/provider_selector.rs:231–243  ·  view source on GitHub ↗
(&self)

Source from the content-addressed store, hash-verified

229 }
230
231 fn confirm_selection(&self) -> Option<ProviderSelection> {
232 if self.selectable_row_indices.is_empty() {
233 return None;
234 }
235 let row_idx = self.selectable_row_indices[self.selected];
236 match &self.rows[row_idx] {
237 DisplayRow::Provider(tmpl_idx) => Some(ProviderSelection::Provider(
238 self.templates[*tmpl_idx].clone(),
239 )),
240 DisplayRow::Custom => Some(ProviderSelection::Custom),
241 _ => None,
242 }
243 }
244
245 // ── Key handling ──
246

Callers 2

handle_key_eventMethod · 0.45
handle_mouse_eventMethod · 0.45

Calls 2

is_emptyMethod · 0.45
cloneMethod · 0.45

Tested by

no test coverage detected