aboutsummaryrefslogtreecommitdiffstats
path: root/src/eu/siacs/conversations/ui
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--src/eu/siacs/conversations/ui/ContactDetailsActivity.java14
-rw-r--r--src/eu/siacs/conversations/ui/ConversationActivity.java9
-rw-r--r--src/eu/siacs/conversations/ui/ManageAccountActivity.java8
3 files changed, 13 insertions, 18 deletions
diff --git a/src/eu/siacs/conversations/ui/ContactDetailsActivity.java b/src/eu/siacs/conversations/ui/ContactDetailsActivity.java
index 9d384c60..9926e126 100644
--- a/src/eu/siacs/conversations/ui/ContactDetailsActivity.java
+++ b/src/eu/siacs/conversations/ui/ContactDetailsActivity.java
@@ -39,8 +39,6 @@ import eu.siacs.conversations.utils.UIHelper;
public class ContactDetailsActivity extends XmppActivity {
public static final String ACTION_VIEW_CONTACT = "view_contact";
- protected ContactDetailsActivity activity = this;
-
private Contact contact;
private String accountJid;
@@ -58,8 +56,8 @@ public class ContactDetailsActivity extends XmppActivity {
@Override
public void onClick(DialogInterface dialog, int which) {
- activity.xmppConnectionService.deleteContactOnServer(contact);
- activity.finish();
+ ContactDetailsActivity.this.xmppConnectionService.deleteContactOnServer(contact);
+ ContactDetailsActivity.this.finish();
}
};
@@ -73,14 +71,14 @@ public class ContactDetailsActivity extends XmppActivity {
intent.putExtra(Intents.Insert.IM_PROTOCOL,
CommonDataKinds.Im.PROTOCOL_JABBER);
intent.putExtra("finishActivityOnSaveCompleted", true);
- activity.startActivityForResult(intent, 0);
+ ContactDetailsActivity.this.startActivityForResult(intent, 0);
}
};
private OnClickListener onBadgeClick = new OnClickListener() {
@Override
public void onClick(View v) {
- AlertDialog.Builder builder = new AlertDialog.Builder(activity);
+ AlertDialog.Builder builder = new AlertDialog.Builder(ContactDetailsActivity.this);
builder.setTitle(getString(R.string.action_add_phone_book));
builder.setMessage(getString(R.string.add_phone_book_text,
contact.getJid()));
@@ -206,7 +204,7 @@ public class ContactDetailsActivity extends XmppActivity {
@Override
public void onValueEdited(String value) {
contact.setServerName(value);
- activity.xmppConnectionService
+ ContactDetailsActivity.this.xmppConnectionService
.pushContactToServer(contact);
populateView();
}
@@ -354,7 +352,7 @@ public class ContactDetailsActivity extends XmppActivity {
@Override
public void onClick(View v) {
- PgpEngine pgp = activity.xmppConnectionService
+ PgpEngine pgp = ContactDetailsActivity.this.xmppConnectionService
.getPgpEngine();
if (pgp != null) {
PendingIntent intent = pgp.getIntentForKey(contact);
diff --git a/src/eu/siacs/conversations/ui/ConversationActivity.java b/src/eu/siacs/conversations/ui/ConversationActivity.java
index f3db8cb4..ad1cd283 100644
--- a/src/eu/siacs/conversations/ui/ConversationActivity.java
+++ b/src/eu/siacs/conversations/ui/ConversationActivity.java
@@ -74,7 +74,6 @@ public class ConversationActivity extends XmppActivity implements
private boolean paneShouldBeOpen = true;
private ArrayAdapter<Conversation> listAdapter;
- protected ConversationActivity activity = this;
private Toast prepareImageToast;
private Uri pendingImageUri = null;
@@ -223,7 +222,7 @@ public class ConversationActivity extends XmppActivity implements
ab.setDisplayHomeAsUpEnabled(true);
ab.setHomeButtonEnabled(true);
if (getSelectedConversation().getMode() == Conversation.MODE_SINGLE
- || activity.useSubjectToIdentifyConference()) {
+ || ConversationActivity.this.useSubjectToIdentifyConference()) {
ab.setTitle(getSelectedConversation().getName());
} else {
ab.setTitle(getSelectedConversation().getContactJid()
@@ -450,7 +449,7 @@ public class ConversationActivity extends XmppActivity implements
@Override
public void onClick(DialogInterface dialog, int which) {
- activity.xmppConnectionService
+ ConversationActivity.this.xmppConnectionService
.clearConversationHistory(conversation);
if (endConversationCheckBox.isChecked()) {
endConversation(conversation);
@@ -585,7 +584,7 @@ public class ConversationActivity extends XmppActivity implements
+ (durations[which] * 1000);
}
conversation.setMutedTill(till);
- activity.xmppConnectionService.databaseBackend
+ ConversationActivity.this.xmppConnectionService.databaseBackend
.updateConversation(conversation);
ConversationFragment selectedFragment = (ConversationFragment) getFragmentManager()
.findFragmentByTag("conversation");
@@ -855,7 +854,7 @@ public class ConversationActivity extends XmppActivity implements
@Override
public void userInputRequried(PendingIntent pi,
Message message) {
- activity.runIntent(pi,
+ ConversationActivity.this.runIntent(pi,
ConversationActivity.REQUEST_SEND_MESSAGE);
}
diff --git a/src/eu/siacs/conversations/ui/ManageAccountActivity.java b/src/eu/siacs/conversations/ui/ManageAccountActivity.java
index ca17eb0d..afe9e06e 100644
--- a/src/eu/siacs/conversations/ui/ManageAccountActivity.java
+++ b/src/eu/siacs/conversations/ui/ManageAccountActivity.java
@@ -24,8 +24,6 @@ import android.widget.ListView;
public class ManageAccountActivity extends XmppActivity {
- protected ManageAccountActivity activity = this;
-
protected Account selectedAccount = null;
protected List<Account> accountList = new ArrayList<Account>();
@@ -72,7 +70,7 @@ public class ManageAccountActivity extends XmppActivity {
public void onCreateContextMenu(ContextMenu menu, View v,
ContextMenuInfo menuInfo) {
super.onCreateContextMenu(menu, v, menuInfo);
- activity.getMenuInflater().inflate(R.menu.manageaccounts_context, menu);
+ ManageAccountActivity.this.getMenuInflater().inflate(R.menu.manageaccounts_context, menu);
AdapterView.AdapterContextMenuInfo acmi = (AdapterContextMenuInfo) menuInfo;
this.selectedAccount = accountList.get(acmi.position);
if (this.selectedAccount.isOptionSet(Account.OPTION_DISABLED)) {
@@ -181,7 +179,7 @@ public class ManageAccountActivity extends XmppActivity {
}
private void publishOpenPGPPublicKey(Account account) {
- if (activity.hasPgp()) {
+ if (ManageAccountActivity.this.hasPgp()) {
announcePgp(account, null);
} else {
this.showInstallPgpDialog();
@@ -189,7 +187,7 @@ public class ManageAccountActivity extends XmppActivity {
}
private void deleteAccount(final Account account) {
- AlertDialog.Builder builder = new AlertDialog.Builder(activity);
+ AlertDialog.Builder builder = new AlertDialog.Builder(ManageAccountActivity.this);
builder.setTitle(getString(R.string.mgmt_account_are_you_sure));
builder.setIconAttribute(android.R.attr.alertDialogIcon);
builder.setMessage(getString(R.string.mgmt_account_delete_confirm_text));