github.com/SpiderOak/mobile@v0.0.0-20221129182558-6f541b59af45/bind/java/context_android.go (about) 1 // Copyright 2016 The Go Authors. All rights reserved. 2 // Use of this source code is governed by a BSD-style 3 // license that can be found in the LICENSE file. 4 5 package java // import "github.com/SpiderOak/mobile/bind/java" 6 7 // #cgo LDFLAGS: -llog 8 // 9 //#include <jni.h> 10 import "C" 11 12 import ( 13 "unsafe" 14 15 "github.com/SpiderOak/mobile/internal/mobileinit" 16 ) 17 18 //export setContext 19 func setContext(vm *C.JavaVM, ctx C.jobject) { 20 mobileinit.SetCurrentContext(unsafe.Pointer(vm), uintptr(ctx)) 21 }