Skip to content

Commit 870807a

Browse files
njbrakehansonkim
andauthored
fix: stopped status would never return from that state (#324)
* fix: show C-p groups hint only when group field is focused The rename dialog bottom hint line showed "C-p groups" on all fields, but Ctrl+P only works on the group field (focused_field == 1). Add the same focused_field guard already used in handle_key and group_hint rendering so the hint matches the actual behavior. * stop status stuck --------- Co-authored-by: 김명주 <hanson@loplat.com>
1 parent c2ce2a5 commit 870807a

1 file changed

Lines changed: 8 additions & 2 deletions

File tree

src/tui/home/mod.rs

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -305,7 +305,10 @@ impl HomeView {
305305
if let Some(updates) = self.status_poller.try_recv_updates() {
306306
for update in updates {
307307
if let Some(inst) = self.instances.iter_mut().find(|i| i.id == update.id) {
308-
if inst.status != Status::Deleting && inst.status != Status::Stopped {
308+
if inst.status != Status::Deleting
309+
&& inst.status != Status::Stopped
310+
&& update.status != Status::Stopped
311+
{
309312
let old_status = inst.status;
310313
inst.status = update.status;
311314
inst.last_error = update.last_error.clone();
@@ -319,7 +322,10 @@ impl HomeView {
319322
}
320323
}
321324
if let Some(inst) = self.instance_map.get_mut(&update.id) {
322-
if inst.status != Status::Deleting && inst.status != Status::Stopped {
325+
if inst.status != Status::Deleting
326+
&& inst.status != Status::Stopped
327+
&& update.status != Status::Stopped
328+
{
323329
inst.status = update.status;
324330
inst.last_error = update.last_error;
325331
}

0 commit comments

Comments
 (0)