From cbae26dd4c4f5de6eee2721801c805744dbf0174 Mon Sep 17 00:00:00 2001 From: Zachary Epps Date: Wed, 5 Apr 2017 13:49:28 -0400 Subject: [PATCH] changed AccountActivity so that after following someone the FAB hides itself --- app/build.gradle | 1 + app/src/main/java/com/keylesspalace/tusky/AccountActivity.java | 3 ++- 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/app/build.gradle b/app/build.gradle index b05e8867..560e5f54 100644 --- a/app/build.gradle +++ b/app/build.gradle @@ -44,6 +44,7 @@ dependencies { compile 'com.jakewharton:butterknife:8.4.0' compile 'com.google.firebase:firebase-messaging:10.0.1' compile 'com.google.firebase:firebase-crash:10.0.1' + compile 'com.github.bluzwong:swipeback:0.2.0@aar' testCompile 'junit:junit:4.12' annotationProcessor 'com.jakewharton:butterknife-compiler:8.4.0' } diff --git a/app/src/main/java/com/keylesspalace/tusky/AccountActivity.java b/app/src/main/java/com/keylesspalace/tusky/AccountActivity.java index a86df1c2..30740086 100644 --- a/app/src/main/java/com/keylesspalace/tusky/AccountActivity.java +++ b/app/src/main/java/com/keylesspalace/tusky/AccountActivity.java @@ -292,7 +292,7 @@ public class AccountActivity extends BaseActivity { private void updateButtons() { invalidateOptionsMenu(); - FloatingActionButton floatingBtn = (FloatingActionButton) findViewById(R.id.floating_btn); + final FloatingActionButton floatingBtn = (FloatingActionButton) findViewById(R.id.floating_btn); if(!isSelf && !blocking && !following) { floatingBtn.show(); @@ -301,6 +301,7 @@ public class AccountActivity extends BaseActivity { @Override public void onClick(View v) { follow(accountId); + floatingBtn.hide(); } }); }