Browse Source

PennyTestModule framework made

master
Preyea Regmi 6 years ago
parent
commit
f76c672739
  1. BIN
      .idea/caches/build_file_checksums.ser
  2. 11
      app/src/main/AndroidManifest.xml
  3. 36
      app/src/main/java/com/gmeremit/online/gmeremittance_native/customwidgets/DepthTransformation.java
  4. 82
      app/src/main/java/com/gmeremit/online/gmeremittance_native/customwidgets/SwipeDisabledViewPager.java
  5. 33
      app/src/main/java/com/gmeremit/online/gmeremittance_native/customwidgets/ZoomOutTransformation.java
  6. 20
      app/src/main/java/com/gmeremit/online/gmeremittance_native/homeV2/view/HomeActivityV2.java
  7. 33
      app/src/main/java/com/gmeremit/online/gmeremittance_native/kycV2/adapter/PennyTestViewPagerAdapter.java
  8. 4
      app/src/main/java/com/gmeremit/online/gmeremittance_native/kycV2/view/KYCFormV2Activity.java
  9. 266
      app/src/main/java/com/gmeremit/online/gmeremittance_native/kycV2/view/pennytest/PennyTestActivity.java
  10. 38
      app/src/main/java/com/gmeremit/online/gmeremittance_native/kycV2/view/pennytest/PennyTestModalFragment.java
  11. 39
      app/src/main/java/com/gmeremit/online/gmeremittance_native/kycV2/view/pennytest/PennyTestOperationFragment.java
  12. 39
      app/src/main/java/com/gmeremit/online/gmeremittance_native/kycV2/view/pennytest/PennyTestPromptFragment.java
  13. 2
      app/src/main/java/com/gmeremit/online/gmeremittance_native/transactionhistoryV2/view/TransactionFragmentV2.java
  14. 6
      app/src/main/res/anim/slide_down.xml
  15. 5
      app/src/main/res/anim/slide_up.xml
  16. 2
      app/src/main/res/layout/activity_kyc_v2.xml
  17. 82
      app/src/main/res/layout/activity_penny_test.xml
  18. 2
      app/src/main/res/layout/activity_transaction_history_v2.xml
  19. 25
      app/src/main/res/layout/fragment_penny_test_operation.xml
  20. 9
      app/src/main/res/layout/fragment_penny_test_prompt.xml
  21. 16
      app/src/main/res/values/styles.xml

BIN
.idea/caches/build_file_checksums.ser

11
app/src/main/AndroidManifest.xml

@ -561,11 +561,16 @@
<activity
android:name="com.theartofdev.edmodo.cropper.CropImageActivity"
android:theme="@style/Base.Theme.AppCompat" />
<activity android:name=".withdrawV2.view.WithdrawV2Activity"
<activity
android:name=".withdrawV2.view.WithdrawV2Activity"
android:screenOrientation="portrait"
android:theme="@style/AppTheme.NoActionBar"
android:windowSoftInputMode="stateAlwaysHidden"/>
android:windowSoftInputMode="stateAlwaysHidden" />
<activity android:name=".kycV2.view.pennytest.PennyTestActivity"
android:screenOrientation="portrait"
android:windowSoftInputMode="stateAlwaysHidden"
android:excludeFromRecents="true"
android:theme="@style/ActivityDialog"></activity>
</application>
</manifest>

36
app/src/main/java/com/gmeremit/online/gmeremittance_native/customwidgets/DepthTransformation.java

@ -0,0 +1,36 @@
package com.gmeremit.online.gmeremittance_native.customwidgets;
import android.support.v4.view.ViewPager;
import android.view.View;
public class DepthTransformation implements ViewPager.PageTransformer {
@Override
public void transformPage(View page, float position) {
if (position < -1){ // [-Infinity,-1)
// This page is way off-screen to the left.
page.setAlpha(0);
}
else if (position <= 0){ // [-1,0]
page.setAlpha(1);
page.setTranslationX(0);
page.setScaleX(1);
page.setScaleY(1);
}
else if (position <= 1){ // (0,1]
page.setTranslationX(-position*page.getWidth());
page.setAlpha(1-Math.abs(position));
page.setScaleX(1-Math.abs(position));
page.setScaleY(1-Math.abs(position));
}
else { // (1,+Infinity]
// This page is way off-screen to the right.
page.setAlpha(0);
}
}
}

