-
-
Save vekexasia/e2237075076a68780dc8 to your computer and use it in GitHub Desktop.
Post#1 Form EditText
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<com.andreabaccega.widget.FormEditText | |
xmlns:android="http://schemas.android.com/apk/res/android" | |
xmlns:editTextFormExample="http://schemas.android.com/apk/res/com.andreabaccega.edittextformexample" | |
android:id="@+id/et" | |
style="@android:style/Widget.EditText" | |
android:layout_width="match_parent" | |
android:layout_height="wrap_content" | |
android:hint="@string/hint_email" | |
android:inputType="textEmailAddress" | |
editTextFormExample:testType="email" /> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public void onClickValidate(View v) { | |
FormEditText fdt = (FormEditText) findViewById(R.id.et); | |
if (fdt.testValidity()) { | |
Toast.makeText(this, ":)", Toast.LENGTH_LONG).show(); | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment