Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Search bin directory for qml #21

Merged
merged 1 commit into from
Feb 28, 2014
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 8 additions & 2 deletions ui/gui.go
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,8 @@ import (
"github.com/ethereum/eth-go/ethdb"
"github.com/ethereum/eth-go/ethutil"
"github.com/niemeyer/qml"
"bitbucket.org/kardianos/osext"
"path/filepath"
"math/big"
"strings"
)
Expand Down Expand Up @@ -84,12 +86,16 @@ func (ui *Gui) Start() {
ethutil.Config.Log.Infoln("[GUI] Starting GUI")
// Create a new QML engine
ui.engine = qml.NewEngine()

// Get Binary Directory
exedir , _ := osext.ExecutableFolder()

// Load the main QML interface
component, err := ui.engine.LoadFile("wallet.qml")
component, err := ui.engine.LoadFile(filepath.Join(exedir, "wallet.qml"))
if err != nil {
panic(err)
}
ui.engine.LoadFile("transactions.qml")
ui.engine.LoadFile(filepath.Join(exedir, "transactions.qml"))

ui.win = component.CreateWindow(nil)

Expand Down