MCPcopy Create free account
hub / github.com/devnullvoid/pvetui / ShowActiveProfile

Method ShowActiveProfile

internal/ui/components/header.go:161–172  ·  view source on GitHub ↗

ShowActiveProfile displays the active profile in the header.

(profileName string)

Source from the content-addressed store, hash-verified

159
160// ShowActiveProfile displays the active profile in the header.
161func (h *Header) ShowActiveProfile(profileName string) {
162 h.mu.Lock()
163 h.isLoading = false
164 if h.loadingCancel != nil {
165 h.loadingCancel()
166 h.loadingCancel = nil
167 }
168 h.mu.Unlock()
169 h.StopLoading()
170 h.currentProfile = profileName // Store the profile name
171 h.SetText(h.formatProfileText(profileName))
172}
173
174// GetCurrentProfile returns the currently connected profile name.
175func (h *Header) GetCurrentProfile() string {

Callers

nothing calls this directly

Calls 3

StopLoadingMethod · 0.95
SetTextMethod · 0.95
formatProfileTextMethod · 0.95

Tested by

no test coverage detected