Skip to content

Commit 987d8bc

Browse files
committed
[WARP] Fix container list not refreshing for dynamically added containers
When running the command "WARP\\Load File" it will create a new container and add it to the global container list, we need to show this in the UI
1 parent 51d50c7 commit 987d8bc

File tree

2 files changed

+2
-5
lines changed

2 files changed

+2
-5
lines changed

plugins/warp/ui/containers.h

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -149,7 +149,7 @@ class WarpContainersPane : public QWidget
149149
{
150150
// Retrieve all available containers
151151
const auto all = Warp::Container::All();
152-
m_containers = all; // copy vector<Ref<Container>>
152+
m_containers = all;
153153

154154
for (const auto& c : m_containers)
155155
{
@@ -159,10 +159,6 @@ class WarpContainersPane : public QWidget
159159
auto* widget = new WarpContainerWidget(c, m_stack);
160160
m_stack->addWidget(widget);
161161
}
162-
163-
// Visual style: behave like a vertical tab bar
164-
// m_list->setFrameShape(QFrame::NoFrame);
165-
// m_list->setSpacing(0);
166162
}
167163

168164
static int itemHeightPx()

plugins/warp/ui/plugin.cpp

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -194,6 +194,7 @@ void WarpSidebarWidget::Update()
194194
{
195195
m_currentFunctionWidget->UpdateMatches();
196196
m_matchedWidget->Update();
197+
m_containerWidget->refresh();
197198
// TODO: Obviously this probably should not be called here.
198199
setMatcherActionIcon(false);
199200
}

0 commit comments

Comments
 (0)