Floating Action Button Behavior

Floating Action Button Behavior
gradle a alttaki satır eklenmeli;
implementation 'com.getbase:floatingactionbutton:1.10.1'
tamamı
apply plugin: 'com.android.application'
android {
compileSdkVersion 28
buildToolsVersion '28.0.3'
defaultConfig {
applicationId "com.mobilprogramlar.floatingactionbuttonbehavior"
minSdkVersion 21
targetSdkVersion 28
versionCode 1
versionName "1.0"
testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
}
buildTypes {
release {
minifyEnabled false
proguardFiles getDefaultProguardFile('proguard-android-optimize.txt'), 'proguard-rules.pro'
}
}
}
dependencies {
implementation fileTree(dir: 'libs', include: ['*.jar'])
implementation 'androidx.appcompat:appcompat:1.1.0-rc01'
implementation 'androidx.constraintlayout:constraintlayout:2.0.0-beta2'
testİmplementation 'junit:junit:4.13-beta-3'
androidTestİmplementation 'androidx.test:runner:1.3.0-alpha02'
androidTestİmplementation 'androidx.test.espresso:espresso-core:3.3.0-alpha02'
implementation 'com.google.android.material:material:1.0.0'
implementation 'com.getbase:floatingactionbutton:1.10.1'
}
activity_main.xml
<?xml version="1.0" encoding="utf-8"?>
<androidx.constraintlayout.widget.ConstraintLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:app="http://schemas.android.com/apk/res-auto"
android:layout_width="match_parent"
android:layout_height="match_parent">
<com.getbase.floatingactionbutton.FloatingActionButton
android:id="@+id/fab"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_gravity="end|bottom"
android:layout_margin="16dp"
app:fab_icon="@drawable/ic_done"
app:layout_behavior="com.mobilprogramlar.floatingactionbuttonbehavior.FloatingActionButtonBehavior"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toTopOf="parent" />
</androidx.constraintlayout.widget.ConstraintLayout>
MainActivity ise
package com.mobilprogramlar.floatingactionbuttonbehavior;… Devamını Oku “Floating Action Button Behavior”
