Actual toast

This commit is contained in:
licaon-kter 2016-02-19 11:39:29 +02:00
parent 5fc001cb19
commit 6f5f4dcf89
1 changed files with 12 additions and 1 deletions

View File

@ -135,6 +135,17 @@ public class ActivityMain extends AppCompatActivity implements SharedPreferences
// Icon, no title
getSupportActionBar().setTitle(null);
// Netguard is busy
ivQueue.setOnLongClickListener(new View.OnLongClickListener() {
@Override
public boolean onLongClick(View view) {
Toast toast = Toast.makeText(ActivityMain.this, R.string.msg_queue, Toast.LENGTH_LONG);
toast.setGravity(Gravity.TOP, actionView.getLeft(), actionView.getBottom());
toast.show();
return true;
}
});
// On/off switch
swEnabled.setChecked(enabled);
swEnabled.setOnCheckedChangeListener(new CompoundButton.OnCheckedChangeListener() {
@ -825,4 +836,4 @@ public class ActivityMain extends AppCompatActivity implements SharedPreferences
}
return intent;
}
}
}