2019-06-29 02:35:14 +02:00
|
|
|
package gq.cyuubi.lightswitch;
|
|
|
|
|
|
|
|
import android.os.Bundle;
|
|
|
|
import android.widget.TextView;
|
|
|
|
|
2019-06-29 15:35:24 +02:00
|
|
|
import androidx.appcompat.app.AppCompatActivity;
|
|
|
|
|
2019-06-29 02:35:14 +02:00
|
|
|
public class MainActivity extends AppCompatActivity {
|
|
|
|
|
|
|
|
static {
|
2019-06-29 15:35:24 +02:00
|
|
|
System.loadLibrary("lightswitch");
|
2019-06-29 02:35:14 +02:00
|
|
|
}
|
|
|
|
|
|
|
|
@Override
|
|
|
|
protected void onCreate(Bundle savedInstanceState) {
|
|
|
|
super.onCreate(savedInstanceState);
|
|
|
|
setContentView(R.layout.activity_main);
|
|
|
|
|
|
|
|
// Example of a call to a native method
|
|
|
|
TextView tv = findViewById(R.id.sample_text);
|
|
|
|
tv.setText(stringFromJNI());
|
|
|
|
}
|
|
|
|
|
|
|
|
public native String stringFromJNI();
|
|
|
|
}
|