Compare commits

...
14 Commits
Author SHA1 Message Date
gmp e53c7be976 Ignore jar build dir 2026-08-21 20:34:57 -04:00
gmp 99598c14fe Request BLUETOOTH_SCAN/CONNECT at onAttach on API 31+
Activity.requestPermissions is unreliable from non-UI threads / late
timing on Android 17 (createDeviceContext garbage device id); the
fragment's onAttach request path works. Skip the legacy location
request on API 31+ (BLUETOOTH_SCAN is neverForLocation). Rebuild
Ble.jar.
2026-08-21 20:28:43 -04:00
gmp 876ea68622 Use commitNowAllowingStateLoss (API 24+) for fragment registration
The register() runnable can run after the activity has saved its
state (e.g. app started in the background), in which case commitNow
throws IllegalStateException and crashes the app. Rebuild Ble.jar.
2026-08-21 19:52:33 -04:00
gmp 9f32185b78 Merge branch 'fix/recents-wipe-jni-null-view'
Guard against Gio's null-view detach event (recents-wipe SIGABRT).
2026-08-20 23:35:08 -04:00
gmp d70bbfed13 Guard against Gio's null-view detach event (recents-wipe SIGABRT)
Gio's GioView.onDestroyView sends ViewEvent{View: 0} as its detach
signal when the view is destroyed — i.e. the activity going away on a
recents-wipe. An app that forwards the event to Enable() passes a zero
view through to registerFragment, whose GetObjectClass(null) aborts the
process (JNI DETECTED ERROR: java_object == null in call to
GetObjectClass).

