From f6aabb7a90903a681eca44976301620756124137 Mon Sep 17 00:00:00 2001 From: Maran Date: Mon, 23 Jun 2014 16:25:57 +0200 Subject: Implements QML Apps. Implements #47 You are welcome Stephan. --- ethereal/ui/ui_lib.go | 15 ++++----------- 1 file changed, 4 insertions(+), 11 deletions(-) (limited to 'ethereal/ui/ui_lib.go') diff --git a/ethereal/ui/ui_lib.go b/ethereal/ui/ui_lib.go index 791d4fe09..908497be3 100644 --- a/ethereal/ui/ui_lib.go +++ b/ethereal/ui/ui_lib.go @@ -35,18 +35,11 @@ func NewUiLib(engine *qml.Engine, eth *eth.Ethereum, assetPath string) *UiLib { return &UiLib{engine: engine, eth: eth, assetPath: assetPath} } -// Opens a QML file (external application) -func (ui *UiLib) Open(path string) { - component, err := ui.engine.LoadFile(path[7:]) - if err != nil { - ethutil.Config.Log.Debugln(err) - } - win := component.CreateWindow(nil) +func (ui *UiLib) OpenQml(path string) { + container := NewQmlApplication(path[7:], ui) + app := NewExtApplication(container, ui) - go func() { - win.Show() - win.Wait() - }() + go app.run() } func (ui *UiLib) OpenHtml(path string) { -- cgit