mirror of
https://github.com/M66B/NetGuard.git
synced 2024-12-23 08:17:51 +00:00
Logcat count down gimmick
This commit is contained in:
parent
c2b1dfc180
commit
9968111906
1 changed files with 7 additions and 1 deletions
|
@ -436,12 +436,18 @@ public class ActivityMain extends AppCompatActivity implements SharedPreferences
|
|||
// Handle logcat
|
||||
view.setOnClickListener(new View.OnClickListener() {
|
||||
private short tap = 0;
|
||||
private Toast toast = Toast.makeText(ActivityMain.this, "", Toast.LENGTH_SHORT);
|
||||
|
||||
@Override
|
||||
public void onClick(View view) {
|
||||
if (++tap == 7) {
|
||||
tap++;
|
||||
if (tap == 7) {
|
||||
tap = 0;
|
||||
toast.cancel();
|
||||
Util.sendLogcat(null, ActivityMain.this);
|
||||
} else if (tap > 3) {
|
||||
toast.setText(Integer.toString(7 - tap));
|
||||
toast.show();
|
||||
}
|
||||
}
|
||||
});
|
||||
|
|
Loading…
Reference in a new issue