aboutsummaryrefslogtreecommitdiffstats
path: root/cmd
diff options
context:
space:
mode:
Diffstat (limited to 'cmd')
-rw-r--r--cmd/mist/bindings.go4
-rw-r--r--cmd/mist/debugger.go4
-rw-r--r--cmd/mist/ext_app.go14
-rw-r--r--cmd/mist/gui.go20
-rw-r--r--cmd/mist/html_container.go4
-rw-r--r--cmd/mist/qml_container.go4
-rw-r--r--cmd/mist/ui_lib.go8
7 files changed, 29 insertions, 29 deletions
diff --git a/cmd/mist/bindings.go b/cmd/mist/bindings.go
index 0a6427938..03d35a574 100644
--- a/cmd/mist/bindings.go
+++ b/cmd/mist/bindings.go
@@ -22,7 +22,7 @@ import (
"os"
"strconv"
- "github.com/ethereum/go-ethereum/ethchain"
+ "github.com/ethereum/go-ethereum/chain"
"github.com/ethereum/go-ethereum/ethlog"
"github.com/ethereum/go-ethereum/ethpipe"
"github.com/ethereum/go-ethereum/ethutil"
@@ -110,7 +110,7 @@ func (self *Gui) DumpState(hash, path string) {
if len(hash) == 0 {
stateDump = self.eth.StateManager().CurrentState().Dump()
} else {
- var block *ethchain.Block
+ var block *chain.Block
if hash[0] == '#' {
i, _ := strconv.Atoi(hash[1:])
block = self.eth.ChainManager().GetBlockByNumber(uint64(i))
diff --git a/cmd/mist/debugger.go b/cmd/mist/debugger.go
index ff3a30b3b..d786a0395 100644
--- a/cmd/mist/debugger.go
+++ b/cmd/mist/debugger.go
@@ -24,7 +24,7 @@ import (
"strings"
"unicode"
- "github.com/ethereum/go-ethereum/ethchain"
+ "github.com/ethereum/go-ethereum/chain"
"github.com/ethereum/go-ethereum/ethstate"
"github.com/ethereum/go-ethereum/ethutil"
"github.com/ethereum/go-ethereum/utils"
@@ -81,7 +81,7 @@ func (self *DebuggerWindow) SetData(data string) {
func (self *DebuggerWindow) SetAsm(data []byte) {
self.win.Root().Call("clearAsm")
- dis := ethchain.Disassemble(data)
+ dis := chain.Disassemble(data)
for _, str := range dis {
self.win.Root().Call("setAsm", str)
}
diff --git a/cmd/mist/ext_app.go b/cmd/mist/ext_app.go
index 7680106f0..cb014aec4 100644
--- a/cmd/mist/ext_app.go
+++ b/cmd/mist/ext_app.go
@@ -20,7 +20,7 @@ package main
import (
"encoding/json"
- "github.com/ethereum/go-ethereum/ethchain"
+ "github.com/ethereum/go-ethereum/chain"
"github.com/ethereum/go-ethereum/ethpipe"
"github.com/ethereum/go-ethereum/ethstate"
"github.com/ethereum/go-ethereum/event"
@@ -36,7 +36,7 @@ type AppContainer interface {
Window() *qml.Window
Engine() *qml.Engine
- NewBlock(*ethchain.Block)
+ NewBlock(*chain.Block)
NewWatcher(chan bool)
Messages(ethstate.Messages, string)
Post(string, int)
@@ -44,12 +44,12 @@ type AppContainer interface {
type ExtApplication struct {
*ethpipe.JSPipe
- eth ethchain.EthManager
+ eth chain.EthManager
events event.Subscription
watcherQuitChan chan bool
- filters map[string]*ethchain.Filter
+ filters map[string]*chain.Filter
container AppContainer
lib *UiLib
@@ -60,7 +60,7 @@ func NewExtApplication(container AppContainer, lib *UiLib) *ExtApplication {
JSPipe: ethpipe.NewJSPipe(lib.eth),
eth: lib.eth,
watcherQuitChan: make(chan bool),
- filters: make(map[string]*ethchain.Filter),
+ filters: make(map[string]*chain.Filter),
container: container,
lib: lib,
}
@@ -80,7 +80,7 @@ func (app *ExtApplication) run() {
// Subscribe to events
mux := app.lib.eth.EventMux()
- app.events = mux.Subscribe(ethchain.NewBlockEvent{}, ethstate.Messages(nil))
+ app.events = mux.Subscribe(chain.NewBlockEvent{}, ethstate.Messages(nil))
// Call the main loop
go app.mainLoop()
@@ -106,7 +106,7 @@ func (app *ExtApplication) stop() {
func (app *ExtApplication) mainLoop() {
for ev := range app.events.Chan() {
switch ev := ev.(type) {
- case ethchain.NewBlockEvent:
+ case chain.NewBlockEvent:
app.container.NewBlock(ev.Block)
case ethstate.Messages:
diff --git a/cmd/mist/gui.go b/cmd/mist/gui.go
index e6da33475..c917ad06e 100644
--- a/cmd/mist/gui.go
+++ b/cmd/mist/gui.go
@@ -31,7 +31,7 @@ import (
"time"
"github.com/ethereum/go-ethereum"
- "github.com/ethereum/go-ethereum/ethchain"
+ "github.com/ethereum/go-ethereum/chain"
"github.com/ethereum/go-ethereum/ethdb"
"github.com/ethereum/go-ethereum/ethlog"
"github.com/ethereum/go-ethereum/ethminer"
@@ -286,7 +286,7 @@ func (gui *Gui) loadAddressBook() {
}
}
-func (gui *Gui) insertTransaction(window string, tx *ethchain.Transaction) {
+func (gui *Gui) insertTransaction(window string, tx *chain.Transaction) {
pipe := ethpipe.New(gui.eth)
nameReg := pipe.World().Config().Get("NameReg")
addr := gui.address()
@@ -336,7 +336,7 @@ func (gui *Gui) insertTransaction(window string, tx *ethchain.Transaction) {
func (gui *Gui) readPreviousTransactions() {
it := gui.txDb.Db().NewIterator(nil, nil)
for it.Next() {
- tx := ethchain.NewTransactionFromBytes(it.Value())
+ tx := chain.NewTransactionFromBytes(it.Value())
gui.insertTransaction("post", tx)
@@ -344,7 +344,7 @@ func (gui *Gui) readPreviousTransactions() {
it.Release()
}
-func (gui *Gui) processBlock(block *ethchain.Block, initial bool) {
+func (gui *Gui) processBlock(block *chain.Block, initial bool) {
name := strings.Trim(gui.pipe.World().Config().Get("NameReg").Storage(block.Coinbase).Str(), "\x00")
b := ethpipe.NewJSBlock(block)
b.Name = name
@@ -407,9 +407,9 @@ func (gui *Gui) update() {
events := gui.eth.EventMux().Subscribe(
eth.ChainSyncEvent{},
eth.PeerListEvent{},
- ethchain.NewBlockEvent{},
- ethchain.TxPreEvent{},
- ethchain.TxPostEvent{},
+ chain.NewBlockEvent{},
+ chain.TxPreEvent{},
+ chain.TxPostEvent{},
ethminer.Event{},
)
@@ -425,13 +425,13 @@ func (gui *Gui) update() {
return
}
switch ev := ev.(type) {
- case ethchain.NewBlockEvent:
+ case chain.NewBlockEvent:
gui.processBlock(ev.Block, false)
if bytes.Compare(ev.Block.Coinbase, gui.address()) == 0 {
gui.setWalletValue(gui.eth.StateManager().CurrentState().GetAccount(gui.address()).Balance(), nil)
}
- case ethchain.TxPreEvent:
+ case chain.TxPreEvent:
tx := ev.Tx
object := state.GetAccount(gui.address())
@@ -444,7 +444,7 @@ func (gui *Gui) update() {
gui.setWalletValue(object.Balance(), unconfirmedFunds)
gui.insertTransaction("pre", tx)
- case ethchain.TxPostEvent:
+ case chain.TxPostEvent:
tx := ev.Tx
object := state.GetAccount(gui.address())
diff --git a/cmd/mist/html_container.go b/cmd/mist/html_container.go
index 2e2818027..96bae1a9a 100644
--- a/cmd/mist/html_container.go
+++ b/cmd/mist/html_container.go
@@ -27,7 +27,7 @@ import (
"path"
"path/filepath"
- "github.com/ethereum/go-ethereum/ethchain"
+ "github.com/ethereum/go-ethereum/chain"
"github.com/ethereum/go-ethereum/ethpipe"
"github.com/ethereum/go-ethereum/ethstate"
"github.com/ethereum/go-ethereum/ethutil"
@@ -138,7 +138,7 @@ func (app *HtmlApplication) Window() *qml.Window {
return app.win
}
-func (app *HtmlApplication) NewBlock(block *ethchain.Block) {
+func (app *HtmlApplication) NewBlock(block *chain.Block) {
b := &ethpipe.JSBlock{Number: int(block.BlockInfo().Number), Hash: ethutil.Bytes2Hex(block.Hash())}
app.webView.Call("onNewBlockCb", b)
}
diff --git a/cmd/mist/qml_container.go b/cmd/mist/qml_container.go
index 7538fb919..3318786e7 100644
--- a/cmd/mist/qml_container.go
+++ b/cmd/mist/qml_container.go
@@ -21,7 +21,7 @@ import (
"fmt"
"runtime"
- "github.com/ethereum/go-ethereum/ethchain"
+ "github.com/ethereum/go-ethereum/chain"
"github.com/ethereum/go-ethereum/ethpipe"
"github.com/ethereum/go-ethereum/ethstate"
"github.com/ethereum/go-ethereum/ethutil"
@@ -65,7 +65,7 @@ func (app *QmlApplication) NewWatcher(quitChan chan bool) {
}
// Events
-func (app *QmlApplication) NewBlock(block *ethchain.Block) {
+func (app *QmlApplication) NewBlock(block *chain.Block) {
pblock := &ethpipe.JSBlock{Number: int(block.BlockInfo().Number), Hash: ethutil.Bytes2Hex(block.Hash())}
app.win.Call("onNewBlockCb", pblock)
}
diff --git a/cmd/mist/ui_lib.go b/cmd/mist/ui_lib.go
index 32ca3c2c9..a9b560b6f 100644
--- a/cmd/mist/ui_lib.go
+++ b/cmd/mist/ui_lib.go
@@ -25,7 +25,7 @@ import (
"strings"
"github.com/ethereum/go-ethereum"
- "github.com/ethereum/go-ethereum/ethchain"
+ "github.com/ethereum/go-ethereum/chain"
"github.com/ethereum/go-ethereum/ethcrypto"
"github.com/ethereum/go-ethereum/ethpipe"
"github.com/ethereum/go-ethereum/ethstate"
@@ -120,7 +120,7 @@ func (self *UiLib) PastPeers() *ethutil.List {
}
func (self *UiLib) ImportTx(rlpTx string) {
- tx := ethchain.NewTransactionFromBytes(ethutil.Hex2Bytes(rlpTx))
+ tx := chain.NewTransactionFromBytes(ethutil.Hex2Bytes(rlpTx))
self.eth.TxPool().QueueTransaction(tx)
}
@@ -221,8 +221,8 @@ func (self *UiLib) NewFilter(object map[string]interface{}) (id int) {
}
func (self *UiLib) NewFilterString(typ string) (id int) {
- filter := ethchain.NewFilter(self.eth)
- filter.BlockCallback = func(block *ethchain.Block) {
+ filter := chain.NewFilter(self.eth)
+ filter.BlockCallback = func(block *chain.Block) {
self.win.Root().Call("invokeFilterCallback", "{}", id)
}
id = self.eth.InstallFilter(filter)