Skip to content

Commit

Permalink
Update MyEditText.java
Browse files Browse the repository at this point in the history
  • Loading branch information
gilangadhan committed May 10, 2019
1 parent e4f3024 commit 4f17be8
Showing 1 changed file with 1 addition and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -38,9 +38,6 @@ protected void onDraw(Canvas canvas) {
// Menambahkan hint pada editText
setHint("Masukkan nama Anda");

// Manambahkan tipe input pada editText
setInputType(InputType.TYPE_TEXT_FLAG_CAP_SENTENCES);

// Menambahkan text aligmnet pada editText
setTextAlignment(TEXT_ALIGNMENT_VIEW_START);
}
Expand Down Expand Up @@ -73,6 +70,7 @@ public boolean onTouch(View v, MotionEvent event) {
if (event.getAction() == MotionEvent.ACTION_DOWN) {
mClearButtonImage = ResourcesCompat.getDrawable(getResources(), R.drawable.ic_close_black_24dp, null);
showClearButton();
return true;
} else if (event.getAction() == MotionEvent.ACTION_UP) {
mClearButtonImage = ResourcesCompat.getDrawable(getResources(), R.drawable.ic_close_black_24dp, null);
if (getText() != null) {
Expand Down

0 comments on commit 4f17be8

Please sign in to comment.