Skip to content

Commit

Permalink
Merged recent PRs.
Browse files Browse the repository at this point in the history
  • Loading branch information
PhilJay committed May 2, 2015
1 parent c7b6e07 commit 6a60e2c
Show file tree
Hide file tree
Showing 5 changed files with 11 additions and 7 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -58,6 +58,8 @@ protected void onCreate(Bundle savedInstanceState) {
mChart = (PieChart) findViewById(R.id.chart1);
mChart.setUsePercentValues(true);
mChart.setDescription("");

mChart.setDragDecelerationFrictionCoef(0.99f);

tf = Typeface.createFromAsset(getAssets(), "OpenSans-Regular.ttf");

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,7 @@ public boolean onTouchEvent(MotionEvent event) {
public void computeScroll() {

if (mListener instanceof PieRadarChartTouchListener)
((PieRadarChartTouchListener)mListener).computeScroll();
((PieRadarChartTouchListener) mListener).computeScroll();
}

@Override
Expand Down Expand Up @@ -442,7 +442,6 @@ public List<SelInfo> getYValsAtIndex(int xIndex) {
*/
/** CODE BELOW THIS RELATED TO ANIMATION */


/**
* Applys a spin animation to the Chart.
*
Expand All @@ -458,7 +457,8 @@ public void spin(int durationmillis, float fromangle, float toangle, Easing.Easi

setRotationAngle(fromangle);

ObjectAnimator spinAnimator = ObjectAnimator.ofFloat(this, "rotationAngle", fromangle, toangle);
ObjectAnimator spinAnimator = ObjectAnimator.ofFloat(this, "rotationAngle", fromangle,
toangle);
spinAnimator.setDuration(durationmillis);
spinAnimator.setInterpolator(Easing.getEasingFunctionFromOption(easing));

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ public class PieRadarChartTouchListener extends SimpleOnGestureListener implemen

private GestureDetector mGestureDetector;

private ArrayList<AngularVelocitySample> _velocitySamples = new ArrayList<>();
private ArrayList<AngularVelocitySample> _velocitySamples = new ArrayList<AngularVelocitySample>();

private long mDecelerationLastTime = 0;
private float mDecelerationAngularVelocity = 0.f;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -31,14 +31,14 @@ public LargeValueFormatter() {
* Creates a formatter that appends a specified text to the result string
* @param text a text that will be appended
*/
public LargeValueFormatter(String text) {
public LargeValueFormatter(String appendix) {
this();
mText = text;
mText = appendix;
}

@Override
public String getFormattedValue(float value) {
return makePretty(value) + " " + mText;
return makePretty(value) + mText;
}

/**
Expand Down
2 changes: 2 additions & 0 deletions MPChartLib/src/com/github/mikephil/charting/utils/Utils.java
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,9 @@
import android.view.VelocityTracker;
import android.view.View;
import android.view.ViewConfiguration;

import com.github.mikephil.charting.components.YAxis.AxisDependency;

import java.text.DecimalFormat;
import java.util.List;

Expand Down

0 comments on commit 6a60e2c

Please sign in to comment.