카카오톡 채팅방 추가 버튼
조회수 3409회
1 답변
-
이런 버튼을 말씀하시는 거라면 아래의 링크에서 제공되는 오픈소스를 적용하면 좋을것 같습니다. https://github.com/gowong/material-sheet-fab
사용법이라면 build.gradle에
compile 'com.gordonwong:material-sheet-fab:1.2.1'
를 적용하시고클래스를 만들어서 FAB버튼을 구현해주시면 됩니다.
import android.support.design.widget.FloatingActionButton; public class Fab extends FloatingActionButton implements AnimatedFab { /** * Shows the FAB. */ @Override public void show() { show(0, 0); } /** * Shows the FAB and sets the FAB's translation. * * @param translationX translation X value * @param translationY translation Y value */ @Override public void show(float translationX, float translationY) { // NOTE: Using the parameters is only needed if you want // to support moving the FAB around the screen. // NOTE: This immediately hides the FAB. An animation can // be used instead - see the sample app. setVisibility(View.VISIBLE); } /** * Hides the FAB. */ @Override public void hide() { // NOTE: This immediately hides the FAB. An animation can // be used instead - see the sample app. setVisibility(View.INVISIBLE); } }
댓글 입력