82
app/src/main/java/com/gmeremit/online/gmeremittance_native/customwidgets/SwipeDisabledViewPager.java

@ -5,25 +5,87 @@ import android.content.Context;
import android.support.v4.view.ViewPager;
import android.util.AttributeSet;
import android.view.MotionEvent;
import android.view.animation.DecelerateInterpolator;
import android.view.animation.Interpolator;
import android.widget.Scroller;
import java.lang.reflect.Field;
public class SwipeDisabledViewPager extends ViewPager {
private FixedSpeedScroller mScroller = null;
public SwipeDisabledViewPager(Context context) {
super(context);
init();
}
public SwipeDisabledViewPager(Context context, AttributeSet attrs) {
super(context, attrs);
init();
}
@Override
public boolean onInterceptTouchEvent(MotionEvent ev) {
return false;
}
@Override
public boolean onTouchEvent(MotionEvent ev) {
return false;
}
private void init() {
try {
Class<?> viewpager = ViewPager.class;
Field scroller = viewpager.getDeclaredField("mScroller");
scroller.setAccessible(true);
mScroller = new FixedSpeedScroller(getContext(),
new DecelerateInterpolator());
scroller.set(this, mScroller);
} catch (Exception ignored) {
}
}
// @Override
// public boolean onInterceptTouchEvent(MotionEvent ev) {
//
// return false;
// }
//
// @Override
// public boolean onTouchEvent(MotionEvent ev) {
// return false;
// }
/*
* Set the factor by which the duration will change
*/
public void setScrollDuration(int duration) {
mScroller.setScrollDuration(duration);
}
private class FixedSpeedScroller extends Scroller {
private int mDuration = 500;
public FixedSpeedScroller(Context context) {
super(context);
}
public FixedSpeedScroller(Context context, Interpolator interpolator) {
super(context, interpolator);
}
public FixedSpeedScroller(Context context, Interpolator interpolator, boolean flywheel) {
super(context, interpolator, flywheel);
}
@Override
public void startScroll(int startX, int startY, int dx, int dy, int duration) {
// Ignore received duration, use fixed one instead
super.startScroll(startX, startY, dx, dy, mDuration);
}
@Override
public void startScroll(int startX, int startY, int dx, int dy) {
// Ignore received duration, use fixed one instead
super.startScroll(startX, startY, dx, dy, mDuration);
}
public void setScrollDuration(int duration) {
mDuration = duration;
}
}
}

33
app/src/main/java/com/gmeremit/online/gmeremittance_native/customwidgets/ZoomOutTransformation.java

@ -0,0 +1,33 @@
package com.gmeremit.online.gmeremittance_native.customwidgets;
import android.support.annotation.NonNull;
import android.support.v4.view.ViewPager;
import android.view.View;
public class ZoomOutTransformation implements ViewPager.PageTransformer {
private static final float MIN_SCALE = 0.65f;
private static final float MIN_ALPHA = 0.3f;
@Override
public void transformPage(@NonNull View page, float position) {
if (position <-1){
page.setAlpha(0);
}
else if (position <=1){
page.setScaleX(Math.max(MIN_SCALE,1-Math.abs(position)));
page.setScaleY(Math.max(MIN_SCALE,1-Math.abs(position)));
page.setAlpha(Math.max(MIN_ALPHA,1-Math.abs(position)));
}
else {
page.setAlpha(0);
}
}
}

20
app/src/main/java/com/gmeremit/online/gmeremittance_native/homeV2/view/HomeActivityV2.java

