diff options
author | kali kaneko (leap communications) <kali@leap.se> | 2020-06-04 16:25:04 +0200 |
---|---|---|
committer | kali kaneko (leap communications) <kali@leap.se> | 2020-06-12 20:02:53 +0200 |
commit | a126d333e0d83d44d7306c3ddb9008c7e4df41c7 (patch) | |
tree | 1bf402589d55f834099cf906c477540f13594de9 /gui | |
parent | e66d469c3cdc72b6c0adb274ae39028301168369 (diff) |
[feat] pickled helpers ftw
Signed-off-by: kali kaneko (leap communications) <kali@leap.se>
Diffstat (limited to 'gui')
-rw-r--r-- | gui/backend.go | 6 | ||||
-rw-r--r-- | gui/main.cpp | 6 |
2 files changed, 12 insertions, 0 deletions
diff --git a/gui/backend.go b/gui/backend.go index 812258d..ecff8dc 100644 --- a/gui/backend.go +++ b/gui/backend.go @@ -14,6 +14,7 @@ import ( "unsafe" "0xacab.org/leap/bitmask-vpn/pkg/bitmask" + "0xacab.org/leap/bitmask-vpn/pkg/pickle" "0xacab.org/leap/bitmask-vpn/pkg/systray2" "github.com/jmshal/go-locale" "golang.org/x/text/message" @@ -337,6 +338,11 @@ func RefreshContext() *C.char { return C.CString(string(c)) } +//export InstallHelpers +func InstallHelpers() { + pickle.InstallHelpers() +} + /* end of the exposed api */ /* we could enable this one optionally for the qt tests */ diff --git a/gui/main.cpp b/gui/main.cpp index f2545d3..3e96761 100644 --- a/gui/main.cpp +++ b/gui/main.cpp @@ -65,6 +65,12 @@ int main(int argc, char **argv) { bool debugQml = getEnv("DEBUG_QML_DATA") == "yes"; + if (argc > 1 && strcmp(argv[1], "install-helpers") == 0) { + qDebug() << "Will try to install helpers with sudo"; + InstallHelpers(); + exit(0); + } + QGuiApplication::setAttribute(Qt::AA_EnableHighDpiScaling); QGuiApplication app(argc, argv); app.setQuitOnLastWindowClosed(false); |