Enable() now returns early on a zero view so all callers are covered
even if they forward the event unfiltered, and registerFragment
null-checks as defense in depth. Same fix as pad (fdbffc9); verified
there on a Pixel 9 Pro / Android 17 where the recents swipe used to
crash the app.
2026-08-20 22:16:23 -04:00
gmp 6da0474e59 Bug fix for Android (C variable name conflict). 2021-11-15 15:42:35 -05:00
gmp a6cc776a0d Update to gioui.org@v0.0.0-20211113093644. Updates for MacOS 11.5. 2021-11-15 14:14:45 -05:00
gmp 90ab682a44 Port to gio gioui.org@20200829. 2020-09-05 14:12:29 -04:00
gmp b0b310a7b0 Bump gio version, use window.Do() instead of RegisterFragment(). 2020-06-19 14:35:49 -04:00
gmp f5cc27a30d Bump gio version. 2020-06-12 16:10:46 -04:00
gmp 7a583419c5 BlessedConnect.java: make sure gio shared library is loaded
before calling native methods.
2020-02-04 17:36:39 -05:00
gmp 2d7594514c Fixes to depjars/build.go 2019-12-30 11:26:24 -05:00
gmp 52217c3f6a Add Timber license. Add depjars/ and go:generate commands to build
Java dependencies. Bug fix in retrievePeripheral so that we do not
zero out the reference to the Java Peripheral object.
2019-12-13 13:20:30 -05:00
gmp dd7d927044 Add license information. 2019-12-11 09:58:27 -05:00
18 changed files with 51868 additions and 52454 deletions
+2
View File
@@ -1 +1,3 @@
classes/
cb.ast
BIN
View File
Binary file not shown.
+35 -2
View File
@@ -1,10 +1,12 @@
package st.wow.git.ble; package st.wow.git.ble;
import java.lang.String; import java.lang.String;
import java.lang.Runnable;
import java.util.List; import java.util.List;
import java.util.UUID; import java.util.UUID;
import android.app.Activity; import android.app.Activity;
import android.app.Fragment; import android.app.Fragment;
import android.app.FragmentTransaction;
import android.bluetooth.BluetoothAdapter; import android.bluetooth.BluetoothAdapter;
import android.bluetooth.BluetoothGatt; import android.bluetooth.BluetoothGatt;
import android.bluetooth.BluetoothGattCharacteristic; import android.bluetooth.BluetoothGattCharacteristic;
@@ -18,7 +20,9 @@ import android.content.Intent;
import android.content.IntentFilter; import android.content.IntentFilter;
import android.content.pm.PackageManager; import android.content.pm.PackageManager;
import android.Manifest; import android.Manifest;
import android.os.Handler;
import android.util.Log; import android.util.Log;
import android.view.View;
import com.welie.blessed.BluetoothCentral; import com.welie.blessed.BluetoothCentral;
import com.welie.blessed.BluetoothCentralCallback; import com.welie.blessed.BluetoothCentralCallback;
@@ -31,19 +35,48 @@ public class BlessedConnect extends Fragment {
final int PERMISSION_REQUEST = 1; final int PERMISSION_REQUEST = 1;
final int REQUEST_ENABLE_BT = 2; final int REQUEST_ENABLE_BT = 2;
final int PERMISSION_REQUEST_BLE = 3;
public BlessedConnect() { public BlessedConnect() {
Log.d("gio", "BlessedConnect()"); Log.d("gio", "BlessedConnect()");
} }
public void register(View view) {
Log.d("gio", "BlessedConnect: register()");
Context ctx = view.getContext();
Handler handler = new Handler(ctx.getMainLooper());
BlessedConnect inst = this;
handler.post(new Runnable() {
public void run() {
Activity act = (Activity)ctx;
FragmentTransaction ft = act.getFragmentManager().beginTransaction();
ft.add(inst, "BlessedConnect");
if (android.os.Build.VERSION.SDK_INT >= 24) {
ft.commitNowAllowingStateLoss();
} else {
ft.commitNow();
}
}
});
}
@Override public void onAttach(Context ctx) { @Override public void onAttach(Context ctx) {
super.onAttach(ctx); super.onAttach(ctx);
Log.d("gio", "BlessedConnect: onAttach()"); Log.d("gio", "BlessedConnect: onAttach()");
ctx.registerReceiver(receiver, new IntentFilter(BluetoothAdapter.ACTION_STATE_CHANGED)); ctx.registerReceiver(receiver, new IntentFilter(BluetoothAdapter.ACTION_STATE_CHANGED));
if (ctx.checkSelfPermission(Manifest.permission.ACCESS_FINE_LOCATION) != PackageManager.PERMISSION_GRANTED) { if (android.os.Build.VERSION.SDK_INT >= 31) {
// BLE on Android 12+ needs the BLUETOOTH_SCAN/CONNECT runtime
// permissions. BLUETOOTH_SCAN is declared with
// usesPermissionFlags="neverForLocation", so no location
// permission is required for scanning.
requestPermissions(new String[]{
"android.permission.BLUETOOTH_SCAN",
"android.permission.BLUETOOTH_CONNECT"}, PERMISSION_REQUEST_BLE);
} else if (ctx.checkSelfPermission(Manifest.permission.ACCESS_FINE_LOCATION) != PackageManager.PERMISSION_GRANTED) {
requestPermissions(new String[]{Manifest.permission.ACCESS_FINE_LOCATION}, PERMISSION_REQUEST); requestPermissions(new String[]{Manifest.permission.ACCESS_FINE_LOCATION}, PERMISSION_REQUEST);
} }
central = new BluetoothCentral(ctx, centralCallback, null); central = new BluetoothCentral(ctx, centralCallback, null);
System.loadLibrary("gio");
installComplete(this); installComplete(this);
} }
@@ -244,7 +277,7 @@ public class BlessedConnect extends Fragment {
@Override @Override
public void onRequestPermissionsResult (int requestCode, String[] permissions, int[] grantResults) { public void onRequestPermissionsResult (int requestCode, String[] permissions, int[] grantResults) {
Log.d("gio", "BlessedConnect: onRequestPermissionsResult"); Log.d("gio", "BlessedConnect: onRequestPermissionsResult");
if (requestCode == PERMISSION_REQUEST) { if (requestCode == PERMISSION_REQUEST || requestCode == PERMISSION_REQUEST_BLE) {
boolean granted = true; boolean granted = true;
for (int x : grantResults) { for (int x : grantResults) {
if (x == PackageManager.PERMISSION_DENIED) { if (x == PackageManager.PERMISSION_DENIED) {
+21
View File
@@ -0,0 +1,21 @@
The MIT License (MIT)
Copyright (c) 2019 Gregory Pomerantz
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in
all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
THE SOFTWARE.
+21
View File
@@ -0,0 +1,21 @@
MIT License
Copyright (c) 2019 Martijn van Welie
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.
+202
View File
@@ -0,0 +1,202 @@
Apache License
Version 2.0, January 2004
http://www.apache.org/licenses/
TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
1. Definitions.
"License" shall mean the terms and conditions for use, reproduction,
and distribution as defined by Sections 1 through 9 of this document.
"Licensor" shall mean the copyright owner or entity authorized by
the copyright owner that is granting the License.
"Legal Entity" shall mean the union of the acting entity and all
other entities that control, are controlled by, or are under common
control with that entity. For the purposes of this definition,
"control" means (i) the power, direct or indirect, to cause the
direction or management of such entity, whether by contract or
otherwise, or (ii) ownership of fifty percent (50%) or more of the
outstanding shares, or (iii) beneficial ownership of such entity.
"You" (or "Your") shall mean an individual or Legal Entity
exercising permissions granted by this License.
"Source" form shall mean the preferred form for making modifications,
including but not limited to software source code, documentation
source, and configuration files.
"Object" form shall mean any form resulting from mechanical
transformation or translation of a Source form, including but
not limited to compiled object code, generated documentation,
and conversions to other media types.
"Work" shall mean the work of authorship, whether in Source or
Object form, made available under the License, as indicated by a
copyright notice that is included in or attached to the work
(an example is provided in the Appendix below).
"Derivative Works" shall mean any work, whether in Source or Object
form, that is based on (or derived from) the Work and for which the
editorial revisions, annotations, elaborations, or other modifications
represent, as a whole, an original work of authorship. For the purposes
of this License, Derivative Works shall not include works that remain
separable from, or merely link (or bind by name) to the interfaces of,
the Work and Derivative Works thereof.
"Contribution" shall mean any work of authorship, including
the original version of the Work and any modifications or additions
to that Work or Derivative Works thereof, that is intentionally
submitted to Licensor for inclusion in the Work by the copyright owner
or by an individual or Legal Entity authorized to submit on behalf of
the copyright owner. For the purposes of this definition, "submitted"
means any form of electronic, verbal, or written communication sent
to the Licensor or its representatives, including but not limited to
communication on electronic mailing lists, source code control systems,
and issue tracking systems that are managed by, or on behalf of, the
Licensor for the purpose of discussing and improving the Work, but
excluding communication that is conspicuously marked or otherwise
designated in writing by the copyright owner as "Not a Contribution."
"Contributor" shall mean Licensor and any individual or Legal Entity
on behalf of whom a Contribution has been received by Licensor and
subsequently incorporated within the Work.
2. Grant of Copyright License. Subject to the terms and conditions of
this License, each Contributor hereby grants to You a perpetual,
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
copyright license to reproduce, prepare Derivative Works of,
publicly display, publicly perform, sublicense, and distribute the
Work and such Derivative Works in Source or Object form.
3. Grant of Patent License. Subject to the terms and conditions of
this License, each Contributor hereby grants to You a perpetual,
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
(except as stated in this section) patent license to make, have made,
use, offer to sell, sell, import, and otherwise transfer the Work,
where such license applies only to those patent claims licensable
by such Contributor that are necessarily infringed by their
Contribution(s) alone or by combination of their Contribution(s)
with the Work to which such Contribution(s) was submitted. If You
institute patent litigation against any entity (including a
cross-claim or counterclaim in a lawsuit) alleging that the Work
or a Contribution incorporated within the Work constitutes direct
or contributory patent infringement, then any patent licenses
granted to You under this License for that Work shall terminate
as of the date such litigation is filed.
4. Redistribution. You may reproduce and distribute copies of the
Work or Derivative Works thereof in any medium, with or without
modifications, and in Source or Object form, provided that You
meet the following conditions:
(a) You must give any other recipients of the Work or
Derivative Works a copy of this License; and
(b) You must cause any modified files to carry prominent notices
stating that You changed the files; and
(c) You must retain, in the Source form of any Derivative Works
that You distribute, all copyright, patent, trademark, and
attribution notices from the Source form of the Work,
excluding those notices that do not pertain to any part of
the Derivative Works; and
(d) If the Work includes a "NOTICE" text file as part of its
distribution, then any Derivative Works that You distribute must
include a readable copy of the attribution notices contained
within such NOTICE file, excluding those notices that do not
pertain to any part of the Derivative Works, in at least one
of the following places: within a NOTICE text file distributed
as part of the Derivative Works; within the Source form or
documentation, if provided along with the Derivative Works; or,
within a display generated by the Derivative Works, if and
wherever such third-party notices normally appear. The contents
of the NOTICE file are for informational purposes only and
do not modify the License. You may add Your own attribution
notices within Derivative Works that You distribute, alongside
or as an addendum to the NOTICE text from the Work, provided
that such additional attribution notices cannot be construed
as modifying the License.
You may add Your own copyright statement to Your modifications and
may provide additional or different license terms and conditions
for use, reproduction, or distribution of Your modifications, or
for any such Derivative Works as a whole, provided Your use,
reproduction, and distribution of the Work otherwise complies with
the conditions stated in this License.
5. Submission of Contributions. Unless You explicitly state otherwise,
any Contribution intentionally submitted for inclusion in the Work
by You to the Licensor shall be under the terms and conditions of
this License, without any additional terms or conditions.
Notwithstanding the above, nothing herein shall supersede or modify
the terms of any separate license agreement you may have executed
with Licensor regarding such Contributions.
6. Trademarks. This License does not grant permission to use the trade
names, trademarks, service marks, or product names of the Licensor,
except as required for reasonable and customary use in describing the
origin of the Work and reproducing the content of the NOTICE file.
7. Disclaimer of Warranty. Unless required by applicable law or
agreed to in writing, Licensor provides the Work (and each
Contributor provides its Contributions) on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
implied, including, without limitation, any warranties or conditions
of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
PARTICULAR PURPOSE. You are solely responsible for determining the
appropriateness of using or redistributing the Work and assume any
risks associated with Your exercise of permissions under this License.
8. Limitation of Liability. In no event and under no legal theory,
whether in tort (including negligence), contract, or otherwise,
unless required by applicable law (such as deliberate and grossly
negligent acts) or agreed to in writing, shall any Contributor be
liable to You for damages, including any direct, indirect, special,
incidental, or consequential damages of any character arising as a
result of this License or out of the use or inability to use the
Work (including but not limited to damages for loss of goodwill,
work stoppage, computer failure or malfunction, or any and all
other commercial damages or losses), even if such Contributor
has been advised of the possibility of such damages.
9. Accepting Warranty or Additional Liability. While redistributing
the Work or Derivative Works thereof, You may choose to offer,
and charge a fee for, acceptance of support, warranty, indemnity,
or other liability obligations and/or rights consistent with this
License. However, in accepting such obligations, You may act only
on Your own behalf and on Your sole responsibility, not on behalf
of any other Contributor, and only if You agree to indemnify,
defend, and hold each Contributor harmless for any liability
incurred by, or claims asserted against, such Contributor by reason
of your accepting any such warranty or additional liability.
END OF TERMS AND CONDITIONS
APPENDIX: How to apply the Apache License to your work.
To apply the Apache License to your work, attach the following
boilerplate notice, with the fields enclosed by brackets "[]"
replaced with your own identifying information. (Don't include
the brackets!) The text should be enclosed in the appropriate
comment syntax for the file format. We also recommend that a
file or class name and description of purpose be included on the
same "printed page" as the copyright notice for easier
identification within third-party archives.
Copyright [yyyy] [name of copyright owner]
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
+26 -13
View File
@@ -223,9 +223,22 @@ func NewBLE() *BLE {
} }
//Enable //Enable
func (b *BLE) Enable(w *app.Window) { func (b *BLE) Enable(view uintptr) {
log.Printf("ble.Enable()") log.Printf("ble.Enable()")
w.RegisterFragment("st/wow/git/ble/BlessedConnect") // view == 0 is Gio's detach signal (GioView.onDestroyView sends
// ViewEvent{View: 0} when the view is destroyed, e.g. the activity
// going away on a recents-wipe). Nothing to register; passing the null
// ref on would abort in JNI (GetObjectClass on null). A re-attach
// arrives as a fresh event with a live view. Callers that forward the
// event unfiltered are protected by this guard.
if view == 0 {
return
}
setJVM(app.JavaVM())
runInJVM(func(env *JNIEnv) {
log.Printf("ble.Enable(): inside runInJVM()")
C.registerFragment(env, (C.jobject)(unsafe.Pointer(view)))
})
} }
// Go callbacks from Java // Go callbacks from Java
@@ -237,8 +250,6 @@ func Java_st_wow_git_ble_BlessedConnect_installComplete(env *C.JNIEnv, class C.j
log.Printf("BlessedConnect object is nil!") log.Printf("BlessedConnect object is nil!")
} }
gBLE.handle.BlessedConnect = (C.NewGlobalRef)(env,b) gBLE.handle.BlessedConnect = (C.NewGlobalRef)(env,b)
h := app.PlatformHandle()
setJVM(h.JVM)
if C.enabled(env, gBLE.handle.BlessedConnect) == C.JNI_TRUE { if C.enabled(env, gBLE.handle.BlessedConnect) == C.JNI_TRUE {
gBLE.handle.state = STATE_ON gBLE.handle.state = STATE_ON
gBLE.ready = true gBLE.ready = true
@@ -324,7 +335,7 @@ func goOnDiscoverService(cid, cuuid *C.char, serv C.jobject) {
} }
//export goOnDiscoverCharacteristic //export goOnDiscoverCharacteristic
func goOnDiscoverCharacteristic(cid, csuuid *C.char, serv C.jobject, ccuuid *C.char, char C.jobject) { func goOnDiscoverCharacteristic(cid, csuuid *C.char, serv C.jobject, ccuuid *C.char, characteristic C.jobject) {
id := C.GoString(cid) id := C.GoString(cid)
suuid := C.GoString(csuuid) suuid := C.GoString(csuuid)
cuuid := C.GoString(ccuuid) cuuid := C.GoString(ccuuid)
@@ -337,34 +348,34 @@ func goOnDiscoverCharacteristic(cid, csuuid *C.char, serv C.jobject, ccuuid *C.c
service: serv, service: serv,
} }
characteristic := Characteristic{ ch := Characteristic{
UUID: cuuid, UUID: cuuid,
characteristic: char, characteristic: characteristic,
} }
gBLE.events <- DiscoverCharacteristicEvent{ gBLE.events <- DiscoverCharacteristicEvent{
Peripheral: peripheral, Peripheral: peripheral,
Service: service, Service: service,
Characteristic: characteristic, Characteristic: ch,
Gatt: gatt.Characteristic{cuuid}, Gatt: gatt.Characteristic{cuuid},
} }
} }
//export goOnCharacteristicChanged //export goOnCharacteristicChanged
func goOnCharacteristicChanged(cid, ccuuid *C.char, char C.jobject, cvalue *C.char, length C.jint) { func goOnCharacteristicChanged(cid, ccuuid *C.char, characteristic C.jobject, cvalue *C.char, length C.jint) {
id := C.GoString(cid) id := C.GoString(cid)
cuuid := C.GoString(ccuuid) cuuid := C.GoString(ccuuid)
peripheral := gBLE.retrievePeripheral(id) peripheral := gBLE.retrievePeripheral(id)
characteristic := Characteristic{ ch := Characteristic{
UUID: cuuid, UUID: cuuid,
characteristic: char, characteristic: characteristic,
} }
gBLE.events <- UpdateValueEvent{ gBLE.events <- UpdateValueEvent{
Peripheral: peripheral, Peripheral: peripheral,
Characteristic: characteristic, Characteristic: ch,
Data: C.GoBytes(unsafe.Pointer(cvalue), length), Data: C.GoBytes(unsafe.Pointer(cvalue), length),
} }
} }
@@ -384,7 +395,9 @@ func (b *BLE) retrievePeripheral(id string, devs ...C.jobject) Peripheral {
for i, item := range gBLE.peripherals.items { for i, item := range gBLE.peripherals.items {
if item.p.Identifier == id { if item.p.Identifier == id {
peripheral = item.p peripheral = item.p
peripheral.peripheral = dev if dev != 0 {
peripheral.peripheral = dev
}
found = true found = true
gBLE.peripherals.items[i].p = peripheral gBLE.peripherals.items[i].p = peripheral
break break
+10 -11
View File
@@ -8,8 +8,6 @@ import (
"time" "time"
"unsafe" "unsafe"
"gioui.org/app"
"git.wow.st/gmp/ble/gatt" "git.wow.st/gmp/ble/gatt"
"git.wow.st/gmp/ble/ns" "git.wow.st/gmp/ble/ns"
) )
@@ -158,7 +156,7 @@ func (p Peripheral) DiscoverCharacteristics(serv Service) {
//SetNotifyValue subscribes to a characteristic //SetNotifyValue subscribes to a characteristic
func (p Peripheral) SetNotifyValue(c Characteristic) { func (p Peripheral) SetNotifyValue(c Characteristic) {
p.p.SetNotifyValue(1, c) p.p.SetNotifyValue((ns.BOOL)(true), c)
} }
//NewBLE returns a pointer to a BLE struct after setting up the OS //NewBLE returns a pointer to a BLE struct after setting up the OS
@@ -204,12 +202,13 @@ func NewBLE() *BLE {
} }
//Enable is not required for Darwin. //Enable is not required for Darwin.
func (b *BLE) Enable(w *app.Window) { func (b *BLE) Enable(v uintptr) {
} }
// Core Bluetooth callback functions // Core Bluetooth callback functions
func didUpdateState(c *ns.CBCentralManager) { func didUpdateState(d ns.CBDelegate, c *ns.CBCentralManager) {
fmt.Print("didUpdateState")
b := cdLookup[c.Ptr()] b := cdLookup[c.Ptr()]
st := c.CBManager.State() st := c.CBManager.State()
if st == (ns.CBManagerState)(ns.CBManagerStatePoweredOn) { if st == (ns.CBManagerState)(ns.CBManagerStatePoweredOn) {
@@ -232,7 +231,7 @@ func didUpdateState(c *ns.CBCentralManager) {
b.events <- UpdateStateEvent{State: b.stringState()} b.events <- UpdateStateEvent{State: b.stringState()}
} }
func didDiscoverPeripheral(c *ns.CBCentralManager, p *ns.CBPeripheral, d *ns.NSDictionary, rssi *ns.NSNumber) { func didDiscoverPeripheral(d_ ns.CBDelegate, c *ns.CBCentralManager, p *ns.CBPeripheral, d *ns.NSDictionary, rssi *ns.NSNumber) {
b := cdLookup[c.Ptr()] b := cdLookup[c.Ptr()]
peripheral := newPeripheral(p) peripheral := newPeripheral(p)
peripheral.RSSI = (int)(rssi.IntValue()) peripheral.RSSI = (int)(rssi.IntValue())
@@ -249,7 +248,7 @@ func _didDiscoverPeripheral(b *BLE, peripheral Peripheral) {
} }
} }
func didConnectPeripheral(c *ns.CBCentralManager, p *ns.CBPeripheral) { func didConnectPeripheral(d ns.CBDelegate, c *ns.CBCentralManager, p *ns.CBPeripheral) {
fmt.Printf("Did connect peripheral\n") fmt.Printf("Did connect peripheral\n")
b := cdLookup[c.Ptr()] b := cdLookup[c.Ptr()]
@@ -282,7 +281,7 @@ func didConnectPeripheral(c *ns.CBCentralManager, p *ns.CBPeripheral) {
fmt.Printf("Go: didConnectPeripheral returning\n") fmt.Printf("Go: didConnectPeripheral returning\n")
} }
func didDisconnectPeripheral(c *ns.CBCentralManager, p *ns.CBPeripheral, e *ns.NSError) { func didDisconnectPeripheral(d ns.CBDelegate, c *ns.CBCentralManager, p *ns.CBPeripheral, e *ns.NSError) {
fmt.Printf("Did disconnect peripheral\n"); fmt.Printf("Did disconnect peripheral\n");
b := cdLookup[c.Ptr()] b := cdLookup[c.Ptr()]
@@ -313,7 +312,7 @@ func didDisconnectPeripheral(c *ns.CBCentralManager, p *ns.CBPeripheral, e *ns.N
}() }()
} }
func didDiscoverServices(p *ns.CBPeripheral, e *ns.NSError) { func didDiscoverServices(d ns.CBDelegate, p *ns.CBPeripheral, e *ns.NSError) {
b := pdLookup[p.Ptr()] b := pdLookup[p.Ptr()]
fmt.Printf("Did discover services\n") fmt.Printf("Did discover services\n")
p.Services().ObjectEnumerator().ForIn(func(o *ns.Id) bool { p.Services().ObjectEnumerator().ForIn(func(o *ns.Id) bool {
@@ -329,7 +328,7 @@ func didDiscoverServices(p *ns.CBPeripheral, e *ns.NSError) {
fmt.Printf("Go: didDiscoverServices returning\n") fmt.Printf("Go: didDiscoverServices returning\n")
} }
func didDiscoverCharacteristics(p *ns.CBPeripheral, s *ns.CBService, e *ns.NSError) { func didDiscoverCharacteristics(d ns.CBDelegate, p *ns.CBPeripheral, s *ns.CBService, e *ns.NSError) {
b := pdLookup[p.Ptr()] b := pdLookup[p.Ptr()]
fmt.Printf("Did discover characteristics\n") fmt.Printf("Did discover characteristics\n")
s.Characteristics().ObjectEnumerator().ForIn(func(o *ns.Id) bool { s.Characteristics().ObjectEnumerator().ForIn(func(o *ns.Id) bool {
@@ -347,7 +346,7 @@ func didDiscoverCharacteristics(p *ns.CBPeripheral, s *ns.CBService, e *ns.NSErr
fmt.Printf("Go: didDiscoverCharacteristics returning\n") fmt.Printf("Go: didDiscoverCharacteristics returning\n")
} }
func didUpdateValue(p *ns.CBPeripheral, chr *ns.CBCharacteristic, e *ns.NSError) { func didUpdateValue(d ns.CBDelegate, p *ns.CBPeripheral, chr *ns.CBCharacteristic, e *ns.NSError) {
b := pdLookup[p.Ptr()] b := pdLookup[p.Ptr()]
v := chr.Value() v := chr.Value()
b.events <-UpdateValueEvent{ b.events <-UpdateValueEvent{
BIN
View File
Binary file not shown.
+14
View File
@@ -0,0 +1,14 @@
//go:generate rm -rf blessed-android timber
//go:generate git clone https://github.com/weliem/blessed-android
//go:generate git -C blessed-android checkout be74941512ba08e33eb1fd6d0030ad4a4d332365
//go:generate blessed-android/gradlew -x lint -x lintVitalRelease -x test -x check -p blessed-android build
//go:generate mv blessed-android/blessed/build/intermediates/full_jar/release/createFullJarRelease/full.jar ../blessed-full.jar
//go:generate rm -rf blessed-android
//go:generate git clone https://github.com/JakeWharton/timber.git
//go:generate git -C timber checkout 4.7.1
//go:generate timber/gradlew -x lint -x lintVitalRelease -x test -x check -p timber build
//go:generate mv timber/timber/build/intermediates/intermediate-jars/release/classes.jar ../timber.jar
//go:generate rm -rf timber
package depjars
+1 -1
View File
@@ -2,4 +2,4 @@ module git.wow.st/gmp/ble
go 1.13 go 1.13
require gioui.org v0.0.0-20191126175243-2ca2e5462f16 require gioui.org v0.0.0-20200829162755-829ee4559c5a
+8
View File
@@ -1,6 +1,12 @@
dmitri.shuralyov.com/gpu/mtl v0.0.0-20190408044501-666a987793e9/go.mod h1:H6x//7gZCb22OMCxBHrMx7a5I7Hp++hsVxbQ4BYO7hU= dmitri.shuralyov.com/gpu/mtl v0.0.0-20190408044501-666a987793e9/go.mod h1:H6x//7gZCb22OMCxBHrMx7a5I7Hp++hsVxbQ4BYO7hU=
gioui.org v0.0.0-20191126175243-2ca2e5462f16 h1:p31rtmKm51xpj2QtqGNlljAyHEP1oStU8MDRl2Dv7Gs= gioui.org v0.0.0-20191126175243-2ca2e5462f16 h1:p31rtmKm51xpj2QtqGNlljAyHEP1oStU8MDRl2Dv7Gs=
gioui.org v0.0.0-20191126175243-2ca2e5462f16/go.mod h1:KqFFi2Dq5gYA3FJ0sDOt8OBXoMsuxMtE8v2f0JExXAY= gioui.org v0.0.0-20191126175243-2ca2e5462f16/go.mod h1:KqFFi2Dq5gYA3FJ0sDOt8OBXoMsuxMtE8v2f0JExXAY=
gioui.org v0.0.0-20200612151431-2dc19a36959c h1:sGUKyRMv2bbfbsRyG8ghOI12l+WCGta+PivmznjuLgo=
gioui.org v0.0.0-20200612151431-2dc19a36959c/go.mod h1:AHI9rFr6AEEHCb8EPVtb/p5M+NMJRKH58IOp8O3Je04=
gioui.org v0.0.0-20200619121558-88ced59dad93 h1:Llh4Tigdbu++FrRXL/KzqDHnH2Q5LPmAEk0djh6NLwk=
gioui.org v0.0.0-20200619121558-88ced59dad93/go.mod h1:jiUwifN9cRl/zmco43aAqh0aV+s9GbhG13KcD+gEpkU=
gioui.org v0.0.0-20200829162755-829ee4559c5a h1:mciXRGzQwU0TbgCILZzl6L1nYIWU31lDGIb+8RYige8=
gioui.org v0.0.0-20200829162755-829ee4559c5a/go.mod h1:Y+uS7hHMvku1Q+ooaoq6fYD5B2LGoT8JtFgvmYmRzTw=
github.com/BurntSushi/xgb v0.0.0-20160522181843-27f122750802/go.mod h1:IVnqGOEym/WlBOVXweHU+Q+/VP0lqqI8lqeDx9IjBqo= github.com/BurntSushi/xgb v0.0.0-20160522181843-27f122750802/go.mod h1:IVnqGOEym/WlBOVXweHU+Q+/VP0lqqI8lqeDx9IjBqo=
github.com/go-gl/glfw v0.0.0-20190409004039-e6da0acd62b1/go.mod h1:vR7hzQXu2zJy9AVAgeJqvqgH9Q5CA+iKCZ2gyEVpxRU= github.com/go-gl/glfw v0.0.0-20190409004039-e6da0acd62b1/go.mod h1:vR7hzQXu2zJy9AVAgeJqvqgH9Q5CA+iKCZ2gyEVpxRU=
golang.org/x/crypto v0.0.0-20190308221718-c2843e01d9a2/go.mod h1:djNgcEr1/C05ACkg1iLfiJU5Ep61QUkGW8qpdssI0+w= golang.org/x/crypto v0.0.0-20190308221718-c2843e01d9a2/go.mod h1:djNgcEr1/C05ACkg1iLfiJU5Ep61QUkGW8qpdssI0+w=
@@ -9,6 +15,7 @@ golang.org/x/exp v0.0.0-20190306152737-a1d7652674e8/go.mod h1:CJ0aWSM057203Lf6IL
golang.org/x/exp v0.0.0-20191002040644-a1355ae1e2c3/go.mod h1:NOZ3BPKG0ec/BKJQgnvsSFpcKLM5xXVWnvZS97DWHgE= golang.org/x/exp v0.0.0-20191002040644-a1355ae1e2c3/go.mod h1:NOZ3BPKG0ec/BKJQgnvsSFpcKLM5xXVWnvZS97DWHgE=
golang.org/x/image v0.0.0-20190227222117-0694c2d4d067/go.mod h1:kZ7UVZpmo3dzQBMxlp+ypCbDeSB+sBbTgSJuh5dn5js= golang.org/x/image v0.0.0-20190227222117-0694c2d4d067/go.mod h1:kZ7UVZpmo3dzQBMxlp+ypCbDeSB+sBbTgSJuh5dn5js=
golang.org/x/image v0.0.0-20190802002840-cff245a6509b/go.mod h1:FeLwcggjj3mMvU+oOTbSwawSJRM1uh48EjtB4UJZlP0= golang.org/x/image v0.0.0-20190802002840-cff245a6509b/go.mod h1:FeLwcggjj3mMvU+oOTbSwawSJRM1uh48EjtB4UJZlP0=
golang.org/x/image v0.0.0-20200618115811-c13761719519/go.mod h1:FeLwcggjj3mMvU+oOTbSwawSJRM1uh48EjtB4UJZlP0=
golang.org/x/mobile v0.0.0-20190719004257-d2bd2a29d028/go.mod h1:E/iHnbuqvinMTCcRqshq8CkpyQDoeVncDDYHnLhea+o= golang.org/x/mobile v0.0.0-20190719004257-d2bd2a29d028/go.mod h1:E/iHnbuqvinMTCcRqshq8CkpyQDoeVncDDYHnLhea+o=
golang.org/x/mod v0.1.0/go.mod h1:0QHyrYULN0/3qlju5TqG8bIK38QM8yzMo5ekMj3DlcY= golang.org/x/mod v0.1.0/go.mod h1:0QHyrYULN0/3qlju5TqG8bIK38QM8yzMo5ekMj3DlcY=
golang.org/x/net v0.0.0-20190404232315-eb5bcb51f2a3/go.mod h1:t9HGtf8HONx5eT2rtn7q6eTqICYqUVnKs3thJo3Qplg= golang.org/x/net v0.0.0-20190404232315-eb5bcb51f2a3/go.mod h1:t9HGtf8HONx5eT2rtn7q6eTqICYqUVnKs3thJo3Qplg=
@@ -19,6 +26,7 @@ golang.org/x/sys v0.0.0-20190312061237-fead79001313/go.mod h1:h1NjWce9XRLGQEsW7w
golang.org/x/sys v0.0.0-20190412213103-97732733099d/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20190412213103-97732733099d/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
golang.org/x/sys v0.0.0-20190813064441-fde4db37ae7a h1:aYOabOQFp6Vj6W1F80affTUvO9UxmJRx8K0gsfABByQ= golang.org/x/sys v0.0.0-20190813064441-fde4db37ae7a h1:aYOabOQFp6Vj6W1F80affTUvO9UxmJRx8K0gsfABByQ=
golang.org/x/sys v0.0.0-20190813064441-fde4db37ae7a/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20190813064441-fde4db37ae7a/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
golang.org/x/sys v0.0.0-20200124204421-9fbb57f87de9/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
golang.org/x/text v0.3.0/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ= golang.org/x/text v0.3.0/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ=
golang.org/x/tools v0.0.0-20190927191325-030b2cf1153e/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo= golang.org/x/tools v0.0.0-20190927191325-030b2cf1153e/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo=
golang.org/x/xerrors v0.0.0-20190717185122-a985d3407aa7/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= golang.org/x/xerrors v0.0.0-20190717185122-a985d3407aa7/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0=
+26
View File
@@ -3,6 +3,32 @@
#include <android/log.h> #include <android/log.h>
#include "_cgo_export.h" #include "_cgo_export.h"
void
registerFragment(JNIEnv *env, jobject view) {
if (view == NULL) {
// Detach signal (Gio sends ViewEvent{View: 0} when the view is
// destroyed, e.g. the activity going away on a recents-wipe).
// The Go side already filters these; this guard keeps the JNI
// calls safe if one ever slips through (GetObjectClass on null
// aborts the process).
return;
}
jclass cls = (*env)->GetObjectClass(env, view);
jmethodID mid = (*env)->GetMethodID(env, cls, "getContext", "()Landroid/content/Context;");
jobject ctx = (*env)->CallObjectMethod(env, view, mid);
cls = (*env)->GetObjectClass(env, ctx);
mid = (*env)->GetMethodID(env, cls, "getClassLoader", "()Ljava/lang/ClassLoader;");
jobject loader = (*env)->CallObjectMethod(env, ctx, mid);
cls = (*env)->GetObjectClass(env, loader);
mid = (*env)->GetMethodID(env, cls, "findClass", "(Ljava/lang/String;)Ljava/lang/Class;");
jstring str = (*env)->NewStringUTF(env, "st/wow/git/ble/BlessedConnect");
cls = (*env)->CallObjectMethod(env, loader, mid, str);
mid = (*env)->GetMethodID(env, cls, "<init>", "()V");
jobject inst = (*env)->NewObject(env, cls, mid);
mid = (*env)->GetMethodID(env, cls, "register", "(Landroid/view/View;)V");
(*env)->CallVoidMethod(env, inst, mid, view);
}
jboolean jboolean
enabled(JNIEnv *env, jobject b) { enabled(JNIEnv *env, jobject b) {
jclass cls = (*env)->GetObjectClass(env, b); jclass cls = (*env)->GetObjectClass(env, b);
+1
View File
@@ -1,5 +1,6 @@
#include <jni.h> #include <jni.h>
void registerFragment(JNIEnv *env, jobject view);
jboolean enabled(JNIEnv *env, jobject p); jboolean enabled(JNIEnv *env, jobject p);
void scan(JNIEnv *env, jobject b); void scan(JNIEnv *env, jobject b);
void stopScan(JNIEnv *env, jobject b); void stopScan(JNIEnv *env, jobject b);
+32 -16
View File
@@ -15,27 +15,20 @@ import "C"
import ( import (
"unsafe" "unsafe"
"fmt"
) )
//export CBDelegateCentralManagerDidUpdateState
func CBDelegateCentralManagerDidUpdateState(o unsafe.Pointer, central unsafe.Pointer) {
CBDelegateMux.RLock()
cb := CBDelegateLookup[o].CentralManagerDidUpdateState
CBDelegateMux.RUnlock()
if cb == nil { return }
a1 := &CBCentralManager{}; a1.ptr = central
cb(a1)
}
//export CBDelegateCentralManagerDidConnectPeripheral //export CBDelegateCentralManagerDidConnectPeripheral
func CBDelegateCentralManagerDidConnectPeripheral(o unsafe.Pointer, central unsafe.Pointer, peripheral unsafe.Pointer) { func CBDelegateCentralManagerDidConnectPeripheral(o unsafe.Pointer, central unsafe.Pointer, peripheral unsafe.Pointer) {
CBDelegateMux.RLock() CBDelegateMux.RLock()
cb := CBDelegateLookup[o].CentralManagerDidConnectPeripheral cb := CBDelegateLookup[o].CentralManagerDidConnectPeripheral
CBDelegateMux.RUnlock() CBDelegateMux.RUnlock()
if cb == nil { return } if cb == nil { return }
self := CBDelegate{}
self.ptr = o
a1 := &CBCentralManager{}; a1.ptr = central a1 := &CBCentralManager{}; a1.ptr = central
a2 := &CBPeripheral{}; a2.ptr = peripheral a2 := &CBPeripheral{}; a2.ptr = peripheral
cb(a1, a2) cb(self, a1, a2)
} }
//export CBDelegateCentralManagerDidDisconnectPeripheral //export CBDelegateCentralManagerDidDisconnectPeripheral
@@ -44,10 +37,12 @@ func CBDelegateCentralManagerDidDisconnectPeripheral(o unsafe.Pointer, central u
cb := CBDelegateLookup[o].CentralManagerDidDisconnectPeripheral cb := CBDelegateLookup[o].CentralManagerDidDisconnectPeripheral
CBDelegateMux.RUnlock() CBDelegateMux.RUnlock()
if cb == nil { return } if cb == nil { return }
self := CBDelegate{}
self.ptr = o
a1 := &CBCentralManager{}; a1.ptr = central a1 := &CBCentralManager{}; a1.ptr = central
a2 := &CBPeripheral{}; a2.ptr = peripheral a2 := &CBPeripheral{}; a2.ptr = peripheral
a3 := &NSError{}; a3.ptr = error a3 := &NSError{}; a3.ptr = error
cb(a1, a2, a3) cb(self, a1, a2, a3)
} }
//export CBDelegateCentralManagerDidDiscoverPeripheral //export CBDelegateCentralManagerDidDiscoverPeripheral
@@ -56,11 +51,26 @@ func CBDelegateCentralManagerDidDiscoverPeripheral(o unsafe.Pointer, central uns
cb := CBDelegateLookup[o].CentralManagerDidDiscoverPeripheral cb := CBDelegateLookup[o].CentralManagerDidDiscoverPeripheral
CBDelegateMux.RUnlock() CBDelegateMux.RUnlock()
if cb == nil { return } if cb == nil { return }
self := CBDelegate{}
self.ptr = o
a1 := &CBCentralManager{}; a1.ptr = central a1 := &CBCentralManager{}; a1.ptr = central
a2 := &CBPeripheral{}; a2.ptr = peripheral a2 := &CBPeripheral{}; a2.ptr = peripheral
a3 := &NSDictionary{}; a3.ptr = advertisementData a3 := &NSDictionary{}; a3.ptr = advertisementData
a4 := &NSNumber{}; a4.ptr = RSSI a4 := &NSNumber{}; a4.ptr = RSSI
cb(a1, a2, a3, a4) cb(self, a1, a2, a3, a4)
}
//export CBDelegateCentralManagerDidUpdateState
func CBDelegateCentralManagerDidUpdateState(o unsafe.Pointer, central unsafe.Pointer) {
fmt.Print("CentralManagerDidUpdateState")
CBDelegateMux.RLock()
cb := CBDelegateLookup[o].CentralManagerDidUpdateState
CBDelegateMux.RUnlock()
if cb == nil { return }
self := CBDelegate{}
self.ptr = o
a1 := &CBCentralManager{}; a1.ptr = central
cb(self, a1)
} }
//export CBDelegatePeripheralDidDiscoverServices //export CBDelegatePeripheralDidDiscoverServices
@@ -69,9 +79,11 @@ func CBDelegatePeripheralDidDiscoverServices(o unsafe.Pointer, peripheral unsafe
cb := CBDelegateLookup[o].PeripheralDidDiscoverServices cb := CBDelegateLookup[o].PeripheralDidDiscoverServices
CBDelegateMux.RUnlock() CBDelegateMux.RUnlock()
if cb == nil { return } if cb == nil { return }
self := CBDelegate{}
self.ptr = o
a1 := &CBPeripheral{}; a1.ptr = peripheral a1 := &CBPeripheral{}; a1.ptr = peripheral
a2 := &NSError{}; a2.ptr = error a2 := &NSError{}; a2.ptr = error
cb(a1, a2) cb(self, a1, a2)
} }
//export CBDelegatePeripheralDidDiscoverCharacteristicsForService //export CBDelegatePeripheralDidDiscoverCharacteristicsForService
@@ -80,10 +92,12 @@ func CBDelegatePeripheralDidDiscoverCharacteristicsForService(o unsafe.Pointer,
cb := CBDelegateLookup[o].PeripheralDidDiscoverCharacteristicsForService cb := CBDelegateLookup[o].PeripheralDidDiscoverCharacteristicsForService
CBDelegateMux.RUnlock() CBDelegateMux.RUnlock()
if cb == nil { return } if cb == nil { return }
self := CBDelegate{}
self.ptr = o
a1 := &CBPeripheral{}; a1.ptr = peripheral a1 := &CBPeripheral{}; a1.ptr = peripheral
a2 := &CBService{}; a2.ptr = service a2 := &CBService{}; a2.ptr = service
a3 := &NSError{}; a3.ptr = error a3 := &NSError{}; a3.ptr = error
cb(a1, a2, a3) cb(self, a1, a2, a3)
} }
//export CBDelegatePeripheralDidUpdateValueForCharacteristic //export CBDelegatePeripheralDidUpdateValueForCharacteristic
@@ -92,8 +106,10 @@ func CBDelegatePeripheralDidUpdateValueForCharacteristic(o unsafe.Pointer, perip
cb := CBDelegateLookup[o].PeripheralDidUpdateValueForCharacteristic cb := CBDelegateLookup[o].PeripheralDidUpdateValueForCharacteristic
CBDelegateMux.RUnlock() CBDelegateMux.RUnlock()
if cb == nil { return } if cb == nil { return }
self := CBDelegate{}
self.ptr = o
a1 := &CBPeripheral{}; a1.ptr = peripheral a1 := &CBPeripheral{}; a1.ptr = peripheral
a2 := &CBCharacteristic{}; a2.ptr = characteristic a2 := &CBCharacteristic{}; a2.ptr = characteristic
a3 := &NSError{}; a3.ptr = error a3 := &NSError{}; a3.ptr = error
cb(a1, a2, a3) cb(self, a1, a2, a3)
} }
+51467 -52409
View File
File diff suppressed because it is too large Load Diff
+2 -2
View File
@@ -1,6 +1,6 @@
inputfiles: inputfiles:
- /System/Library/Frameworks/Foundation.framework/Headers/Foundation.h - /Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/System/Library/Frameworks/Foundation.framework/Headers/Foundation.h
- /System/Library/Frameworks/CoreBluetooth.framework/Headers/CoreBluetooth.h - /Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/System/Library/Frameworks/CoreBluetooth.framework/Headers/CoreBluetooth.h
classes: classes:
- NSObject - NSObject
BIN
View File
Binary file not shown.