Android Zxing(二维码的生成,扫描,打开双关灯)
直接看效果:
首先导入依赖包,在源码处有,名字为libzxing的一个文件夹。
①布局文件
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:orientation="vertical">
<Button
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:onClick="scan"
android:text=