Commit f9a8452e by jeffrey

修改完界面

parent 61a70773
......@@ -20,7 +20,7 @@ android {
buildToolsVersion "26.0.2"
defaultConfig {
applicationId "com.xf.weixinclick"
minSdkVersion 16
minSdkVersion 21
targetSdkVersion 25
versionCode 4
versionName "1.3"
......
package com.xf.weixinclick;
import android.app.ProgressDialog;
import android.graphics.Color;
import android.os.Bundle;
import android.support.annotation.Nullable;
import android.support.v7.app.AppCompatActivity;
import android.view.View;
import butterknife.ButterKnife;
......@@ -19,6 +21,7 @@ public abstract class BaseActivity extends AppCompatActivity {
protected void onCreate(@Nullable Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(getContentView());
setStatus();
myApplication.addActivity(this);
ButterKnife.bind(this);
initAction();
......@@ -51,4 +54,11 @@ public abstract class BaseActivity extends AppCompatActivity {
}
}
private void setStatus(){
View decorView = getWindow().getDecorView();
int option = View.SYSTEM_UI_FLAG_LAYOUT_FULLSCREEN
| View.SYSTEM_UI_FLAG_LAYOUT_STABLE;
decorView.setSystemUiVisibility(option);
getWindow().setStatusBarColor(Color.TRANSPARENT);
}
}
......@@ -8,8 +8,10 @@ import android.content.Context;
import android.content.Intent;
import android.content.pm.PackageInfo;
import android.content.pm.PackageManager;
import android.graphics.Color;
import android.os.BatteryManager;
import android.os.Build;
import android.support.v4.app.ActivityCompat;
import android.support.v7.app.NotificationCompat;
import android.text.TextUtils;
import android.util.Log;
......@@ -25,6 +27,8 @@ import com.xf.weixinclick.http.HttpClientApi;
import com.xf.weixinclick.http.HttpSubscriber;
import com.xf.weixinclick.receiver.WeChatStatus;
import com.xf.weixinclick.utils.SP;
import com.xf.weixinclick.view.WaveHelper;
import com.xf.weixinclick.view.WaveView;
import org.greenrobot.eventbus.EventBus;
......@@ -54,6 +58,10 @@ public class MainActivity extends BaseActivity {
@BindView(R.id.tv_version_name)
TextView tv_version_name;
@BindView(R.id.waveView)
WaveView mWaveView;
WaveHelper mWaveHelper;
@Override
int getContentView() {
return R.layout.activity_main;
......@@ -61,7 +69,11 @@ public class MainActivity extends BaseActivity {
@Override
void initAction() {
Log.d("fei","测试下魅族log");
int waveColor = ActivityCompat.getColor(MainActivity.this,R.color.wave);
mWaveView.setWaveColor(waveColor,waveColor);
mWaveHelper = new WaveHelper(mWaveView);
HeartBeatAction.get().start();
......@@ -175,5 +187,19 @@ public class MainActivity extends BaseActivity {
}
@Override
protected void onResume() {
super.onResume();
if (mWaveHelper != null){
mWaveHelper.start();
}
}
@Override
protected void onPause() {
super.onPause();
if (mWaveHelper != null) {
mWaveHelper.cancel();
}
}
}
......@@ -4,6 +4,7 @@ import android.content.Context;
import android.content.res.TypedArray;
import android.graphics.Rect;
import android.graphics.drawable.Drawable;
import android.support.v7.widget.AppCompatEditText;
import android.text.Editable;
import android.text.TextWatcher;
import android.text.method.HideReturnsTransformationMethod;
......@@ -21,7 +22,7 @@ import java.util.ArrayList;
import java.util.Collections;
public class CustomEditText extends EditText {
public class CustomEditText extends AppCompatEditText {
private static final String Tag = CustomEditText.class.getSimpleName();
/**
......
package com.xf.weixinclick.view;
/**
* Created by Li on 2017/7/12.
*/
import android.animation.Animator;
import android.animation.AnimatorSet;
import android.animation.ObjectAnimator;
import android.animation.ValueAnimator;
import android.view.animation.LinearInterpolator;
import java.util.ArrayList;
import java.util.List;
public class WaveHelper {
private WaveView mWaveView;
private AnimatorSet mAnimatorSet;
public WaveHelper(WaveView waveView) {
mWaveView = waveView;
initAnimation();
}
public void start() {
mWaveView.setShowWave(true);
if (mAnimatorSet != null) {
mAnimatorSet.start();
}
}
private void initAnimation() {
List<Animator> animators = new ArrayList<>();
// horizontal animation.
// wave waves infinitely.
ObjectAnimator waveShiftAnim = ObjectAnimator.ofFloat(
mWaveView, "waveShiftRatio", 0f, 1f);
waveShiftAnim.setRepeatCount(ValueAnimator.INFINITE);
waveShiftAnim.setDuration(4000);
waveShiftAnim.setInterpolator(new LinearInterpolator());
animators.add(waveShiftAnim);
// // vertical animation.
// // water level increases from 0 to center of WaveView
// ObjectAnimator waterLevelAnim = ObjectAnimator.ofFloat(
// mWaveView, "waterLevelRatio", 0f, 0.5f);
// waterLevelAnim.setDuration(10000);
// waterLevelAnim.setInterpolator(new DecelerateInterpolator());
// animators.add(waterLevelAnim);
// amplitude animation.
// wave grows big then grows small, repeatedly
ObjectAnimator amplitudeAnim = ObjectAnimator.ofFloat(
mWaveView, "amplitudeRatio", 0.07f, 0.08f);
amplitudeAnim.setRepeatCount(ValueAnimator.INFINITE);
amplitudeAnim.setRepeatMode(ValueAnimator.REVERSE);
amplitudeAnim.setDuration(5000);
amplitudeAnim.setInterpolator(new LinearInterpolator());
animators.add(amplitudeAnim);
mAnimatorSet = new AnimatorSet();
mAnimatorSet.playTogether(animators);
}
public void cancel() {
if (mAnimatorSet != null) {
// mAnimatorSet.cancel();
mAnimatorSet.end();
}
}
}
package com.xf.weixinclick.view;
/**
* Created by Li on 2017/7/12.
*/
/*
* Copyright (C) 2015, gelitenight(gelitenight@gmail.com).
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
import android.content.Context;
import android.graphics.Bitmap;
import android.graphics.BitmapShader;
import android.graphics.Canvas;
import android.graphics.Color;
import android.graphics.Matrix;
import android.graphics.Paint;
import android.graphics.Paint.Style;
import android.graphics.Shader;
import android.util.AttributeSet;
import android.view.View;
public class WaveView extends View {
/**
* +------------------------+
* |<--wave length-> |______
* | /\ | /\ | |
* | / \ | / \ | amplitude
* | / \ | / \ | |
* |/ \ |/ \|__|____
* | \ / | |
* | \ / | |
* | \ / | |
* | \/ | water level
* | | |
* | | |
* +------------------------+__|____
*/
private static final float DEFAULT_AMPLITUDE_RATIO = 0.05f;
private static final float DEFAULT_WATER_LEVEL_RATIO = 0.7f;
private static final float DEFAULT_WAVE_LENGTH_RATIO = 1.0f;
private static final float DEFAULT_WAVE_SHIFT_RATIO = 0.0f;
public static final int DEFAULT_BEHIND_WAVE_COLOR = Color.parseColor("#28FFFFFF");
public static final int DEFAULT_FRONT_WAVE_COLOR = Color.parseColor("#3CFFFFFF");
public static final ShapeType DEFAULT_WAVE_SHAPE = ShapeType.SQUARE;
public enum ShapeType {
CIRCLE,
SQUARE
}
// if true, the shader will display the wave
private boolean mShowWave;
// shader containing repeated waves
private BitmapShader mWaveShader;
// shader matrix
private Matrix mShaderMatrix;
// paint to draw wave
private Paint mViewPaint;
// paint to draw border
private Paint mBorderPaint;
private float mDefaultAmplitude;
private float mDefaultWaterLevel;
private float mDefaultWaveLength;
private double mDefaultAngularFrequency;
private float mAmplitudeRatio = DEFAULT_AMPLITUDE_RATIO;
private float mWaveLengthRatio = DEFAULT_WAVE_LENGTH_RATIO;
private float mWaterLevelRatio = DEFAULT_WATER_LEVEL_RATIO;
private float mWaveShiftRatio = DEFAULT_WAVE_SHIFT_RATIO;
private int mBehindWaveColor = DEFAULT_BEHIND_WAVE_COLOR;
private int mFrontWaveColor = DEFAULT_FRONT_WAVE_COLOR;
private ShapeType mShapeType = DEFAULT_WAVE_SHAPE;
public WaveView(Context context) {
super(context);
init();
}
public WaveView(Context context, AttributeSet attrs) {
super(context, attrs);
init();
}
public WaveView(Context context, AttributeSet attrs, int defStyle) {
super(context, attrs, defStyle);
init();
}
private void init() {
mShaderMatrix = new Matrix();
mViewPaint = new Paint();
mViewPaint.setAntiAlias(true);
}
public float getWaveShiftRatio() {
return mWaveShiftRatio;
}
/**
* Shift the wave horizontally according to <code>waveShiftRatio</code>.
*
* @param waveShiftRatio Should be 0 ~ 1. Default to be 0.
* Result of waveShiftRatio multiples width of WaveView is the length to shift.
*/
public void setWaveShiftRatio(float waveShiftRatio) {
if (mWaveShiftRatio != waveShiftRatio) {
mWaveShiftRatio = waveShiftRatio;
invalidate();
}
}
public float getWaterLevelRatio() {
return mWaterLevelRatio;
}
/**
* Set water level according to <code>waterLevelRatio</code>.
*
* @param waterLevelRatio Should be 0 ~ 1. Default to be 0.5.
* Ratio of water level to WaveView height.
*/
public void setWaterLevelRatio(float waterLevelRatio) {
if (mWaterLevelRatio != waterLevelRatio) {
mWaterLevelRatio = waterLevelRatio;
invalidate();
}
}
public float getAmplitudeRatio() {
return mAmplitudeRatio;
}
/**
* Set vertical size of wave according to <code>amplitudeRatio</code>
*
* @param amplitudeRatio Default to be 0.05. Result of amplitudeRatio + waterLevelRatio should be less than 1.
* Ratio of amplitude to height of WaveView.
*/
public void setAmplitudeRatio(float amplitudeRatio) {
if (mAmplitudeRatio != amplitudeRatio) {
mAmplitudeRatio = amplitudeRatio;
invalidate();
}
}
public float getWaveLengthRatio() {
return mWaveLengthRatio;
}
/**
* Set horizontal size of wave according to <code>waveLengthRatio</code>
*
* @param waveLengthRatio Default to be 1.
* Ratio of wave length to width of WaveView.
*/
public void setWaveLengthRatio(float waveLengthRatio) {
mWaveLengthRatio = waveLengthRatio;
}
public boolean isShowWave() {
return mShowWave;
}
public void setShowWave(boolean showWave) {
mShowWave = showWave;
}
public void setBorder(int width, int color) {
if (mBorderPaint == null) {
mBorderPaint = new Paint();
mBorderPaint.setAntiAlias(true);
mBorderPaint.setStyle(Style.STROKE);
}
mBorderPaint.setColor(color);
mBorderPaint.setStrokeWidth(width);
invalidate();
}
public void setWaveColor(int behindWaveColor, int frontWaveColor) {
mBehindWaveColor = behindWaveColor;
mFrontWaveColor = frontWaveColor;
if (getWidth() > 0 && getHeight() > 0) {
// need to recreate shader when color changed
mWaveShader = null;
createShader();
invalidate();
}
}
public void setShapeType(ShapeType shapeType) {
mShapeType = shapeType;
invalidate();
}
@Override
protected void onSizeChanged(int w, int h, int oldw, int oldh) {
super.onSizeChanged(w, h, oldw, oldh);
createShader();
}
/**
* Create the shader with default waves which repeat horizontally, and clamp vertically
*/
private void createShader() {
mDefaultAngularFrequency = 2.0f * Math.PI / DEFAULT_WAVE_LENGTH_RATIO / getWidth();
mDefaultAmplitude = getHeight() * DEFAULT_AMPLITUDE_RATIO;
mDefaultWaterLevel = getHeight() * DEFAULT_WATER_LEVEL_RATIO;
mDefaultWaveLength = getWidth();
Bitmap bitmap = Bitmap.createBitmap(getWidth(), getHeight(), Bitmap.Config.ARGB_8888);
Canvas canvas = new Canvas(bitmap);
Paint wavePaint = new Paint();
wavePaint.setStrokeWidth(2);
wavePaint.setAntiAlias(true);
// Draw default waves into the bitmap
// y=Asin(ωx+φ)+h
final int endX = getWidth() + 1;
final int endY = getHeight() + 1;
float[] waveY = new float[endX];
wavePaint.setColor(mBehindWaveColor);
for (int beginX = 0; beginX < endX; beginX++) {
double wx = beginX * mDefaultAngularFrequency;
float beginY = (float) (mDefaultWaterLevel + mDefaultAmplitude * Math.sin(wx));
canvas.drawLine(beginX, beginY, beginX, endY, wavePaint);
waveY[beginX] = beginY;
}
wavePaint.setColor(mFrontWaveColor);
final int wave2Shift = (int) (mDefaultWaveLength / 4);
for (int beginX = 0; beginX < endX; beginX++) {
canvas.drawLine(beginX, waveY[(beginX + wave2Shift) % endX], beginX, endY, wavePaint);
}
// use the bitamp to create the shader
mWaveShader = new BitmapShader(bitmap, Shader.TileMode.REPEAT, Shader.TileMode.CLAMP);
mViewPaint.setShader(mWaveShader);
}
@Override
protected void onDraw(Canvas canvas) {
// modify paint shader according to mShowWave state
if (mShowWave && mWaveShader != null) {
// first call after mShowWave, assign it to our paint
if (mViewPaint.getShader() == null) {
mViewPaint.setShader(mWaveShader);
}
// sacle shader according to mWaveLengthRatio and mAmplitudeRatio
// this decides the size(mWaveLengthRatio for width, mAmplitudeRatio for height) of waves
mShaderMatrix.setScale(
mWaveLengthRatio / DEFAULT_WAVE_LENGTH_RATIO,
mAmplitudeRatio / DEFAULT_AMPLITUDE_RATIO,
0,
mDefaultWaterLevel);
// translate shader according to mWaveShiftRatio and mWaterLevelRatio
// this decides the start position(mWaveShiftRatio for x, mWaterLevelRatio for y) of waves
mShaderMatrix.postTranslate(
mWaveShiftRatio * getWidth(),
(DEFAULT_WATER_LEVEL_RATIO - mWaterLevelRatio) * getHeight());
// assign matrix to invalidate the shader
mWaveShader.setLocalMatrix(mShaderMatrix);
float borderWidth = mBorderPaint == null ? 0f : mBorderPaint.getStrokeWidth();
switch (mShapeType) {
case CIRCLE:
if (borderWidth > 0) {
canvas.drawCircle(getWidth() / 2f, getHeight() / 2f,
(getWidth() - borderWidth) / 2f - 1f, mBorderPaint);
}
float radius = getWidth() / 2f - borderWidth;
canvas.drawCircle(getWidth() / 2f, getHeight() / 2f, radius, mViewPaint);
break;
case SQUARE:
if (borderWidth > 0) {
canvas.drawRect(
borderWidth / 2f,
borderWidth / 2f,
getWidth() - borderWidth / 2f - 0.5f,
getHeight() - borderWidth / 2f - 0.5f,
mBorderPaint);
}
canvas.drawRect(borderWidth, borderWidth, getWidth() - borderWidth,
getHeight() - borderWidth, mViewPaint);
break;
}
} else {
mViewPaint.setShader(null);
}
}
}
<?xml version="1.0" encoding="utf-8"?>
<ripple android:color="@android:color/white"
xmlns:android="http://schemas.android.com/apk/res/android">
<item >
<shape android:shape="rectangle">
<corners android:radius="3dp"/>
<solid android:color="#1c978b" />
</shape>
</item>
</ripple>
\ No newline at end of file
<?xml version="1.0" encoding="utf-8"?>
<ripple android:color="@android:color/white"
xmlns:android="http://schemas.android.com/apk/res/android">
<item >
<shape android:shape="rectangle">
<corners android:radius="50dp"/>
<solid android:color="#19a89b" />
</shape>
</item>
</ripple>
\ No newline at end of file
<?xml version="1.0" encoding="utf-8"?>
<shape android:shape="rectangle"
xmlns:android="http://schemas.android.com/apk/res/android">
<corners android:radius="3dp"/>
<solid android:color="#1c978b" />
</shape>
\ No newline at end of file
<?xml version="1.0" encoding="utf-8"?>
<shape android:shape="rectangle"
xmlns:android="http://schemas.android.com/apk/res/android">
<corners android:radius="50dp"/>
<stroke android:color="@android:color/white" android:width="1px"/>
<solid android:color="#11ffffff" />
</shape>
\ No newline at end of file
<?xml version="1.0" encoding="utf-8"?>
<android.support.design.widget.CoordinatorLayout xmlns:android="http://schemas.android.com/apk/res/android"
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:background="@drawable/bg"
android:fitsSystemWindows="true"
android:gravity="center_horizontal"
android:orientation="vertical">
<LinearLayout
android:layout_width="match_parent"
android:layout_height="match_parent"
android:gravity="center_horizontal"
android:orientation="vertical">
<ImageView
android:id="@+id/iv_click"
......@@ -23,39 +18,39 @@
<com.xf.weixinclick.customerview.CustomEditText
android:id="@+id/et_phone"
android:layout_width="match_parent"
android:layout_height="50dp"
android:layout_marginLeft="20dp"
android:layout_marginRight="20dp"
android:layout_marginTop="20dp"
android:background="#00000000"
android:layout_height="35dp"
android:layout_marginLeft="40dp"
android:layout_marginRight="40dp"
android:layout_marginTop="50dp"
android:background="@drawable/shape_edit_text"
android:drawablePadding="30dp"
android:gravity="center_vertical"
android:hint="输入号码"
android:hint="请输入用户名"
android:inputType="number"
android:paddingLeft="15dp"
android:paddingRight="15dp"
android:textColor="#a503d6"
android:textColorHint="#7d7d7d"
android:textSize="16sp" />
android:textColor="@android:color/white"
android:textColorHint="@android:color/white"
android:textSize="12sp" />
<com.xf.weixinclick.customerview.CustomEditText
android:id="@+id/et_pwd"
android:layout_marginTop="10dp"
android:layout_width="match_parent"
android:layout_height="50dp"
android:layout_marginLeft="20dp"
android:layout_marginRight="20dp"
android:background="#00000000"
android:layout_height="35dp"
android:layout_marginLeft="40dp"
android:layout_marginRight="40dp"
android:background="@drawable/shape_edit_text"
android:drawablePadding="30dp"
android:gravity="center_vertical"
android:hint="密码"
android:hint="请输入密码"
android:paddingLeft="15dp"
android:paddingRight="15dp"
android:password="true"
android:textColor="#a503d6"
android:textColorHint="#7d7d7d"
android:textSize="16sp" />
android:inputType="textPassword"
android:textColor="@android:color/white"
android:textColorHint="@android:color/white"
android:textSize="12sp" />
<View
android:layout_width="match_parent"
......@@ -64,14 +59,14 @@
android:layout_marginRight="20dp"
android:background="#7d7d7d" />
<TextView
<Button
android:id="@+id/btn_login"
android:background="@drawable/btn_login_bg_ripple"
android:layout_width="match_parent"
android:layout_height="40dp"
android:layout_height="35dp"
android:layout_marginLeft="40dp"
android:layout_marginRight="40dp"
android:layout_marginTop="35dp"
android:background="#a503d6"
android:gravity="center"
android:text="登录"
android:textColor="#fff"
......@@ -95,5 +90,4 @@
android:gravity="center"
android:text="设置"
android:visibility="gone" />
</LinearLayout>
</android.support.design.widget.CoordinatorLayout>
\ No newline at end of file
</LinearLayout>
\ No newline at end of file
<?xml version="1.0" encoding="utf-8"?>
<android.support.design.widget.CoordinatorLayout xmlns:android="http://schemas.android.com/apk/res/android"
<LinearLayout 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:layout_height="match_parent"
android:orientation="vertical">
<LinearLayout
android:orientation="vertical"
<RelativeLayout
android:fitsSystemWindows="true"
android:background="#19a99a"
android:layout_width="match_parent"
android:layout_height="match_parent">
android:layout_height="175dp">
<com.xf.weixinclick.view.WaveView
android:id="@+id/waveView"
android:layout_alignParentBottom="true"
android:layout_width="match_parent"
android:layout_height="100dp" />
<TextView
android:text="网家"
android:layout_marginTop="15dp"
android:textSize="16sp"
android:textColor="@android:color/white"
android:layout_centerHorizontal="true"
android:layout_width="wrap_content"
android:layout_height="wrap_content" />
<LinearLayout
android:orientation="horizontal"
android:layout_centerVertical="true"
android:layout_marginRight="15dp"
android:layout_marginTop="15dp"
android:layout_marginLeft="15dp"
android:layout_width="match_parent"
android:layout_height="wrap_content">
<com.xf.weixinclick.customerview.CustomEditText
android:id="@+id/cet_bind_user"
android:gravity="center_vertical"
android:background="@drawable/shape_edit_id"
android:gravity="left"
android:padding="5dp"
android:singleLine="true"
android:textSize="20sp"
android:layout_width="match_parent"
android:layout_height="90dp" />
android:textSize="12sp"
android:textColor="@android:color/white"
android:layout_marginRight="15dp"
android:layout_weight="1"
android:layout_width="0dp"
android:layout_height="30dp" />
<TextView
android:id="@+id/tv_bind"
android:text="绑定"
android:textSize="50sp"
android:background="#00cccc"
android:textColor="#ff00ff"
android:textSize="14sp"
android:background="@drawable/btn_bind"
android:textColor="@android:color/white"
android:gravity="center"
android:layout_width="60dp"
android:layout_height="30dp" />
</LinearLayout>
</RelativeLayout>
<TextView
android:text="设置"
android:textSize="16sp"
android:textColor="#c9c9ca"
android:layout_marginTop="15dp"
android:layout_marginLeft="15dp"
android:layout_width="wrap_content"
android:layout_height="wrap_content" />
<RelativeLayout
android:layout_marginTop="15dp"
android:layout_marginLeft="15dp"
android:layout_marginRight="15dp"
android:background="@drawable/bg_work_action"
android:layout_width="match_parent"
android:layout_height="100dp" />
android:layout_height="100dp">
<TextView
android:id="@+id/chat_view"
android:text="开启监听"
android:gravity="center"
android:textSize="50sp"
android:textColor="#000"
android:layout_width="match_parent"
android:layout_height="100dp"
android:background="#fff000"/>
android:textSize="14sp"
android:textColor="#fd7f5f"
android:layout_centerInParent="true"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:background="@drawable/bg_btn_wok_action"/>
</RelativeLayout>
<RelativeLayout
android:layout_marginTop="15dp"
android:layout_marginLeft="15dp"
android:layout_marginRight="15dp"
android:background="@drawable/bg_work_action"
android:layout_width="match_parent"
android:layout_height="100dp">
<TextView
android:id="@+id/chat_view_show"
android:text="设置事件"
android:gravity="center"
android:textSize="50sp"
android:textColor="#fff"
android:layout_width="match_parent"
android:layout_height="100dp"
android:background="#ff6600"/>
android:textSize="14sp"
android:textColor="#fd7f5f"
android:layout_centerInParent="true"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:background="@drawable/bg_btn_wok_action"/>
</RelativeLayout>
<RelativeLayout
android:layout_width="match_parent"
android:layout_height="match_parent">
<TextView
android:id="@+id/tv_version_name"
android:layout_marginTop="@dimen/text_margin"
android:layout_marginLeft="@dimen/text_margin"
android:layout_width="match_parent"
android:layout_height="20dp"
android:layout_marginBottom="15dp"
android:layout_centerHorizontal="true"
android:layout_alignParentBottom="true"
android:textSize="16sp"
android:textColor="#c9c9ca"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
tools:text="版本号" />
</LinearLayout>
</RelativeLayout>
</android.support.design.widget.CoordinatorLayout>
</LinearLayout>
<resources>
<style name="AppTheme" parent="@style/BaseAppTheme">
</style>
</resources>
......@@ -3,4 +3,6 @@
<color name="colorPrimary">#3F51B5</color>
<color name="colorPrimaryDark">#303F9F</color>
<color name="colorAccent">#FF4081</color>
<color name="windowBg">#edf0f0</color>
<color name="wave">#08FFFFFF</color>
</resources>
<resources>
<!-- Base application theme. -->
<style name="AppTheme" parent="Theme.AppCompat.Light.DarkActionBar">
<style name="BaseAppTheme" parent="Theme.AppCompat.Light.NoActionBar">
<!-- Customize your theme here. -->
<item name="colorPrimary">@color/colorPrimary</item>
<item name="colorPrimaryDark">@color/colorPrimaryDark</item>
<item name="colorAccent">@color/colorAccent</item>
<item name="windowActionBar">false</item> //很重要
<item name="windowNoTitle">true</item> //很重要
<item name="android:windowBackground">@color/windowBg</item>
</style>
<style name="AppTheme" parent="@style/BaseAppTheme">
</style>
<declare-styleable name="customedt">
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment