diff options
| author | Jeff Carr <[email protected]> | 2024-02-19 14:42:59 -0600 |
|---|---|---|
| committer | Jeff Carr <[email protected]> | 2024-02-19 14:42:59 -0600 |
| commit | ad21d5d5db43b975e88067ff730691e89e10ea97 (patch) | |
| tree | 6df12661892c57d20130cb85a8380ff63bda4ad6 /common.go | |
| parent | be73f6af0ea749ba87f301b85e60a4b95f1b8038 (diff) | |
experiment with widget 'mirror'
Diffstat (limited to 'common.go')
| -rw-r--r-- | common.go | 36 |
1 files changed, 19 insertions, 17 deletions
@@ -3,6 +3,7 @@ package repostatus import ( "strings" + "go.wit.com/gui" "go.wit.com/log" // "go.wit.com/gui/gui" ) @@ -41,7 +42,7 @@ func (rs *RepoStatus) GoName() string { // not sure which name is easier to remember. probably this one func (rs *RepoStatus) GoPath() string { - return rs.goSrcPath.String() + return rs.goPath.String() } // returns the filesystem path to the repo @@ -49,22 +50,6 @@ func (rs *RepoStatus) Path() string { return rs.realPath.String() } -/* -func (rs *RepoStatus) GetPath() string { - return rs.path.String() -} -*/ - -/* -func (rs *RepoStatus) Draw() { - if !rs.Ready() { - return - } - log.Log(CHANGE, "Draw() window ready =", rs.ready) - rs.window.TestDraw() -} -*/ - func (rs *RepoStatus) Show() { if !rs.Ready() { return @@ -190,3 +175,20 @@ func (rs *RepoStatus) SetTargetVersion(s string) { // func (rs *RepoStatus) setTag() bool { rs.targetReleaseVersion.SetText(s) } + +// returns a widget of the last tag that acts as a mirror +func (rs *RepoStatus) MirrorLastTag() *gui.Node { + return rs.lasttag.MirrorValue() +} + +func (rs *RepoStatus) MirrorTargetVersion() *gui.Node { + return rs.targetReleaseVersion.MirrorValue() +} + +func (rs *RepoStatus) MirrorCurrentVersion() *gui.Node { + return rs.currentVersion.MirrorValue() +} + +func (rs *RepoStatus) MirrorCurrentName() *gui.Node { + return rs.currentBranch.MirrorValue() +} |
