feat: Added ports section, closes #21

This commit is contained in:
Jack Wills
2024-01-18 00:25:09 +00:00
parent b6fd35022a
commit 65a1afcb06
8 changed files with 518 additions and 61 deletions
+1 -1
View File
@@ -14,6 +14,6 @@ pub enum DockerMessage {
Restart(ContainerId),
Start(ContainerId),
Stop(ContainerId),
Unpause(ContainerId),
Resume(ContainerId),
Update,
}
+2 -2
View File
@@ -387,11 +387,11 @@ impl DockerData {
});
self.update_everything().await;
}
DockerMessage::Unpause(id) => {
DockerMessage::Resume(id) => {
tokio::spawn(async move {
let handle = GuiState::start_loading_animation(&gui_state, uuid);
if docker.unpause_container(id.get()).await.is_err() {
Self::set_error(&app_data, DockerControls::Unpause, &gui_state);
Self::set_error(&app_data, DockerControls::Resume, &gui_state);
}
gui_state.lock().stop_loading_animation(&handle, uuid);
});