Signed-off-by: Jeff Carr <jcarr@wit.com>
This commit is contained in:
Jeff Carr 2019-05-25 02:51:00 -07:00
parent 3f5ff714ca
commit b1cddd9f60
2 changed files with 4 additions and 12 deletions

View File

@ -48,7 +48,7 @@ json-readable:
cat ~/.config/cloud-control-panel.json |jq -r --tab
json-restore:
cp resources/jcarr.json ~/.config/cloud-control-panel.json
cp resources/protobuf-config.json ~/.config/cloud-control-panel.json
json-test:
cp resources/test.json ~/.config/cloud-control-panel.json

14
main.go
View File

@ -184,7 +184,7 @@ func mainMouseClick(b *gui.ButtonMap) {
log.Println("\tEntryName =", username)
log.Println("\tEntryPass =", password)
acc := new(pb.Config_Account)
acc := new(pb.Account)
acc.Nick = nick
acc.Username = username
acc.Password = password
@ -308,26 +308,18 @@ func watchGUI() {
time.Sleep(200 * time.Millisecond)
if (gui.Data.State == "SEND WEBSOCKET") {
log.Println("\tTRIGGERING WEBSOCKET HERE on AccNick =")
log.Println("\tTRIGGERING WEBSOCKET HERE on AccNick =")
log.Println("\tTRIGGERING WEBSOCKET HERE on AccNick =")
event := pb.MakeGetEvent()
event.Token = getToken()
log.Println("\tTRIGGERING WEBSOCKET HERE with event.Token =", event.Token)
log.Println("\tTRIGGERING WEBSOCKET pb.MakeGetEvent() event.Token =", event.Token)
gorillaSendProtobuf(event)
gui.Data.State = "READ PROTOBUF"
}
if (gui.Data.State == "SEND LOGIN") {
log.Println("\tTRIGGERING LOGIN HERE on AccNick =")
log.Println("\tTRIGGERING LOGIN HERE on AccNick =")
log.Println("\tTRIGGERING LOGIN HERE on AccNick =")
event := pb.MakeLoginEvent()
event.Token = getToken()
event.Username = gui.Data.Current.Username
log.Println("\tTRIGGERING LOGIN HERE with event.Token =", event.Token)
log.Println("\tTRIGGERING LOGIN HERE pb.MakeLoginEvent() event.Token =", event.Token)
gorillaSendProtobuf(event)
gui.Data.State = "READ PROTOBUF"
}