@ -31,6 +31,7 @@ import com.gmeremit.online.gmeremittance_native.homeV2.HomeParentViewContractV2;
import com.gmeremit.online.gmeremittance_native.homeV2.presenter.HomeV2Presenter;
import com.gmeremit.online.gmeremittance_native.homeV2.presenter.HomeV2PresenterInterface;
import com.gmeremit.online.gmeremittance_native.int_notification.view.IntNotificationView;
import com.gmeremit.online.gmeremittance_native.kycV2.view.pennytest.PennyTestActivity;
import com.gmeremit.online.gmeremittance_native.load_more.view.LoadMoreActivity;
import com.gmeremit.online.gmeremittance_native.recipientV2.view.recipientlisting.RecipientListingV2Activity;
import com.gmeremit.online.gmeremittance_native.settings.view.SettingsView;
@ -40,7 +41,6 @@ import com.gmeremit.online.gmeremittance_native.static_pages.view.SupportActivit
import com.gmeremit.online.gmeremittance_native.transactionhistoryV2.view.TransactionHistoryActivityV2;
import com.gmeremit.online.gmeremittance_native.user_profile.view.ProfileActivity;
import com.gmeremit.online.gmeremittance_native.utils.Utils;
import com.gmeremit.online.gmeremittance_native.walletstatementV2.view.WalletStatementV2Activity;
import com.gmeremit.online.gmeremittance_native.withdrawV2.view.WithdrawV2Activity;
import com.text.drawable.TextDrawable;
@ -269,14 +269,22 @@ public class HomeActivityV2 extends BaseActivity implements HomeParentViewContra
@Override
public void showWalletStatment() {
String unverifiedMessage = presenter.checkIfUserVerified();
if (unverifiedMessage == null)
startActivity(new Intent(getApplicationContext(), WalletStatementV2Activity.class));
else
showPopUpMessage(unverifiedMessage, CustomAlertDialog.AlertType.ALERT, null);
// String unverifiedMessage = presenter.checkIfUserVerified();
// if (unverifiedMessage == null)
// startActivity(new Intent(getApplicationContext(), WalletStatementV2Activity.class));
// else
// showPopUpMessage(unverifiedMessage, CustomAlertDialog.AlertType.ALERT, null);
// showPennyTestModalFragment();
showPennyTestView();
}
private void showPennyTestView() {
startActivity(new Intent(this,PennyTestActivity.class));
}
@Override
public void showTransactionStatementView() {
String unverifiedMessage = presenter.checkIfUserVerified();

33
app/src/main/java/com/gmeremit/online/gmeremittance_native/kycV2/adapter/PennyTestViewPagerAdapter.java

@ -0,0 +1,33 @@
package com.gmeremit.online.gmeremittance_native.kycV2.adapter;
import android.support.v4.app.Fragment;
import android.support.v4.app.FragmentManager;
import android.support.v4.app.FragmentPagerAdapter;
import java.util.ArrayList;
import java.util.List;
public class PennyTestViewPagerAdapter extends FragmentPagerAdapter {
private List<Fragment> fraglist;
public PennyTestViewPagerAdapter(FragmentManager fm) {
super(fm);
fraglist=new ArrayList<>();
}
@Override
public Fragment getItem(int position) {
return fraglist.get(position);
}
public void addFragments(List<Fragment> data)
{
fraglist=data;
}
@Override
public int getCount() {
return fraglist.size();
}
}

4
app/src/main/java/com/gmeremit/online/gmeremittance_native/kycV2/view/KYCFormV2Activity.java

@ -16,12 +16,10 @@ import android.widget.TextView;
import com.gmeremit.online.gmeremittance_native.R;
import com.gmeremit.online.gmeremittance_native.base.BaseActivity;
import com.gmeremit.online.gmeremittance_native.customwidgets.SwipeDisabledViewPager;
import com.gmeremit.online.gmeremittance_native.kycV2.KYCV2ActionListener;
import com.gmeremit.online.gmeremittance_native.kycV2.adapter.KycViewPagerAdapter;
import com.gmeremit.online.gmeremittance_native.kycV2.presenter.KYCV2Presenter;
import com.gmeremit.online.gmeremittance_native.kycV2.presenter.KYCV2PresenterInterface;
import com.gmeremit.online.gmeremittance_native.kycV2.view.pennytest.PennyTestModalFragment;
import com.gmeremit.online.gmeremittance_native.kycV2.view.view1.KYCView1Fragment;
import com.gmeremit.online.gmeremittance_native.kycV2.view.view2.KYCView2Fragment;
import com.gmeremit.online.gmeremittance_native.kycV2.view.view3.KYCView3Fragment;
@ -37,7 +35,7 @@ public class KYCFormV2Activity extends BaseActivity implements KYCV2ActionListen
public static final String USER_DOB_BUNDLE_KEY = "kycStatusUserDobBundleKey";
@BindView(R.id.kycFormViewPager)
SwipeDisabledViewPager viewPager;
ViewPager viewPager;
@BindView(R.id.kycTabLayout)
TabLayout tabLayout;

266
app/src/main/java/com/gmeremit/online/gmeremittance_native/kycV2/view/pennytest/PennyTestActivity.java

@ -0,0 +1,266 @@
package com.gmeremit.online.gmeremittance_native.kycV2.view.pennytest;
import android.animation.Animator;
import android.animation.AnimatorListenerAdapter;
import android.animation.AnimatorSet;
import android.animation.ObjectAnimator;
import android.animation.ValueAnimator;
import android.graphics.drawable.GradientDrawable;
import android.os.Handler;
import android.support.v4.app.Fragment;
import android.support.v4.content.ContextCompat;
import android.support.v4.view.ViewCompat;
import android.support.v4.view.ViewPager;
import android.os.Bundle;
import android.util.Log;
import android.view.View;
import android.view.ViewGroup;
import android.view.Window;
import android.view.animation.AccelerateDecelerateInterpolator;
import android.view.animation.Interpolator;
import android.widget.Button;
import android.widget.ProgressBar;
import com.gmeremit.online.gmeremittance_native.R;
import com.gmeremit.online.gmeremittance_native.base.BaseActivity;
import com.gmeremit.online.gmeremittance_native.customwidgets.ZoomOutTransformation;
import com.gmeremit.online.gmeremittance_native.kycV2.adapter.PennyTestViewPagerAdapter;
import java.util.ArrayList;
import java.util.List;
import butterknife.BindView;
import butterknife.ButterKnife;
public class PennyTestActivity extends BaseActivity implements View.OnClickListener, ViewPager.OnPageChangeListener {
@BindView(R.id.progressbar_login)
ProgressBar progressbar_login;
@BindView(R.id.btn_submit)
Button submitBtn;
@BindView(R.id.iv_back)
View iv_back;
@BindView(R.id.penny_test_view_pager)
ViewPager penntTestViewPager;
public String buttonText;
private AnimatorSet mMorphingAnimatorSet=null;
private boolean mIsMorphingInProgress=false;
private Interpolator interpolator=new AccelerateDecelerateInterpolator();
private int originalButtonWidth;
private boolean isLoadingInProgress=false;
private static float DEFAULT_CORNER_RADIUS;
private List<Fragment> fragments=new ArrayList<>();
private PennyTestViewPagerAdapter viewPagerAdapter;
@Override
protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.activity_penny_test);
ButterKnife.bind(this);
Window window = getWindow();
if (window != null) {
window.getAttributes().windowAnimations = R.style.SlideInAnimation;
window.setBackgroundDrawableResource(R.drawable.ic_rounded_grey_bg_with_inset);
window.setLayout(ViewGroup.LayoutParams.MATCH_PARENT, ViewGroup.LayoutParams.MATCH_PARENT);
}
initialize();
setupViewPager(true);
}
private void setupViewPager(boolean action) {
if(action)
fragments.add(new PennyTestPromptFragment());
fragments.add(new PennyTestOperationFragment());
viewPagerAdapter=new PennyTestViewPagerAdapter(getSupportFragmentManager());
viewPagerAdapter.addFragments(fragments);
penntTestViewPager.setPageTransformer(true,new ZoomOutTransformation());
penntTestViewPager.addOnPageChangeListener(this);
penntTestViewPager.setAdapter(viewPagerAdapter);
onPageSelected(0);
}
private void initialize() {
DEFAULT_CORNER_RADIUS=35*getResources().getDisplayMetrics().density;
progressbar_login.getIndeterminateDrawable().setColorFilter(ContextCompat.getColor(this,android.R.color.white), android.graphics.PorterDuff.Mode.MULTIPLY);
ViewCompat.setTranslationZ(progressbar_login, 100);
progressbar_login.setVisibility(View.GONE);
}
@Override
protected void onStart() {
super.onStart();
submitBtn.setOnClickListener(this);
iv_back.setOnClickListener(this);
}
@Override
protected void onStop() {
super.onStop();
submitBtn.setOnClickListener(null);
iv_back.setOnClickListener(null);
}
private void morphButtonIntoProgressBar()
{
GradientDrawable mGradientDrawable = (GradientDrawable) submitBtn.getBackground();
buttonText = submitBtn.getText().toString();
ObjectAnimator cornerAnimation =
ObjectAnimator.ofFloat(mGradientDrawable,
"cornerRadius",
DEFAULT_CORNER_RADIUS,
submitBtn.getHeight());
originalButtonWidth= submitBtn.getWidth();
ValueAnimator widthAnimation = ValueAnimator.ofInt(submitBtn.getWidth(), submitBtn.getHeight());
widthAnimation.addUpdateListener(valueAnimator -> {
int val = (Integer) valueAnimator.getAnimatedValue();
ViewGroup.LayoutParams layoutParams = submitBtn.getLayoutParams();
layoutParams.width = val;
submitBtn.setLayoutParams(layoutParams);
});
mMorphingAnimatorSet = new AnimatorSet();
mMorphingAnimatorSet.setDuration(330);
mMorphingAnimatorSet.setInterpolator(interpolator);
mMorphingAnimatorSet.playTogether(cornerAnimation, widthAnimation);
mMorphingAnimatorSet.addListener(new AnimatorListenerAdapter() {
@Override
public void onAnimationStart(Animator animation) {
super.onAnimationStart(animation);
mIsMorphingInProgress = true;
isLoadingInProgress=true;
submitBtn.setText("");
}
@Override
public void onAnimationEnd(Animator animation) {
mIsMorphingInProgress = false;
// ViewCompat.setTranslationZ(progressbar_login, 100);
progressbar_login.setVisibility(View.VISIBLE);
}
});
mMorphingAnimatorSet.start();
}
public void morphProgressBarIntoButton(Runnable callback)
{
GradientDrawable mGradientDrawable = (GradientDrawable) submitBtn.getBackground();
ObjectAnimator cornerAnimation =
ObjectAnimator.ofFloat(mGradientDrawable,
"cornerRadius",
submitBtn.getHeight(),
DEFAULT_CORNER_RADIUS);
ValueAnimator widthAnimation = ValueAnimator.ofInt(submitBtn.getHeight(), originalButtonWidth);
widthAnimation.addUpdateListener(valueAnimator -> {
int val = (Integer) valueAnimator.getAnimatedValue();
ViewGroup.LayoutParams layoutParams = submitBtn.getLayoutParams();
layoutParams.width = val;
submitBtn.setLayoutParams(layoutParams);
});
mMorphingAnimatorSet = new AnimatorSet();
mMorphingAnimatorSet.setDuration(330);
mMorphingAnimatorSet.setInterpolator(interpolator);
mMorphingAnimatorSet.playTogether(cornerAnimation, widthAnimation);
mMorphingAnimatorSet.addListener(new AnimatorListenerAdapter() {
@Override
public void onAnimationStart(Animator animation) {
super.onAnimationStart(animation);
mIsMorphingInProgress = true;
// ViewCompat.setTranslationZ(progressbar_login, 0);
progressbar_login.setVisibility(View.GONE);
}
@Override
public void onAnimationEnd(Animator animation) {
mIsMorphingInProgress = false;
submitBtn.setText(buttonText);
isLoadingInProgress=false;
if(callback!=null)
callback.run();
}
});
mMorphingAnimatorSet.start();
}
@Override
public void onClick(View v) {
switch(v.getId())
{
case R.id.btn_submit:
morphButtonIntoProgressBar();
new Handler().postDelayed(()->morphProgressBarIntoButton(()->penntTestViewPager.setCurrentItem(1,true)),3000);
break;
case R.id.iv_back:
onBackPressed();
break;
}
}
@Override
public void onPageScrolled(int i, float v, int i1) {
}
@Override
public void onPageSelected(int i) {
Fragment currentFragment=fragments.get(i);
if(currentFragment instanceof PennyTestPromptFragment)
{
onPennyTestPromptPageSelected();
}
else
{
onPennyTestOperationPageSelected();
}
}
private void onPennyTestPromptPageSelected() {
Log.d("PennyTestViewPager","Page: Prompt Page Displayed");
submitBtn.setText("Proceed");
}
private void onPennyTestOperationPageSelected() {
Log.d("PennyTestViewPager","Page: Operation Page Displayed");
submitBtn.setText("Submit");
}
@Override
public void onPageScrollStateChanged(int i) {
}
}

