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