asticode / go-astilectron-bundler

Bundle your Astilectron app with ease

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Showing the electron icon in app launchers of windows

Errrorr opened this issue · comments

Hi,
I have some problems about launching my app in windows environment.

  1. When I right-click the app in launchers, it shows the electron icon instead of the application icon. And after clicking the option 'electron', it popups electron window.
    1
    image

  2. When I add my app to app launchers, the launcher icon becomes the electron icon.
    image

Thank you for your help.

Can you share some code so that I can see how you're setting up Astilectron options ?

Oh sorry, I forgot to show some information.

bundler.json

{
  "app_name": "pplinservice",
  "environments": [
    {
      "arch": "amd64",
      "os": "windows",
      "env": {
        "CC": "x86_64-w64-mingw32-gcc",
        "CXX": "x86_64-w64-mingw32-g++",
        "CGO_ENABLED": "1"
      }
    }
  ],
  "icon_path_windows": "resources/app/statics/icons/icon.ico",
  "output_path": "../output/latest"
}

bootstrap.Options

bootstrap.Options{
  Asset:         Asset,
  RestoreAssets: RestoreAssets,
  AstilectronOptions: astilectron.Options{
    AppName: "PPLinService",
    AppIconDefaultPath: "resources/app/statics/icons/icon.png",
  },
  Debug:         *debug,
  OnWait: func(_ *astilectron.Astilectron, ws []*astilectron.Window, _ *astilectron.Menu, _ *astilectron.Tray, _ *astilectron.Menu) error {
    if *debug {
      ws[0].OpenDevTools()
    }
    runForegroundMode(ws[0])
    return nil
  },
  Windows: []*bootstrap.Window{
    {
      Homepage:       "index.html",
      MessageHandler: ctrl.HandleMessages,
      Options: &astilectron.WindowOptions{
        Center: astilectron.PtrBool(true),
        Width:  astilectron.PtrInt(800),
        Height: astilectron.PtrInt(600),
      },
    },
  },
}

Right off the bat I've no idea why it shows Electron's menu. I'll investigate more once I've some free time.

Thank you very much.

Hi @asticode, I'm running into the same problem. Have you found the issue yet?

@pzeinlinger unfortunately no 😒