Search in sources :

Example 11 with EntityIntentBuilder

use of com.xabber.android.data.intent.EntityIntentBuilder in project xabber-android by redsolution.

the class GroupEditActivity method createIntent.

public static Intent createIntent(Context context, AccountJid account, UserJid user) {
    Intent intent = new EntityIntentBuilder(context, GroupEditActivity.class).setAccount(account).setUser(user).build();
    intent.setFlags(Intent.FLAG_ACTIVITY_REORDER_TO_FRONT);
    return intent;
}
Also used : Intent(android.content.Intent) EntityIntentBuilder(com.xabber.android.data.intent.EntityIntentBuilder)

Example 12 with EntityIntentBuilder

use of com.xabber.android.data.intent.EntityIntentBuilder in project xabber-android by redsolution.

the class QuestionActivity method createIntent.

/**
 * @param context
 * @param account
 * @param user
 * @param showQuestion  <code>false</code> is used for shared secret.
 * @param answerRequest <code>false</code> is used to ask a question.
 * @param question      must be not <code>null</code> if showQuestion and
 *                      answerRequest are <code>true</code>.
 * @return
 */
public static Intent createIntent(Context context, AccountJid account, UserJid user, boolean showQuestion, boolean answerRequest, String question) {
    Intent intent = new EntityIntentBuilder(context, QuestionActivity.class).setAccount(account).setUser(user).build();
    intent.putExtra(EXTRA_FIELD_SHOW_QUESTION, showQuestion);
    intent.putExtra(EXTRA_FIELD_ANSWER_REQUEST, answerRequest);
    intent.putExtra(Intent.EXTRA_TEXT, question);
    return intent;
}
Also used : Intent(android.content.Intent) EntityIntentBuilder(com.xabber.android.data.intent.EntityIntentBuilder)

Example 13 with EntityIntentBuilder

use of com.xabber.android.data.intent.EntityIntentBuilder in project xabber-android by redsolution.

the class AccountInfoEditorActivity method createIntent.

public static Intent createIntent(Context context, AccountJid account, String vCard) {
    Intent intent = new EntityIntentBuilder(context, AccountInfoEditorActivity.class).setAccount(account).build();
    intent.putExtra(ARG_VCARD, vCard);
    return intent;
}
Also used : Intent(android.content.Intent) EntityIntentBuilder(com.xabber.android.data.intent.EntityIntentBuilder)

Example 14 with EntityIntentBuilder

use of com.xabber.android.data.intent.EntityIntentBuilder in project xabber-android by redsolution.

the class ChatActivity method createSpecificChatIntent.

public static Intent createSpecificChatIntent(Context context, AccountJid account, UserJid user) {
    Intent intent = new EntityIntentBuilder(context, ChatActivity.class).setAccount(account).setUser(user).build();
    intent.setAction(ACTION_SPECIFIC_CHAT);
    AbstractChat chat = MessageManager.getInstance().getChat(account, user);
    intent.putExtra(KEY_SHOW_ARCHIVED, chat != null && chat.isArchived());
    return intent;
}
Also used : AbstractChat(com.xabber.android.data.message.AbstractChat) Intent(android.content.Intent) EntityIntentBuilder(com.xabber.android.data.intent.EntityIntentBuilder)

Example 15 with EntityIntentBuilder

use of com.xabber.android.data.intent.EntityIntentBuilder in project xabber-android by redsolution.

the class ContactListActivity method createMucInviteIntent.

public static Intent createMucInviteIntent(Context context, AccountJid account, UserJid user) {
    Intent intent = new EntityIntentBuilder(context, ContactListActivity.class).setAccount(account).setUser(user).build();
    intent.setAction(ACTION_INCOMING_MUC_INVITE);
    return intent;
}
Also used : Intent(android.content.Intent) EntityIntentBuilder(com.xabber.android.data.intent.EntityIntentBuilder)

Aggregations

Intent (android.content.Intent)20 EntityIntentBuilder (com.xabber.android.data.intent.EntityIntentBuilder)20 AbstractChat (com.xabber.android.data.message.AbstractChat)1