MCPcopy Create free account
hub / github.com/ChrisFeldmeier/OpenCodeRust / new

Method new

crates/opencode-tui/src/components/dialogs/confirm.rs:21–30  ·  view source on GitHub ↗
(title: &str, message: &str)

Source from the content-addressed store, hash-verified

19
20impl ConfirmDialog {
21 pub fn new(title: &str, message: &str) -> Self {
22 Self {
23 title: title.to_string(),
24 message: message.to_string(),
25 confirm_text: "Confirm".to_string(),
26 cancel_text: "Cancel".to_string(),
27 focused: false,
28 open: false,
29 }
30 }
31
32 pub fn open(&mut self) {
33 self.open = true;

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected