Permalink
Please sign in to comment.
Showing
with
237 additions
and 17 deletions.
- +1 −0 app/src/main/AndroidManifest.xml
- +21 −1 app/src/main/java/com/camnter/easycountdowntextureview/demo/MainActivity.java
- +25 −0 app/src/main/java/com/camnter/easycountdowntextureview/demo/StyleActivity.java
- +21 −6 app/src/main/res/layout/activity_main.xml
- +31 −0 app/src/main/res/layout/activity_style.xml
- +2 −1 app/src/main/res/values/strings.xml
- +2 −0 build.gradle
- +89 −0 library/build.gradle
- +42 −9 library/src/main/java/com/camnter/easycountdowntextureview/EasyCountDownTextureView.java
- +3 −0 library/src/main/res/values/attrs.xml
1
app/src/main/AndroidManifest.xml
22
app/src/main/java/com/camnter/easycountdowntextureview/demo/MainActivity.java
25
app/src/main/java/com/camnter/easycountdowntextureview/demo/StyleActivity.java
| @@ -0,0 +1,25 @@ | ||
| +package com.camnter.easycountdowntextureview.demo; | ||
| + | ||
| +import android.content.Context; | ||
| +import android.content.Intent; | ||
| +import android.os.Bundle; | ||
| +import android.support.annotation.Nullable; | ||
| +import android.support.v7.app.AppCompatActivity; | ||
| + | ||
| +/** | ||
| + * Description:StyleActivity | ||
| + * Created by:CaMnter | ||
| + * Time:2016-03-17 17:20 | ||
| + */ | ||
| +public class StyleActivity extends AppCompatActivity { | ||
| + | ||
| + public static void startActivity(Context context) { | ||
| + context.startActivity(new Intent(context, StyleActivity.class)); | ||
| + } | ||
| + | ||
| + @Override | ||
| + protected void onCreate(@Nullable Bundle savedInstanceState) { | ||
| + super.onCreate(savedInstanceState); | ||
| + this.setContentView(R.layout.activity_style); | ||
| + } | ||
| +} |
27
app/src/main/res/layout/activity_main.xml
31
app/src/main/res/layout/activity_style.xml
| @@ -0,0 +1,31 @@ | ||
| +<?xml version="1.0" encoding="utf-8"?> | ||
| +<RelativeLayout 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" | ||
| + android:paddingBottom="@dimen/activity_vertical_margin" | ||
| + android:paddingLeft="@dimen/activity_horizontal_margin" | ||
| + android:paddingRight="@dimen/activity_horizontal_margin" | ||
| + android:paddingTop="@dimen/activity_vertical_margin" | ||
| + tools:context="com.camnter.easycountdowntextureview.demo.MainActivity"> | ||
| + | ||
| + <com.camnter.easycountdowntextureview.EasyCountDownTextureView | ||
| + android:layout_width="132dp" | ||
| + android:layout_height="36dp" | ||
| + app:easyCountBackgroundColor="#ffdddddd" | ||
| + app:easyCountColonColor="#ffdddddd" | ||
| + app:easyCountColonSize="20sp" | ||
| + app:easyCountHour="6" | ||
| + app:easyCountMinute="6" | ||
| + app:easyCountRectHeight="34dp" | ||
| + app:easyCountRectRadius="5dp" | ||
| + app:easyCountRectSpacing="12dp" | ||
| + app:easyCountRectWidth="36dp" | ||
| + app:easyCountSecond="26" | ||
| + app:easyCountTimeColor="#ff3A94FF" | ||
| + app:easyCountTimeSize="20sp" /> | ||
| + | ||
| + | ||
| +</RelativeLayout> |
3
app/src/main/res/values/strings.xml
| @@ -1,3 +1,4 @@ | ||
| <resources> | ||
| - <string name="app_name">EasyCountDownSurfaceView</string> | ||
| + <string name="app_name">EasyCountDownTextureView</string> | ||
| + <string name="style_bt">Style</string> | ||
| </resources> |
2
build.gradle
89
library/build.gradle
51
library/src/main/java/com/camnter/easycountdowntextureview/EasyCountDownTextureView.java
3
library/src/main/res/values/attrs.xml
0 comments on commit
e36b440