Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Tools update and typo fix #8

Open
wants to merge 2 commits into
base: master
Choose a base branch
from
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
9 changes: 2 additions & 7 deletions .idea/gradle.xml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

6 changes: 6 additions & 0 deletions .idea/vcs.xml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

14 changes: 7 additions & 7 deletions app/src/main/java/jp/narr/tensorflowmnist/MainActivity.java
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ public class MainActivity extends AppCompatActivity implements View.OnTouchListe
private DrawModel mModel;
private DrawView mDrawView;

private PointF mTmpPiont = new PointF();
private PointF mTmpPoint = new PointF();

private DigitDetector mDetector = new DigitDetector();

Expand Down Expand Up @@ -113,19 +113,19 @@ public boolean onTouch(View v, MotionEvent event) {
private void processTouchDown(MotionEvent event) {
mLastX = event.getX();
mLastY = event.getY();
mDrawView.calcPos(mLastX, mLastY, mTmpPiont);
float lastConvX = mTmpPiont.x;
float lastConvY = mTmpPiont.y;
mDrawView.calcPos(mLastX, mLastY, mTmpPoint);
float lastConvX = mTmpPoint.x;
float lastConvY = mTmpPoint.y;
mModel.startLine(lastConvX, lastConvY);
}

private void processTouchMove(MotionEvent event) {
float x = event.getX();
float y = event.getY();

mDrawView.calcPos(x, y, mTmpPiont);
float newConvX = mTmpPiont.x;
float newConvY = mTmpPiont.y;
mDrawView.calcPos(x, y, mTmpPoint);
float newConvX = mTmpPoint.x;
float newConvY = mTmpPoint.y;
mModel.addLineElem(newConvX, newConvY);

mLastX = x;
Expand Down
2 changes: 1 addition & 1 deletion build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ buildscript {
jcenter()
}
dependencies {
classpath 'com.android.tools.build:gradle:2.1.2'
classpath 'com.android.tools.build:gradle:2.2.2'

// NOTE: Do not place your application dependencies here; they belong
// in the individual module build.gradle files
Expand Down
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 Sep 26 20:47:15 JST 2016
#Sun Nov 13 09:56:04 CST 2016
distributionBase=GRADLE_USER_HOME
distributionPath=wrapper/dists
zipStoreBase=GRADLE_USER_HOME
zipStorePath=wrapper/dists
distributionUrl=https\://services.gradle.org/distributions/gradle-2.10-all.zip
distributionUrl=https\://services.gradle.org/distributions/gradle-2.14.1-all.zip