Preyea Regmi
4 years ago
8 changed files with 138 additions and 88 deletions
-
42app/src/main/java/com/gmeremit/online/gmeremittance_native/common/view/MAutoCompleteTextView.java
-
24app/src/main/java/com/gmeremit/online/gmeremittance_native/registerV2/presenter/RegisterV2Presenter.java
-
6app/src/main/java/com/gmeremit/online/gmeremittance_native/registerV2/presenter/RegisterV2PresenterInterface.java
-
103app/src/main/java/com/gmeremit/online/gmeremittance_native/registerV2/view/RegisterV2Activity.java
-
17app/src/main/res/layout/activity_register_v2.xml
-
11app/src/main/res/layout/item_list.xml
-
3app/src/main/res/values/attrs.xml
-
4app/src/main/res/values/styles.xml
@ -0,0 +1,42 @@ |
|||
package com.gmeremit.online.gmeremittance_native.common.view; |
|||
|
|||
import android.content.Context; |
|||
import android.content.res.Resources; |
|||
import android.content.res.TypedArray; |
|||
import android.util.AttributeSet; |
|||
import android.widget.AutoCompleteTextView; |
|||
|
|||
import androidx.appcompat.widget.AppCompatAutoCompleteTextView; |
|||
|
|||
import com.gmeremit.online.gmeremittance_native.R; |
|||
import com.gmeremit.online.gmeremittance_native.customwidgets.FontCache; |
|||
|
|||
public class MAutoCompleteTextView extends AppCompatAutoCompleteTextView { |
|||
|
|||
|
|||
public MAutoCompleteTextView(Context context) { |
|||
super(context); |
|||
init(context,null); |
|||
} |
|||
|
|||
public MAutoCompleteTextView(Context context, AttributeSet attrs) { |
|||
super(context, attrs); |
|||
init(context,null); |
|||
|
|||
} |
|||
|
|||
public MAutoCompleteTextView(Context context, AttributeSet attrs, int defStyleAttr) { |
|||
super(context, attrs, defStyleAttr); |
|||
init(context,null); |
|||
|
|||
} |
|||
|
|||
private void init(Context context, AttributeSet attrs) { |
|||
if (attrs != null) { |
|||
TypedArray a = getContext().obtainStyledAttributes(attrs, R.styleable.MAutoCompleteTextView); |
|||
String fontName = a.getString(R.styleable.MAutoCompleteTextView_autoTxtViewFontName); |
|||
setTypeface(FontCache.getTypeface(fontName, context)); |
|||
a.recycle(); |
|||
} |
|||
} |
|||
} |
@ -0,0 +1,11 @@ |
|||
<?xml version="1.0" encoding="utf-8"?> |
|||
<com.gmeremit.online.gmeremittance_native.common.view.MTextView |
|||
xmlns:android="http://schemas.android.com/apk/res/android" android:layout_width="match_parent" |
|||
android:ellipsize="end" |
|||
android:maxLines="1" |
|||
android:textSize="@dimen/_12ssp" |
|||
android:gravity="start" |
|||
android:padding="@dimen/_4sdp" |
|||
android:layout_height="match_parent"> |
|||
|
|||
</com.gmeremit.online.gmeremittance_native.common.view.MTextView> |
Write
Preview
Loading…
Cancel
Save
Reference in new issue