Skip to content
This repository has been archived by the owner on Jul 10, 2020. It is now read-only.

Commit

Permalink
Merge from master branch
Browse files Browse the repository at this point in the history
  • Loading branch information
jahirfiquitiva committed Mar 31, 2018
2 parents fbaba73 + 1d9708f commit f313157
Showing 1 changed file with 11 additions and 3 deletions.
14 changes: 11 additions & 3 deletions library/src/main/java/jahirfiquitiva/libs/fabsmenu/TitleFAB.java
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@
import android.content.res.ColorStateList;
import android.content.res.TypedArray;
import android.support.annotation.ColorInt;
import android.support.annotation.NonNull;
import android.support.annotation.Nullable;
import android.support.design.widget.CoordinatorLayout;
import android.support.design.widget.FloatingActionButton;
Expand All @@ -35,8 +36,8 @@
import android.view.View;
import android.view.animation.Interpolator;

@CoordinatorLayout.DefaultBehavior(FABSnackbarBehavior.class)
public class TitleFAB extends FloatingActionButton {
@SuppressWarnings("unused")
public class TitleFAB extends FloatingActionButton implements CoordinatorLayout.AttachedBehavior {

private static final int MAX_CHARACTERS_COUNT = 25;

Expand Down Expand Up @@ -162,6 +163,7 @@ public boolean isTitleClickEnabled() {
return titleClickEnabled;
}

@SuppressWarnings("SameParameterValue")
public void setTitleClickEnabled(boolean titleClickEnabled) {
this.titleClickEnabled = titleClickEnabled;
LabelView label = getLabelView();
Expand Down Expand Up @@ -356,4 +358,10 @@ private boolean shouldAnimateVisibilityChange() {
return ViewCompat.isLaidOut(this) && !isInEditMode();
}
}
}

@NonNull
@Override
public CoordinatorLayout.Behavior getBehavior() {
return new FABSnackbarBehavior();
}
}

0 comments on commit f313157

Please sign in to comment.