Skip to content

Commit

Permalink
代码重构
Browse files Browse the repository at this point in the history
  • Loading branch information
wujiajun committed Apr 14, 2017
1 parent c268259 commit 3babf5c
Show file tree
Hide file tree
Showing 8 changed files with 109 additions and 0 deletions.
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
package com.wjj.easy.easyandroidHelper.common.base;

import com.wjj.easy.easyandroid.mvp.EasyBasePresenter;
import com.wjj.easy.easyandroid.mvp.EasyBaseView;

/**
* BaseView业务基类
* Created by wujiajun on 17/4/14.
*/

public interface BaseView<T extends EasyBasePresenter> extends EasyBaseView<T> {
void toast(String msg);

void showLoading();

void hiddenLoading();
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
package com.wjj.easy.easyandroidHelper.common.base;

import com.wjj.easy.easyandroid.mvp.EasyBasePresenter;

/**
* Fragment业务基类
* Created by wujiajun on 17/4/14.
*/

public interface BaseViewFrg<T extends EasyBasePresenter> extends BaseView<T> {
void setPresenter(T presenter);
}
10 changes: 10 additions & 0 deletions app/src/main/res/anim/roll_down.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
<?xml version="1.0" encoding="utf-8"?>
<set xmlns:android="http://schemas.android.com/apk/res/android">

<translate
android:duration="300"
android:fromYDelta="0.0"
android:interpolator="@android:anim/decelerate_interpolator"
android:toYDelta="100.0%p" />

</set>
10 changes: 10 additions & 0 deletions app/src/main/res/anim/roll_up.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
<?xml version="1.0" encoding="utf-8"?>
<set xmlns:android="http://schemas.android.com/apk/res/android">

<translate
android:duration="300"
android:fromYDelta="100.0%p"
android:interpolator="@android:anim/decelerate_interpolator"
android:toYDelta="0.0" />

</set>
16 changes: 16 additions & 0 deletions app/src/main/res/anim/slide_in_bottom.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
<?xml version="1.0" encoding="utf-8"?>
<set xmlns:android="http://schemas.android.com/apk/res/android"
android:interpolator="@android:interpolator/accelerate_decelerate"
>

<translate
android:duration="@android:integer/config_mediumAnimTime"
android:fromYDelta="100%p"
android:toYDelta="0" />

<alpha
android:duration="@android:integer/config_mediumAnimTime"
android:fromAlpha="0.95"
android:toAlpha="1" />

</set>
14 changes: 14 additions & 0 deletions app/src/main/res/anim/slide_out_bottom.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
<?xml version="1.0" encoding="utf-8"?>
<set xmlns:android="http://schemas.android.com/apk/res/android" >

<translate
android:duration="@android:integer/config_mediumAnimTime"
android:fromYDelta="0"
android:toYDelta="100%p" />

<alpha
android:duration="@android:integer/config_mediumAnimTime"
android:fromAlpha="1"
android:toAlpha="0.95" />

</set>
9 changes: 9 additions & 0 deletions app/src/main/res/drawable/bg_color_white_corners_10.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
<?xml version="1.0" encoding="utf-8"?>
<shape xmlns:android="http://schemas.android.com/apk/res/android"
android:dither="true"
android:shape="rectangle">

<solid android:color="@color/white" />
<corners android:radius="@dimen/padding_size_10" />

</shape>
21 changes: 21 additions & 0 deletions app/src/main/res/layout/dialog_loading.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:background="@drawable/bg_color_white_corners_10"
android:orientation="horizontal"
android:paddingBottom="@dimen/padding_size_15"
android:paddingLeft="@dimen/padding_size_25"
android:paddingRight="@dimen/padding_size_25"
android:paddingTop="@dimen/padding_size_15">

<TextView
android:id="@+id/tv_loading_text"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_gravity="center_vertical"
android:text="@string/app_loading"
android:textColor="@color/tab_text_normal"
android:textSize="@dimen/text_16sp" />

</LinearLayout>

0 comments on commit 3babf5c

Please sign in to comment.