Skip to content

Commit

Permalink
Added time delay for animation to show
Browse files Browse the repository at this point in the history
  • Loading branch information
tirth5828 committed Oct 15, 2021
1 parent d855196 commit ec3e3a6
Show file tree
Hide file tree
Showing 3 changed files with 20 additions and 16 deletions.
2 changes: 2 additions & 0 deletions .idea/misc.xml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

7 changes: 0 additions & 7 deletions app/src/main/java/com/example/us_2_0/LandingPage.java
Original file line number Diff line number Diff line change
@@ -1,16 +1,9 @@
package com.example.us_2_0;

import androidx.appcompat.app.AppCompatActivity;

import android.content.Intent;
import android.os.Bundle;
import com.sawolabs.androidsdk.ConstantsKt;

public class LandingPage extends AppCompatActivity {
Intent intent = getIntent();
String message = intent.getStringExtra(ConstantsKt.LOGIN_SUCCESS_MESSAGE);


@Override
protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
Expand Down
27 changes: 18 additions & 9 deletions app/src/main/java/com/example/us_2_0/MainActivity.java
Original file line number Diff line number Diff line change
Expand Up @@ -3,27 +3,36 @@
import androidx.appcompat.app.AppCompatActivity;

import android.os.Bundle;
import android.os.Handler;
import android.view.View;
import com.sawolabs.androidsdk.Sawo;

public class MainActivity extends AppCompatActivity {

private Handler H = new Handler();

@Override
protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.activity_main);
}

public void Log(View view) {

new Sawo(
this,
"1014c134-e723-43fe-a4d5-5933c554bf29", // your api key
"616975ed3148f7167607f1226AeBwjDLRISfuqNqGz6NqBS4" // your api key secret
).login(
"email", // can be one of 'email' or 'phone_number_sms'
LandingPage.class.getName() // Callback class name
);
H.postDelayed(SAWO,5000);
}

private Runnable SAWO = new Runnable() {
@Override
public void run() {
new Sawo(
MainActivity.this,
"1014c134-e723-43fe-a4d5-5933c554bf29", // your api key
"616975ed3148f7167607f1226AeBwjDLRISfuqNqGz6NqBS4" // your api key secret
).login(
"email", // can be one of 'email' or 'phone_number_sms'
LandingPage.class.getName() // Callback class name
);
}
};

}

0 comments on commit ec3e3a6

Please sign in to comment.