github.com/danbrough/mobile@v0.0.3-beta03/bind/java/context_linux.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/danbrough/mobile/bind/java" 6 7 // 8 //#include <jni.h> 9 import "C" 10 11 import ( 12 "unsafe" 13 14 "github.com/danbrough/mobile/internal/mobileinit" 15 ) 16 17 //export setContext 18 func setContext(vm *C.JavaVM, ctx C.jobject) { 19 mobileinit.SetCurrentContext(unsafe.Pointer(vm), uintptr(ctx)) 20 }