Skip to content

Commit 3cb79bc

Browse files
committed
Merge branch 'release/1.0.1' into develop
2 parents 9d3bf89 + cdb301d commit 3cb79bc

File tree

10 files changed

+34
-47
lines changed

10 files changed

+34
-47
lines changed

CHANGELOG.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,3 +4,7 @@ CHANGE LOG
44
1.0.0
55
-----
66
Initial version of the ExpandableTextView
7+
8+
1.0.1
9+
-----
10+
Added support for Interpolators + update demo Activity

README.md

Lines changed: 9 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ Demo
88
----
99
This repository also contains a demo project.
1010

11-
![Demo](https://raw.githubusercontent.com/Blogcat/Android-ExpandableTextView/release/1.0.0/demo.gif)
11+
![Demo](https://raw.githubusercontent.com/Blogcat/Android-ExpandableTextView/release/1.0.1/demo.gif)
1212

1313
Add dependency
1414
--------------
@@ -32,7 +32,7 @@ library dependency
3232

3333
```groovy
3434
dependencies {
35-
compile ('at.blogc:expandabletextview:1.0.0@aar')
35+
compile ('at.blogc:expandabletextview:1.0.1@aar')
3636
}
3737
```
3838

@@ -77,6 +77,13 @@ final Button buttonToggle = (Button) this.findViewById(R.id.button_toggle);
7777
// set animation duration via code, but preferable in your layout files by using the animation_duration attribute
7878
expandableTextView.setAnimationDuration(1000L);
7979

80+
// set interpolators for both expanding and collapsing animations
81+
expandableTextView.setInterpolator(new OvershootInterpolator());
82+
83+
// or set them separately
84+
expandableTextView.setExpandInterpolator(new OvershootInterpolator());
85+
expandableTextView.setCollapseInterpolator(new OvershootInterpolator());
86+
8087
// toggle the ExpandableTextView
8188
buttonToggle.setOnClickListener(new View.OnClickListener()
8289
{

app/build.gradle

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ apply plugin: 'com.android.application'
22

33
android {
44
compileSdkVersion 23
5-
buildToolsVersion "23.0.2"
5+
buildToolsVersion "23.0.3"
66

77
defaultConfig {
88
applicationId "blogc.at.android.views"
@@ -21,7 +21,7 @@ android {
2121

2222
dependencies {
2323
compile fileTree(dir: 'libs', include: ['*.jar'])
24-
compile 'com.android.support:appcompat-v7:23.1.1'
24+
compile 'com.android.support:appcompat-v7:23.3.0'
2525
compile project(':expandabletextview')
2626

2727

app/src/main/AndroidManifest.xml

Lines changed: 10 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -13,22 +13,28 @@
1313
See the License for the specific language governing permissions and
1414
limitations under the License.
1515
-->
16-
<manifest package="at.blogc.android.views"
17-
xmlns:android="http://schemas.android.com/apk/res/android">
16+
<manifest
17+
xmlns:tools="http://schemas.android.com/tools"
18+
package="at.blogc.android.views"
19+
xmlns:android="http://schemas.android.com/apk/res/android">
1820

1921
<application
2022
android:allowBackup="true"
2123
android:icon="@mipmap/ic_launcher"
2224
android:label="@string/app_name"
2325
android:supportsRtl="true"
24-
android:theme="@style/AppTheme">
26+
android:theme="@style/AppTheme"
27+
tools:ignore="AllowBackup">
28+
2529
<activity android:name="at.blogc.android.activities.MainActivity">
30+
2631
<intent-filter>
2732
<action android:name="android.intent.action.MAIN"/>
28-
2933
<category android:name="android.intent.category.LAUNCHER"/>
3034
</intent-filter>
35+
3136
</activity>
37+
3238
</application>
3339

3440
</manifest>

app/src/main/java/at/blogc/android/activities/MainActivity.java

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,8 +29,9 @@ public class MainActivity extends AppCompatActivity
2929
{
3030
private static final String TAG = "ExpandableTextView";
3131

32+
@SuppressWarnings("ConstantConditions")
3233
@Override
33-
protected void onCreate(Bundle savedInstanceState)
34+
protected void onCreate(final Bundle savedInstanceState)
3435
{
3536
super.onCreate(savedInstanceState);
3637
this.setContentView(R.layout.activity_main);
@@ -51,6 +52,7 @@ protected void onCreate(Bundle savedInstanceState)
5152
// toggle the ExpandableTextView
5253
buttonToggle.setOnClickListener(new View.OnClickListener()
5354
{
55+
@SuppressWarnings("ConstantConditions")
5456
@Override
5557
public void onClick(final View v)
5658
{

build.gradle

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ buildscript {
55
jcenter()
66
}
77
dependencies {
8-
classpath 'com.android.tools.build:gradle:2.1.0-beta3'
8+
classpath 'com.android.tools.build:gradle:2.0.0'
99
classpath 'com.github.dcendents:android-maven-gradle-plugin:1.3'
1010
classpath 'com.jfrog.bintray.gradle:gradle-bintray-plugin:1.6'
1111
// NOTE: Do not place your application dependencies here; they belong

expandabletextview/build.gradle

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,14 +2,14 @@ apply plugin: 'com.android.library'
22
apply plugin: 'com.github.dcendents.android-maven'
33
apply plugin: 'com.jfrog.bintray'
44

5-
def fullVersion = '1.0.0'
5+
def fullVersion = '1.0.1'
66

77
group = 'at.blogc'
88
version = fullVersion
99

1010
android {
1111
compileSdkVersion 23
12-
buildToolsVersion "23.0.2"
12+
buildToolsVersion "23.0.3"
1313

1414
defaultConfig {
1515
minSdkVersion 14

expandabletextview/src/androidTest/java/at/blogc/android/views/ApplicationTest.java

Lines changed: 0 additions & 15 deletions
This file was deleted.

expandabletextview/src/main/java/at/blogc/android/views/ExpandableTextView.java

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -49,17 +49,17 @@ public class ExpandableTextView extends TextView
4949
private boolean expanded;
5050
private int originalHeight;
5151

52-
public ExpandableTextView(Context context)
52+
public ExpandableTextView(final Context context)
5353
{
5454
this(context, null);
5555
}
5656

57-
public ExpandableTextView(Context context, AttributeSet attrs)
57+
public ExpandableTextView(final Context context, final AttributeSet attrs)
5858
{
5959
this(context, attrs, 0);
6060
}
6161

62-
public ExpandableTextView(Context context, AttributeSet attrs, int defStyle)
62+
public ExpandableTextView(final Context context, final AttributeSet attrs, final int defStyle)
6363
{
6464
super(context, attrs, defStyle);
6565

expandabletextview/src/test/java/at/blogc/android/views/ExampleUnitTest.java

Lines changed: 0 additions & 17 deletions
This file was deleted.

0 commit comments

Comments
 (0)