add windows gui support
支持windows 显示
This commit is contained in:
@@ -389,6 +389,7 @@ func listUp(g *gocui.Gui, v *gocui.View) error {
|
||||
// OnInitDialog init main loop
|
||||
func OnInitDialog() {
|
||||
g, err := gocui.NewGui(gocui.OutputNormal)
|
||||
g.ASCII = true
|
||||
|
||||
if err != nil {
|
||||
log.Panicln(err)
|
||||
|
||||
@@ -1,6 +1,15 @@
|
||||
package dlg
|
||||
|
||||
import (
|
||||
"runtime"
|
||||
|
||||
"github.com/xxjwxc/public/myi18n"
|
||||
)
|
||||
|
||||
// WinMain windows main loop
|
||||
func WinMain() {
|
||||
if runtime.GOOS == "windows" {
|
||||
myi18n.SetLocalLG("en")
|
||||
}
|
||||
OnInitDialog()
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user