| 7 | #include "../../helpers/win_center_text/win_center_text.h" |
| 8 | |
| 9 | BoardScreen::BoardScreen(string board_name, DataManager *data_manager, |
| 10 | Config *config, bool from_tui) |
| 11 | : height{getmaxy(stdscr) - 4}, width{getmaxx(stdscr) - 2}, start_y{2}, |
| 12 | start_x{1}, columns_window{this->height, |
| 13 | this->width, |
| 14 | this->start_y, |
| 15 | this->start_x, |
| 16 | &this->columns, |
| 17 | &this->columns_count, |
| 18 | bind(&BoardScreen::draw_columns, this, |
| 19 | placeholders::_1, placeholders::_2), |
| 20 | 3} { |
| 21 | this->window = |
| 22 | newwin(this->height, this->width, this->start_y, this->start_x); |
| 23 | keypad(this->window, true); |
| 24 | refresh(); |
| 25 | |
| 26 | this->data_manager = data_manager; |
| 27 | this->config = config; |
| 28 | this->board = this->data_manager->get_board_if_exists(board_name); |
| 29 | |
| 30 | this->setup_columns(); |
| 31 | this->focused_index = 0; |
| 32 | |
| 33 | this->from_tui = from_tui; |
| 34 | } |
| 35 | |
| 36 | void BoardScreen::setup_columns() { |
| 37 | this->columns = {}; |
nothing calls this directly
no test coverage detected