Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
19 changes: 15 additions & 4 deletions build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -4,14 +4,25 @@ buildscript {
mavenCentral()
}
dependencies {
classpath 'com.android.tools.build:gradle:2.0.0'
classpath 'com.android.tools.build:gradle:3.0.0-alpha4'
}
}

allprojects {
repositories {
jcenter()
maven {
url "https://maven.google.com"
}
}
}

ext {
compileSdkVersion = 23
buildToolsVersion = "23.0.3"
compileSdkVersion = 26
buildToolsVersion = "26.0.0"

minSdkVersion = 14
targetSdkVersion = 23
targetSdkVersion = 26

support = '26.0.0-beta2'
}
4 changes: 2 additions & 2 deletions gradle/wrapper/gradle-wrapper.properties
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#Mon Apr 25 23:12:46 PDT 2016
#Thu Jun 29 14:29:22 CEST 2017
distributionBase=GRADLE_USER_HOME
distributionPath=wrapper/dists
zipStoreBase=GRADLE_USER_HOME
zipStorePath=wrapper/dists
distributionUrl=https\://services.gradle.org/distributions/gradle-2.13-bin.zip
distributionUrl=https\://services.gradle.org/distributions/gradle-4.0-rc-1-all.zip
4 changes: 4 additions & 0 deletions library/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -10,4 +10,8 @@ android {
}
}

dependencies {
compile 'com.android.support:appcompat-v7:' + rootProject.ext.support
}

apply from: 'https://raw.github.com/chrisbanes/gradle-mvn-push/master/gradle-mvn-push.gradle'
11 changes: 5 additions & 6 deletions library/src/main/java/me/grantland/widget/AutofitTextView.java
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
package me.grantland.widget;

import android.content.Context;
import android.support.v7.widget.AppCompatTextView;
import android.util.AttributeSet;
import android.util.TypedValue;
import android.widget.TextView;
Expand All @@ -12,7 +13,9 @@
* @attr ref R.styleable.AutofitTextView_minTextSize
* @attr ref R.styleable.AutofitTextView_precision
*/
public class AutofitTextView extends TextView implements AutofitHelper.OnTextSizeChangeListener {
public class AutofitTextView
extends AppCompatTextView
implements AutofitHelper.OnTextSizeChangeListener {

private AutofitHelper mHelper;

Expand Down Expand Up @@ -115,7 +118,6 @@ public float getMaxTextSize() {
* is adjusted based on the current density and user font size preference.
*
* @param size The scaled pixel size.
*
* @attr ref android.R.styleable#TextView_textSize
*/
public void setMaxTextSize(float size) {
Expand All @@ -128,7 +130,6 @@ public void setMaxTextSize(float size) {
*
* @param unit The desired dimension unit.
* @param size The desired size in the given units.
*
* @attr ref android.R.styleable#TextView_textSize
*/
public void setMaxTextSize(int unit, float size) {
Expand All @@ -147,7 +148,6 @@ public float getMinTextSize() {
* is adjusted based on the current density and user font size preference.
*
* @param minSize The scaled pixel size.
*
* @attr ref me.grantland.R.styleable#AutofitTextView_minTextSize
*/
public void setMinTextSize(int minSize) {
Expand All @@ -158,9 +158,8 @@ public void setMinTextSize(int minSize) {
* Set the minimum text size to a given unit and value. See TypedValue for the possible
* dimension units.
*
* @param unit The desired dimension unit.
* @param unit The desired dimension unit.
* @param minSize The desired size in the given units.
*
* @attr ref me.grantland.R.styleable#AutofitTextView_minTextSize
*/
public void setMinTextSize(int unit, float minSize) {
Expand Down