| |
---|
| | import android.util.AndroidRuntimeException; |
---|
| | import android.widget.ImageView; |
---|
| | |
---|
| | import com.example.cosmosclient.R; |
---|
| | import com.example.cosmosclient.app.Cosmos; |
---|
| | import com.example.cosmosclient.entities.Group; |
---|
| | import com.google.zxing.BarcodeFormat; |
---|
| | import com.google.zxing.WriterException; |
---|
| | import com.journeyapps.barcodescanner.BarcodeEncoder; |
---|
| | |
---|
| |
---|
| | @Override |
---|
| | protected void onCreate(Bundle savedInstanceState) { |
---|
| | super.onCreate(savedInstanceState); |
---|
| | setContentView(R.layout.activity_display_qr); |
---|
| | //QRコード化する文字列 |
---|
| | // //現在のグループ情報を格納しているものからgIdを取得 |
---|
| | // Cosmos app = (Cosmos) getApplication(); |
---|
| | // Group curentGroup = app.getCurentGroup(); |
---|
| | // //元となるgIdを取得完了 |
---|
| | // String data = curentGroup.getgId(); |
---|
| | |
---|
| | //テスト値 |
---|
| | String data = "http://researchers.adm.konan-u.ac.jp/html/130_ja.html"; |
---|
| | //QRコード画像の大きさを指定(pixel) |
---|
| | int size = 500; |
---|
| | |
---|
| |
---|
| | |