From 677de48f6cd849fde7f8a4733bbab4b992471a13 Mon Sep 17 00:00:00 2001 From: obscuren Date: Wed, 2 Jul 2014 00:28:45 +0200 Subject: [PATCH] Listen for namereg changes --- ethereal/gui.go | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/ethereal/gui.go b/ethereal/gui.go index 1e6fac4de1..ea91622c62 100644 --- a/ethereal/gui.go +++ b/ethereal/gui.go @@ -41,7 +41,6 @@ type Gui struct { // Create GUI, but doesn't start it func NewWindow(ethereum *eth.Ethereum, session string, logLevel int) *Gui { - db, err := ethdb.NewLDBDatabase("tx_database") if err != nil { panic(err) @@ -273,7 +272,11 @@ func (gui *Gui) update() { reactor.Subscribe("newBlock", blockChan) reactor.Subscribe("newTx:pre", txChan) reactor.Subscribe("newTx:post", txChan) - //reactor.Subscribe("object:"+string(namereg), objectChan) + + nameReg := ethpub.EthereumConfig(gui.eth.StateManager()).NameReg() + if nameReg != nil { + reactor.Subscribe("object:"+string(nameReg.Address()), objectChan) + } reactor.Subscribe("peerList", peerChan) ticker := time.NewTicker(5 * time.Second)