return true if prompt is confirmed
| 3129 | |
| 3130 | // return true if prompt is confirmed |
| 3131 | bool Query::confirm(const char *prompt) |
| 3132 | { |
| 3133 | if (!flag_confirm) |
| 3134 | return true; |
| 3135 | |
| 3136 | message(std::string(prompt).append("? (y/n) [n] ")); |
| 3137 | |
| 3138 | VKey::flush(); |
| 3139 | |
| 3140 | int key = VKey::get(); |
| 3141 | |
| 3142 | if (key == 'y' || key == 'Y') |
| 3143 | return true; |
| 3144 | |
| 3145 | message_ = false; |
| 3146 | draw(); |
| 3147 | |
| 3148 | return false; |
| 3149 | } |
| 3150 | |
| 3151 | // display help page |
| 3152 | bool Query::help() |
nothing calls this directly
no outgoing calls
no test coverage detected