1
0
mirror of https://github.com/moparisthebest/k-9 synced 2024-11-24 02:12:15 -05:00

re-enable setOnFlagListener

This commit is contained in:
Jesse Vincent 2011-02-11 12:10:45 -05:00
parent 06baf3f602
commit 9deea33426
2 changed files with 13 additions and 7 deletions

View File

@ -1137,6 +1137,12 @@ public class MessageView extends K9Activity implements OnClickListener {
mMessageView.loadBodyFromUrl("file:///android_asset/downloading.html"); mMessageView.loadBodyFromUrl("file:///android_asset/downloading.html");
} }
mMessageView.setHeaders(message, account); mMessageView.setHeaders(message, account);
mMessageView.setOnFlagListener(new OnClickListener() {
@Override
public void onClick(View v) {
onFlag();
}
});
} }
}); });
} }

View File

@ -91,13 +91,8 @@ public class SingleMessageView extends LinearLayout {
public void setHeaders(final Message message, Account account) { public void setHeaders(final Message message, Account account) {
try { try {
mHeaderContainer.populate(message, account); mHeaderContainer.populate(message, account);
mHeaderContainer.setOnFlagListener(new OnClickListener() {
@Override public void onClick(View v) {
if (message != null) {
//TODO: reenable onFlag();
}
}
});
} catch (Exception me) { } catch (Exception me) {
Log.e(K9.LOG_TAG, "setHeaders - error", me); Log.e(K9.LOG_TAG, "setHeaders - error", me);
} }
@ -108,6 +103,11 @@ public class SingleMessageView extends LinearLayout {
mDownloadRemainder.setVisibility(View.VISIBLE); mDownloadRemainder.setVisibility(View.VISIBLE);
} }
} }
public void setOnFlagListener(OnClickListener listener) {
mHeaderContainer.setOnFlagListener(listener);
}
public void showAllHeaders() { public void showAllHeaders() {
mHeaderContainer.onShowAdditionalHeaders(); mHeaderContainer.onShowAdditionalHeaders();
} }