Moved over to hardcoded v1 of Go QML
This commit is contained in:
parent
df0c43265e
commit
9f4886839f
@ -11,7 +11,7 @@ import (
|
|||||||
"github.com/ethereum/eth-go/ethutil"
|
"github.com/ethereum/eth-go/ethutil"
|
||||||
"github.com/ethereum/eth-go/ethvm"
|
"github.com/ethereum/eth-go/ethvm"
|
||||||
"github.com/ethereum/go-ethereum/utils"
|
"github.com/ethereum/go-ethereum/utils"
|
||||||
"github.com/go-qml/qml"
|
"gopkg.in/qml.v1"
|
||||||
)
|
)
|
||||||
|
|
||||||
type DebuggerWindow struct {
|
type DebuggerWindow struct {
|
||||||
|
@ -8,7 +8,7 @@ import (
|
|||||||
"github.com/ethereum/eth-go/ethreact"
|
"github.com/ethereum/eth-go/ethreact"
|
||||||
"github.com/ethereum/eth-go/ethstate"
|
"github.com/ethereum/eth-go/ethstate"
|
||||||
"github.com/ethereum/go-ethereum/javascript"
|
"github.com/ethereum/go-ethereum/javascript"
|
||||||
"github.com/go-qml/qml"
|
"gopkg.in/qml.v1"
|
||||||
)
|
)
|
||||||
|
|
||||||
type AppContainer interface {
|
type AppContainer interface {
|
||||||
|
@ -18,7 +18,7 @@ import (
|
|||||||
"github.com/ethereum/eth-go/ethutil"
|
"github.com/ethereum/eth-go/ethutil"
|
||||||
"github.com/ethereum/eth-go/ethwire"
|
"github.com/ethereum/eth-go/ethwire"
|
||||||
"github.com/ethereum/go-ethereum/utils"
|
"github.com/ethereum/go-ethereum/utils"
|
||||||
"github.com/go-qml/qml"
|
"gopkg.in/qml.v1"
|
||||||
)
|
)
|
||||||
|
|
||||||
var logger = ethlog.NewLogger("GUI")
|
var logger = ethlog.NewLogger("GUI")
|
||||||
|
@ -14,8 +14,8 @@ import (
|
|||||||
"github.com/ethereum/eth-go/ethstate"
|
"github.com/ethereum/eth-go/ethstate"
|
||||||
"github.com/ethereum/eth-go/ethutil"
|
"github.com/ethereum/eth-go/ethutil"
|
||||||
"github.com/ethereum/go-ethereum/javascript"
|
"github.com/ethereum/go-ethereum/javascript"
|
||||||
"github.com/go-qml/qml"
|
|
||||||
"github.com/howeyc/fsnotify"
|
"github.com/howeyc/fsnotify"
|
||||||
|
"gopkg.in/qml.v1"
|
||||||
)
|
)
|
||||||
|
|
||||||
type HtmlApplication struct {
|
type HtmlApplication struct {
|
||||||
|
@ -4,9 +4,10 @@ import (
|
|||||||
"os"
|
"os"
|
||||||
"runtime"
|
"runtime"
|
||||||
|
|
||||||
|
"github.com/ethereum/eth-go"
|
||||||
"github.com/ethereum/eth-go/ethlog"
|
"github.com/ethereum/eth-go/ethlog"
|
||||||
"github.com/ethereum/go-ethereum/utils"
|
"github.com/ethereum/go-ethereum/utils"
|
||||||
"github.com/go-qml/qml"
|
"gopkg.in/qml.v1"
|
||||||
)
|
)
|
||||||
|
|
||||||
const (
|
const (
|
||||||
@ -14,21 +15,9 @@ const (
|
|||||||
Version = "0.6.1"
|
Version = "0.6.1"
|
||||||
)
|
)
|
||||||
|
|
||||||
func main() {
|
var ethereum *eth.Ethereum
|
||||||
runtime.GOMAXPROCS(runtime.NumCPU())
|
|
||||||
|
|
||||||
// This is a bit of a cheat, but ey!
|
|
||||||
os.Setenv("QTWEBKIT_INSPECTOR_SERVER", "127.0.0.1:99999")
|
|
||||||
|
|
||||||
qml.Init(nil)
|
|
||||||
|
|
||||||
var interrupted = false
|
|
||||||
utils.RegisterInterrupt(func(os.Signal) {
|
|
||||||
interrupted = true
|
|
||||||
})
|
|
||||||
|
|
||||||
utils.HandleInterrupt()
|
|
||||||
|
|
||||||
|
func run() error {
|
||||||
// precedence: code-internal flag default < config file < environment variables < command line
|
// precedence: code-internal flag default < config file < environment variables < command line
|
||||||
Init() // parsing command line
|
Init() // parsing command line
|
||||||
|
|
||||||
@ -47,7 +36,7 @@ func main() {
|
|||||||
|
|
||||||
clientIdentity := utils.NewClientIdentity(ClientIdentifier, Version, Identifier)
|
clientIdentity := utils.NewClientIdentity(ClientIdentifier, Version, Identifier)
|
||||||
|
|
||||||
ethereum := utils.NewEthereum(db, clientIdentity, keyManager, UseUPnP, OutboundPort, MaxPeer)
|
ethereum = utils.NewEthereum(db, clientIdentity, keyManager, UseUPnP, OutboundPort, MaxPeer)
|
||||||
|
|
||||||
if ShowGenesis {
|
if ShowGenesis {
|
||||||
utils.ShowGenesis(ethereum)
|
utils.ShowGenesis(ethereum)
|
||||||
@ -65,6 +54,26 @@ func main() {
|
|||||||
utils.StartEthereum(ethereum, UseSeed)
|
utils.StartEthereum(ethereum, UseSeed)
|
||||||
// gui blocks the main thread
|
// gui blocks the main thread
|
||||||
gui.Start(AssetPath)
|
gui.Start(AssetPath)
|
||||||
|
|
||||||
|
return nil
|
||||||
|
}
|
||||||
|
|
||||||
|
func main() {
|
||||||
|
runtime.GOMAXPROCS(runtime.NumCPU())
|
||||||
|
|
||||||
|
// This is a bit of a cheat, but ey!
|
||||||
|
os.Setenv("QTWEBKIT_INSPECTOR_SERVER", "127.0.0.1:99999")
|
||||||
|
|
||||||
|
//qml.Init(nil)
|
||||||
|
qml.Run(run)
|
||||||
|
|
||||||
|
var interrupted = false
|
||||||
|
utils.RegisterInterrupt(func(os.Signal) {
|
||||||
|
interrupted = true
|
||||||
|
})
|
||||||
|
|
||||||
|
utils.HandleInterrupt()
|
||||||
|
|
||||||
// we need to run the interrupt callbacks in case gui is closed
|
// we need to run the interrupt callbacks in case gui is closed
|
||||||
// this skips if we got here by actual interrupt stopping the GUI
|
// this skips if we got here by actual interrupt stopping the GUI
|
||||||
if !interrupted {
|
if !interrupted {
|
||||||
|
@ -8,7 +8,7 @@ import (
|
|||||||
"github.com/ethereum/eth-go/ethpub"
|
"github.com/ethereum/eth-go/ethpub"
|
||||||
"github.com/ethereum/eth-go/ethstate"
|
"github.com/ethereum/eth-go/ethstate"
|
||||||
"github.com/ethereum/eth-go/ethutil"
|
"github.com/ethereum/eth-go/ethutil"
|
||||||
"github.com/go-qml/qml"
|
"gopkg.in/qml.v1"
|
||||||
)
|
)
|
||||||
|
|
||||||
type QmlApplication struct {
|
type QmlApplication struct {
|
||||||
|
@ -9,7 +9,7 @@ import (
|
|||||||
"github.com/ethereum/eth-go/ethpipe"
|
"github.com/ethereum/eth-go/ethpipe"
|
||||||
"github.com/ethereum/eth-go/ethutil"
|
"github.com/ethereum/eth-go/ethutil"
|
||||||
"github.com/ethereum/go-ethereum/javascript"
|
"github.com/ethereum/go-ethereum/javascript"
|
||||||
"github.com/go-qml/qml"
|
"gopkg.in/qml.v1"
|
||||||
)
|
)
|
||||||
|
|
||||||
type memAddr struct {
|
type memAddr struct {
|
||||||
|
Loading…
Reference in New Issue
Block a user