| 126 | } |
| 127 | |
| 128 | void StPlugins::RefreshListWidget() { |
| 129 | if (!stream_list_) { |
| 130 | return; |
| 131 | } |
| 132 | context_->PostUITask([=, this]() { |
| 133 | auto index = 0; |
| 134 | int count = stream_list_->count(); |
| 135 | for (int i = 0; i < count; i++) { |
| 136 | auto item = stream_list_->takeItem(0); |
| 137 | delete item; |
| 138 | } |
| 139 | |
| 140 | for (const auto& item_info : items_info_) { |
| 141 | AddItem(item_info, index++); |
| 142 | } |
| 143 | }); |
| 144 | } |
| 145 | |
| 146 | void StPlugins::UpdateItemStatus() { |
| 147 | if (stream_list_->count() != items_info_.size()) { |
nothing calls this directly
no test coverage detected