This commit is contained in:
ligi 2016-10-28 02:18:20 +02:00
parent cc02abf014
commit 3a11b6ae4e
No known key found for this signature in database
GPG key ID: 8E81894010ABF23D
2 changed files with 6 additions and 9 deletions

View file

@ -58,7 +58,7 @@ internal class BarcodeUIController(rootView: View, private val barCode: BarCode?
}
fun setBarCodeSize(width: Int) {
private fun setBarCodeSize(width: Int) {
zoomOut.visibility = if (width < passViewHelper.fingerSize * 2) INVISIBLE else VISIBLE

View file

@ -46,7 +46,7 @@ class PassViewActivity : PassViewActivityBase() {
val pass = currentPass ?: // don't deal with invalid passes
return
BarcodeUIController(window.decorView, pass.barCode, this, passViewHelper)
BarcodeUIController(findViewById(android.R.id.content), pass.barCode, this, passViewHelper)
processImage(logo_img_view, PassBitmapDefinitions.BITMAP_LOGO, pass)
processImage(footer_img_view, PassBitmapDefinitions.BITMAP_FOOTER, pass)
@ -99,6 +99,10 @@ class PassViewActivity : PassViewActivityBase() {
AXT.at(this).disableRotation()
setContentView(R.layout.activity_pass_view)
val passExtrasView = layoutInflater.inflate(R.layout.pass_view_extra_data, passExtrasContainer, false)
passExtrasContainer.addView(passExtrasView)
}
override fun onResumeFragments() {
@ -108,13 +112,6 @@ class PassViewActivity : PassViewActivityBase() {
return
}
AXT.at(this).disableRotation()
setContentView(R.layout.activity_pass_view)
val passExtrasView = layoutInflater.inflate(R.layout.pass_view_extra_data, passExtrasContainer, false)
passExtrasContainer.addView(passExtrasView)
moreTextView.setOnClickListener {
if (back_fields.visibility == View.VISIBLE) {
back_fields.visibility = View.GONE