38
app/src/main/java/com/gmeremit/online/gmeremittance_native/kycV2/view/pennytest/PennyTestModalFragment.java

@ -1,38 +0,0 @@
package com.gmeremit.online.gmeremittance_native.kycV2.view.pennytest;
import android.app.Dialog;
import android.graphics.Color;
import android.os.Bundle;
import android.support.annotation.NonNull;
import android.support.annotation.Nullable;
import android.support.design.widget.BottomSheetBehavior;
import android.support.design.widget.BottomSheetDialog;
import android.support.design.widget.BottomSheetDialogFragment;
import android.support.design.widget.CoordinatorLayout;
import android.support.v4.app.DialogFragment;
import android.support.v7.app.AlertDialog;
import android.view.LayoutInflater;
import android.view.View;
import android.view.ViewGroup;
import android.widget.TextView;
import com.gmeremit.online.gmeremittance_native.R;
import com.gmeremit.online.gmeremittance_native.customwidgets.UserLockBottomSheetBehavior;
import java.lang.reflect.Field;
public class PennyTestModalFragment extends DialogFragment {
@Override
public Dialog onCreateDialog(Bundle savedInstanceState) {
AlertDialog.Builder builder = new AlertDialog.Builder(getActivity());
View view = getActivity().getLayoutInflater().inflate(R.layout.dialog_country_listing, null);
builder.setView(view);
return builder.create();
}
}

