| 200 | } |
| 201 | |
| 202 | void Window::ListAddColumn(const std::wstring& name, int index, int width) { |
| 203 | LVCOLUMN lvc; |
| 204 | lvc.mask = LVCF_FMT | LVCF_WIDTH | LVCF_TEXT | LVCF_SUBITEM; |
| 205 | lvc.fmt = LVCFMT_LEFT; |
| 206 | lvc.cx = width; |
| 207 | lvc.pszText = const_cast<wchar_t*>(name.c_str()); |
| 208 | lvc.iSubItem = index; |
| 209 | |
| 210 | if (ListView_InsertColumn(handle_, index, &lvc) == -1) { |
| 211 | std::stringstream buf; |
| 212 | buf << "Can not add list column, error code: " << GetLastError(); |
| 213 | throw DriverException(buf.str()); |
| 214 | } |
| 215 | } |
| 216 | |
| 217 | void Window::ListAddItem(const std::vector<std::wstring>& items) { |
| 218 | LVITEM lvi = {0}; |
no test coverage detected