Skip to content

Commit

Permalink
code optimization
Browse files Browse the repository at this point in the history
  • Loading branch information
samwelnyandoro committed Jul 4, 2024
1 parent 18eb7a0 commit 31ec0df
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 1 deletion.
Original file line number Diff line number Diff line change
@@ -1,18 +1,25 @@
package com.mpesaandroidintegration.mpesaintegrationandroid;

import androidx.appcompat.app.AppCompatActivity;
import androidx.localbroadcastmanager.content.LocalBroadcastManager;

import android.app.ProgressDialog;
import android.content.BroadcastReceiver;
import android.content.Context;
import android.content.Intent;
import android.content.IntentFilter;
import android.content.SharedPreferences;
import android.os.Bundle;
import android.util.Log;
import android.view.View;
import android.widget.Button;
import android.widget.EditText;
import android.widget.ImageView;
import android.widget.TextView;
import android.widget.Toast;

import com.afollestad.materialdialogs.GravityEnum;
import com.afollestad.materialdialogs.MaterialDialog;
import com.mpesaandroidintegration.mpesa.Mpesa;
import com.mpesaandroidintegration.mpesa.interfaces.AuthListener;
import com.mpesaandroidintegration.mpesa.interfaces.MpesaListener;
Expand Down Expand Up @@ -111,7 +118,7 @@ private void showDialog(String title, String message,int code){
.positiveText("OK")
.cancelable(false)
.widgetColorRes(R.color.colorPrimary)
.callback(new ButtonCallback() {
.callback(new MaterialDialog.ButtonCallback() {
@Override
public void onPositive(MaterialDialog dialog) {
super.onPositive(dialog);
Expand Down
1 change: 1 addition & 0 deletions app/src/main/res/values/colors.xml
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
<?xml version="1.0" encoding="utf-8"?>
<resources>
<color name="purple_200">#FFBB86FC</color>
<color name="colorPrimary">#3F51B5</color>
<color name="purple_500">#FF6200EE</color>
<color name="purple_700">#FF3700B3</color>
<color name="teal_200">#FF03DAC5</color>
Expand Down

0 comments on commit 31ec0df

Please sign in to comment.