class SecuredActivity extends MultiLanguageActivity implements P2pProcessingStatusBroadcastReceiver.StatusUpdate {

    @Override
    public boolean onOptionsItemSelected(MenuItem item) {
        int i = item.getItemId();
        if (i == R.id.switchLanguageMenuItem) {
            String newLanguagePreference = context().userService().switchLanguagePreference();
            Utils.showShortToast(this, getString(R.string.language_change_prepend_message) + " " + newLanguagePreference + ".");

            return super.onOptionsItemSelected(item);
        } else if (i == MENU_ITEM_LOGOUT) {
            DrishtiApplication application = (DrishtiApplication) getApplication();
            application.logoutCurrentUser();

            return super.onOptionsItemSelected(item);
        } else {
            return super.onOptionsItemSelected(item);
        }
    }

}