StopLoading stops the loading animation.
()
| 79 | |
| 80 | // StopLoading stops the loading animation. |
| 81 | func (h *Header) StopLoading() { |
| 82 | h.mu.Lock() |
| 83 | if !h.isLoading { |
| 84 | h.mu.Unlock() |
| 85 | return |
| 86 | } |
| 87 | h.isLoading = false |
| 88 | if h.loadingCancel != nil { |
| 89 | h.loadingCancel() |
| 90 | h.loadingCancel = nil |
| 91 | } |
| 92 | h.mu.Unlock() |
| 93 | } |
| 94 | |
| 95 | // IsLoading reports whether the header is currently showing a loading state. |
| 96 | func (h *Header) IsLoading() bool { |
no outgoing calls
no test coverage detected