39
app/src/main/java/com/gmeremit/online/gmeremittance_native/kycV2/view/pennytest/PennyTestOperationFragment.java

@ -0,0 +1,39 @@
package com.gmeremit.online.gmeremittance_native.kycV2.view.pennytest;
import android.os.Bundle;
import android.support.annotation.Nullable;
import android.view.LayoutInflater;
import android.view.View;
import android.view.ViewGroup;
import com.gmeremit.online.gmeremittance_native.R;
import com.gmeremit.online.gmeremittance_native.base.BaseFragment;
import butterknife.ButterKnife;
public class PennyTestOperationFragment extends BaseFragment {
@Override
public View onCreateView(LayoutInflater inflater, @Nullable ViewGroup container, @Nullable Bundle savedInstanceState) {
return inflater.inflate(R.layout.fragment_penny_test_operation, container, false);
}
@Override
public void onViewCreated(View view, @Nullable Bundle savedInstanceState) {
super.onViewCreated(view, savedInstanceState);
ButterKnife.bind(this, view);
init();
performDefaultAction(savedInstanceState);
}
private void init()
{
}
private void performDefaultAction(Bundle savedInstanceState) {
}
}

39
app/src/main/java/com/gmeremit/online/gmeremittance_native/kycV2/view/pennytest/PennyTestPromptFragment.java

