show progress in spinner when push/pull is ongoing

This commit is contained in:
Stephan Dilly 2021-03-01 14:35:37 +01:00
parent 49316baf86
commit 26d63a37a0
3 changed files with 13 additions and 0 deletions

View file

@ -329,6 +329,8 @@ impl App {
|| self.stashing_tab.anything_pending() || self.stashing_tab.anything_pending()
|| self.inspect_commit_popup.any_work_pending() || self.inspect_commit_popup.any_work_pending()
|| self.input.is_state_changing() || self.input.is_state_changing()
|| self.push_popup.any_work_pending()
|| self.fetch_popup.any_work_pending()
} }
/// ///

View file

@ -103,6 +103,11 @@ impl PullComponent {
Ok(()) Ok(())
} }
///
pub fn any_work_pending(&self) -> bool {
self.pending
}
/// ///
pub fn update_git( pub fn update_git(
&mut self, &mut self,

View file

@ -144,6 +144,12 @@ impl PushComponent {
Ok(()) Ok(())
} }
///
pub fn any_work_pending(&self) -> bool {
self.pending
}
///
pub fn get_progress( pub fn get_progress(
progress: &Option<RemoteProgress>, progress: &Option<RemoteProgress>,
) -> (String, u8) { ) -> (String, u8) {