-Change the buttons style to the buttons to material one in the fragment_backup_settings.xml and java source

-Add the new buttons push animation to the buttons in the fragment_backup_settings.xml and java source
This commit is contained in:
dtvv 2018-10-12 04:51:54 -05:00
parent c30fd729be
commit 3019cc8422
2 changed files with 21 additions and 4 deletions

View file

@ -23,6 +23,8 @@ import android.widget.Button;
import android.widget.TextView;
import android.widget.Toast;
import com.thekhaeng.pushdownanim.PushDownAnim;
import java.io.File;
import java.text.DateFormat;
import java.text.SimpleDateFormat;
@ -85,6 +87,25 @@ public class BackupsSettingsFragment extends Fragment{
View v = inflater.inflate(R.layout.fragment_backups_settings, container, false);
ButterKnife.bind(this, v);
/*
* Integration of library with button efects
* */
PushDownAnim.setPushDownAnimTo(btnBinFile)
.setOnClickListener( new View.OnClickListener(){
@Override
public void onClick( View view ){
makeBackupFile();
}
} );
PushDownAnim.setPushDownAnimTo(btnBrainkey)
.setOnClickListener( new View.OnClickListener(){
@Override
public void onClick( View view ){
btnBrainOnClick();
}
} );
tvBinFile.setText(makeFirstWordsBold(getResources().getString(R.string.bin_file_description)));
tvBrainkey.setText(makeFirstWordsBold(getResources().getString(R.string.brainkey_description)));
tvWIFKey.setText(makeFirstWordsBold(getResources().getString(R.string.wif_key_description)));

View file

@ -23,12 +23,10 @@
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="16dp"
style="@style/Widget.Button"
android:text="@string/create_a_backup"
android:theme="@style/BlueButton"
android:textStyle="bold"
android:textColor="@color/white"
android:background="@color/colorPrimary"
app:layout_constraintTop_toBottomOf="@id/tvBinFile"
app:layout_constraintStart_toStartOf="@id/tvBinFile" />
@ -45,11 +43,9 @@
<Button
android:id="@+id/btnBrainkey"
style="@style/Widget.Button"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="16dp"
android:background="@color/colorPrimary"
android:text="@string/view_and_copy"
android:theme="@style/BlueButton"
android:textColor="@color/white"