@ -0,0 +1,39 @@
package com.gmeremit.online.gmeremittance_native.kycV2.view.pennytest;
import android.os.Bundle;
import android.support.annotation.Nullable;
import android.view.LayoutInflater;
import android.view.View;
import android.view.ViewGroup;
import com.gmeremit.online.gmeremittance_native.R;
import com.gmeremit.online.gmeremittance_native.base.BaseFragment;
import butterknife.ButterKnife;
public class PennyTestPromptFragment extends BaseFragment {
@Override
public View onCreateView(LayoutInflater inflater, @Nullable ViewGroup container, @Nullable Bundle savedInstanceState) {
return inflater.inflate(R.layout.fragment_penny_test_prompt, container, false);
}
@Override
public void onViewCreated(View view, @Nullable Bundle savedInstanceState) {
super.onViewCreated(view, savedInstanceState);
ButterKnife.bind(this, view);
init();
performDefaultAction(savedInstanceState);
}
private void init()
{
}
private void performDefaultAction(Bundle savedInstanceState) {
}
}

2
app/src/main/java/com/gmeremit/online/gmeremittance_native/transactionhistoryV2/view/TransactionFragmentV2.java

@ -84,8 +84,6 @@ public class TransactionFragmentV2 extends BaseFragment implements View.OnClickL
@Override
public void onDestroy() {
super.onDestroy();

6
app/src/main/res/anim/slide_down.xml

@ -1,4 +1,8 @@
<?xml version="1.0" encoding="utf-8"?>
<set xmlns:android="http://schemas.android.com/apk/res/android">
<set xmlns:android="http://schemas.android.com/apk/res/android" >
<translate android:fromYDelta="0%"
android:toYDelta="150%"
android:duration="250"
android:interpolator="@android:anim/accelerate_decelerate_interpolator"/>
</set>

5
app/src/main/res/anim/slide_up.xml

@ -1,4 +1,7 @@
<?xml version="1.0" encoding="utf-8"?>
<set xmlns:android="http://schemas.android.com/apk/res/android">
<translate android:fromYDelta="110%"
android:toYDelta="0%"
android:duration="250"
android:interpolator="@android:anim/accelerate_decelerate_interpolator"/>
</set>

2
app/src/main/res/layout/activity_kyc_v2.xml

@ -103,7 +103,7 @@
android:layout_height="match_parent"
android:fillViewport="true" >
<com.gmeremit.online.gmeremittance_native.customwidgets.SwipeDisabledViewPager
<android.support.v4.view.ViewPager
android:id="@+id/kycFormViewPager"
android:layout_width="match_parent"
android:layout_height="match_parent"/>

82
app/src/main/res/layout/activity_penny_test.xml

@ -0,0 +1,82 @@
<?xml version="1.0" encoding="utf-8"?>
<android.support.constraint.ConstraintLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:app="http://schemas.android.com/apk/res-auto"
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent"
android:orientation="vertical"
android:background="#fff"
android:layout_height="match_parent">
<ImageView
android:id="@+id/iv_back"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginStart="16dp"
android:layout_marginTop="16dp"
android:padding="10dp"
android:src="@drawable/ic_back"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toTopOf="parent" />
<com.gmeremit.online.gmeremittance_native.customwidgets.SwipeDisabledViewPager
android:id="@+id/penny_test_view_pager"
android:layout_width="match_parent"
android:layout_height="0dp"
android:layout_marginStart="8dp"
android:layout_marginEnd="8dp"
android:layout_marginBottom="8dp"
app:layout_constraintBottom_toTopOf="@+id/progressbar_login_container"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toBottomOf="@+id/iv_back" />
<FrameLayout
android:id="@+id/progressbar_login_container"
android:layout_width="match_parent"
android:layout_height="58dp"
android:layout_marginStart="8dp"
android:layout_marginEnd="8dp"
android:layout_marginBottom="8dp"
app:layout_constraintBottom_toTopOf="@+id/textView"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintStart_toStartOf="parent">
<com.gmeremit.online.gmeremittance_native.customwidgets.GmeButton
android:id="@+id/btn_submit"
android:layout_width="200dp"
android:layout_height="50dp"
android:layout_gravity="center"
android:layout_marginTop="4dp"
android:layout_marginBottom="4dp"
android:background="@drawable/red_morph_button_bg"
android:text="Proceed"
android:textAllCaps="false"
android:textColor="@color/white"
android:textSize="18sp" />
<ProgressBar
android:id="@+id/progressbar_login"
android:layout_width="40dp"
android:layout_height="40dp"
android:layout_gravity="center"
android:indeterminate="true" />
</FrameLayout>
<com.gmeremit.online.gmeremittance_native.customwidgets.GmeTextView
android:id="@+id/textView"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_gravity="center_horizontal"
android:layout_marginBottom="16dp"
android:gravity="center"
android:paddingTop="5dp"
android:paddingBottom="5dp"
android:text="Skip for now"
android:textSize="14sp"
app:layout_constraintBottom_toBottomOf="parent"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintStart_toStartOf="parent" />
</android.support.constraint.ConstraintLayout>

2
app/src/main/res/layout/activity_transaction_history_v2.xml

@ -170,7 +170,7 @@
</LinearLayout>
<com.gmeremit.online.gmeremittance_native.customwidgets.SwipeDisabledViewPager
<android.support.v4.view.ViewPager
android:id="@+id/transactionHistoryViewPager"
android:layout_width="match_parent"
android:layout_height="match_parent" />

25
app/src/main/res/layout/fragment_penny_test_operation.xml

@ -0,0 +1,25 @@
<?xml version="1.0" encoding="utf-8"?>
<android.support.constraint.ConstraintLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:background="@color/red"
xmlns:app="http://schemas.android.com/apk/res-auto">
<TextView
android:id="@+id/textView2"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginStart="8dp"
android:layout_marginTop="8dp"
android:layout_marginEnd="8dp"
android:layout_marginBottom="8dp"
android:textSize="21sp"
android:gravity="center"
android:textColor="@color/white"
android:text="Penny test is about to be completed"
app:layout_constraintBottom_toBottomOf="parent"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toTopOf="parent" />
</android.support.constraint.ConstraintLayout>

9
app/src/main/res/layout/fragment_penny_test.xml → app/src/main/res/layout/fragment_penny_test_prompt.xml

@ -2,19 +2,22 @@
<android.support.constraint.ConstraintLayout
xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:app="http://schemas.android.com/apk/res-auto"
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent"
android:background="@color/bluebg"
android:layout_height="match_parent">
<TextView
android:id="@+id/textView"
android:id="@+id/textView2"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginStart="8dp"
android:layout_marginTop="8dp"
android:layout_marginEnd="8dp"
android:layout_marginBottom="8dp"
android:text="Hello From Penny Test"
android:textSize="21sp"
android:gravity="center"
android:textColor="@color/white"
android:text="Penny test is an esstential step during kyc"
app:layout_constraintBottom_toBottomOf="parent"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintStart_toStartOf="parent"

16
app/src/main/res/values/styles.xml

@ -54,9 +54,23 @@
<style name="DatePickerButtonStyle">
<item name="android:textSize">15sp</item>
<item name="android:textColor">@color/darkgray</item>
<item name="android:textStyle">normal</item>
</style>
<style name="SlideInAnimation" >
<item name="android:windowEnterAnimation">@anim/slide_up</item>
<item name="android:windowExitAnimation">@anim/slide_down</item>
</style>
<style name="ActivityDialog" parent="Theme.AppCompat.Light.Dialog">
<item name="android:windowFrame">@null</item>
<item name="android:windowIsFloating">true</item>
<item name="android:windowIsTranslucent">true</item>
<item name="windowActionBar">false</item>
<item name="windowNoTitle">true</item>
<item name="android:background">@android:color/transparent</item>
</style>
</resources>
Loading…
Cancel
Save