show nixos version in cards
This commit is contained in:
parent
7394dbe119
commit
5a904f911e
@ -16,7 +16,7 @@
|
||||
in {
|
||||
xintray = pkgs.buildGoModule {
|
||||
pname = "xintray";
|
||||
version = "v0.1.3";
|
||||
version = "v0.1.4";
|
||||
src = ./.;
|
||||
|
||||
vendorSha256 =
|
||||
|
5
main.go
5
main.go
@ -330,15 +330,20 @@ func buildCards(stat *xinStatus) fyne.CanvasObject {
|
||||
commitBStr := binding.BindString(&s.commit.message)
|
||||
bsl := widget.NewLabelWithData(commitBStr)
|
||||
|
||||
verBStr := binding.BindString(&s.NixosVersion)
|
||||
bvl := widget.NewLabelWithData(verBStr)
|
||||
|
||||
restartBBool := binding.BindBool(&s.NeedsRestart)
|
||||
bbl := widget.NewCheckWithData("Reboot", restartBBool)
|
||||
bbl.Disable()
|
||||
|
||||
stat.boundStrings = append(stat.boundStrings, commitBStr)
|
||||
stat.boundStrings = append(stat.boundStrings, verBStr)
|
||||
stat.boundBools = append(stat.boundBools, restartBBool)
|
||||
|
||||
card := widget.NewCard(s.Host, "",
|
||||
container.NewVBox(
|
||||
container.NewHBox(bvl),
|
||||
container.NewHBox(bbl),
|
||||
container.NewHBox(bsl),
|
||||
),
|
||||
|
Loading…
Reference in New Issue
Block a user