mirror of
https://github.com/jfoucry/Pilldroid.git
synced 2024-11-14 01:21:35 +01:00
fix aligment; fix bug in dialog result
This commit is contained in:
parent
21d8cce250
commit
09342383bb
1 changed files with 19 additions and 4 deletions
|
@ -323,7 +323,7 @@ public class MedicamentListActivity extends AppCompatActivity {
|
||||||
|
|
||||||
// Get Medoc from database
|
// Get Medoc from database
|
||||||
final Medicament scannedMedoc = dbMedoc.getMedocByCIP13(cip13);
|
final Medicament scannedMedoc = dbMedoc.getMedocByCIP13(cip13);
|
||||||
askToAddInDB(scannedMedoc);
|
askToAddInDB(scannedMedoc);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -340,9 +340,9 @@ public class MedicamentListActivity extends AppCompatActivity {
|
||||||
alertDialogBuilder.setCancelable(false)
|
alertDialogBuilder.setCancelable(false)
|
||||||
.setPositiveButton("OK", (dialog, id) -> {
|
.setPositiveButton("OK", (dialog, id) -> {
|
||||||
String cip13 = editText.getText().toString();
|
String cip13 = editText.getText().toString();
|
||||||
|
|
||||||
Medicament med = dbMedoc.getMedocByCIP13(cip13);
|
Medicament med = dbMedoc.getMedocByCIP13(cip13);
|
||||||
askToAddInDB(med);
|
askToAddInDB(med);
|
||||||
addMedToList(med);
|
|
||||||
})
|
})
|
||||||
.setNegativeButton("Cancel",
|
.setNegativeButton("Cancel",
|
||||||
(dialog, id) -> dialog.cancel());
|
(dialog, id) -> dialog.cancel());
|
||||||
|
@ -543,4 +543,19 @@ public class MedicamentListActivity extends AppCompatActivity {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/*
|
||||||
|
editText.addTextChangeListener( new TextWatcher() {
|
||||||
|
@Override
|
||||||
|
void afterTextChanged(Editable s){
|
||||||
|
|
||||||
|
}
|
||||||
|
void beforeTextChanged(CharSequence s, int start, int count, int after) {
|
||||||
|
|
||||||
|
}
|
||||||
|
void onTextChanged(CharSequence s, int start, int before, int count) {
|
||||||
|
|
||||||
|
}
|
||||||
|
});
|
||||||
|
*/
|
Loading…
Reference in a new issue