Andrew Sapperstein | 4ddda2f | 2013-06-10 11:15:38 -0700 | [diff] [blame] | 1 | /* |
| 2 | * Copyright (C) 2013 Google Inc. |
| 3 | * Licensed to The Android Open Source Project. |
| 4 | * |
| 5 | * Licensed under the Apache License, Version 2.0 (the "License"); |
| 6 | * you may not use this file except in compliance with the License. |
| 7 | * You may obtain a copy of the License at |
| 8 | * |
| 9 | * http://www.apache.org/licenses/LICENSE-2.0 |
| 10 | * |
| 11 | * Unless required by applicable law or agreed to in writing, software |
| 12 | * distributed under the License is distributed on an "AS IS" BASIS, |
| 13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
| 14 | * See the License for the specific language governing permissions and |
| 15 | * limitations under the License. |
| 16 | */ |
| 17 | |
| 18 | package com.android.mail.ui; |
| 19 | |
| 20 | import android.app.Fragment; |
Andrew Sapperstein | 21a6ed2 | 2013-07-17 18:33:00 -0700 | [diff] [blame] | 21 | import android.app.FragmentManager; |
Andrew Sapperstein | 4ddda2f | 2013-06-10 11:15:38 -0700 | [diff] [blame] | 22 | import android.content.res.Resources; |
Martin Hibdon | 50554de | 2014-01-07 16:28:04 -0800 | [diff] [blame] | 23 | import android.graphics.Rect; |
Andrew Sapperstein | 4ddda2f | 2013-06-10 11:15:38 -0700 | [diff] [blame] | 24 | import android.os.Bundle; |
| 25 | import android.view.LayoutInflater; |
| 26 | import android.view.View; |
| 27 | import android.view.ViewGroup; |
| 28 | import android.webkit.WebSettings; |
| 29 | |
| 30 | import com.android.mail.FormattedDateBuilder; |
| 31 | import com.android.mail.R; |
Andrew Sapperstein | 381c322 | 2014-04-20 12:23:57 -0700 | [diff] [blame] | 32 | import com.android.mail.browse.AttachmentActionHandler; |
Andrew Sapperstein | e7e2c0a | 2013-08-02 17:09:54 -0700 | [diff] [blame] | 33 | import com.android.mail.browse.BorderView; |
Andrew Sapperstein | 4ddda2f | 2013-06-10 11:15:38 -0700 | [diff] [blame] | 34 | import com.android.mail.browse.ConversationMessage; |
| 35 | import com.android.mail.browse.ConversationViewAdapter; |
Andrew Sapperstein | 381c322 | 2014-04-20 12:23:57 -0700 | [diff] [blame] | 36 | import com.android.mail.browse.ConversationViewAdapter.MessageFooterItem; |
Andrew Sapperstein | 4ddda2f | 2013-06-10 11:15:38 -0700 | [diff] [blame] | 37 | import com.android.mail.browse.ConversationViewAdapter.MessageHeaderItem; |
| 38 | import com.android.mail.browse.ConversationViewHeader; |
Andrew Sapperstein | 8ec43e8 | 2013-12-17 18:27:55 -0800 | [diff] [blame] | 39 | import com.android.mail.browse.InlineAttachmentViewIntentBuilderCreator; |
| 40 | import com.android.mail.browse.InlineAttachmentViewIntentBuilderCreatorHolder; |
Andrew Sapperstein | 4ddda2f | 2013-06-10 11:15:38 -0700 | [diff] [blame] | 41 | import com.android.mail.browse.MessageFooterView; |
| 42 | import com.android.mail.browse.MessageHeaderView; |
| 43 | import com.android.mail.browse.MessageScrollView; |
| 44 | import com.android.mail.browse.MessageWebView; |
Martin Hibdon | 50554de | 2014-01-07 16:28:04 -0800 | [diff] [blame] | 45 | import com.android.mail.browse.ScrollNotifier.ScrollListener; |
Andrew Sapperstein | e307785 | 2013-12-11 18:04:25 -0800 | [diff] [blame] | 46 | import com.android.mail.browse.WebViewContextMenu; |
Andrew Sapperstein | 562c5ba | 2013-10-09 18:31:50 -0700 | [diff] [blame] | 47 | import com.android.mail.print.PrintUtils; |
| 48 | import com.android.mail.providers.Conversation; |
Andrew Sapperstein | 4ddda2f | 2013-06-10 11:15:38 -0700 | [diff] [blame] | 49 | import com.android.mail.providers.Message; |
| 50 | import com.android.mail.utils.ConversationViewUtils; |
| 51 | |
| 52 | /** |
Martin Hibdon | 50554de | 2014-01-07 16:28:04 -0800 | [diff] [blame] | 53 | * Controller to do most of the heavy lifting for |
| 54 | * {@link SecureConversationViewFragment} and |
| 55 | * {@link com.android.mail.browse.EmlMessageViewFragment}. Currently that work |
| 56 | * is pretty much the rendering logic. |
Andrew Sapperstein | 4ddda2f | 2013-06-10 11:15:38 -0700 | [diff] [blame] | 57 | */ |
| 58 | public class SecureConversationViewController implements |
Andrew Sapperstein | 381c322 | 2014-04-20 12:23:57 -0700 | [diff] [blame] | 59 | MessageHeaderView.MessageHeaderViewCallbacks, ScrollListener, |
| 60 | MessageFooterView.MessageFooterCallbacks { |
Andrew Sapperstein | 4ddda2f | 2013-06-10 11:15:38 -0700 | [diff] [blame] | 61 | private static final String BEGIN_HTML = |
Andrew Sapperstein | d4945f2 | 2014-03-29 18:36:09 -0700 | [diff] [blame] | 62 | "<body style=\"margin: 0 %spx;\"><div style=\"margin: 16px 0; font-size: 80%%\">"; |
Andrew Sapperstein | 4ddda2f | 2013-06-10 11:15:38 -0700 | [diff] [blame] | 63 | private static final String END_HTML = "</div></body>"; |
| 64 | |
| 65 | private final SecureConversationViewControllerCallbacks mCallbacks; |
| 66 | |
| 67 | private MessageWebView mWebView; |
| 68 | private ConversationViewHeader mConversationHeaderView; |
| 69 | private MessageHeaderView mMessageHeaderView; |
Martin Hibdon | 50554de | 2014-01-07 16:28:04 -0800 | [diff] [blame] | 70 | private MessageHeaderView mSnapHeaderView; |
Andrew Sapperstein | 4ddda2f | 2013-06-10 11:15:38 -0700 | [diff] [blame] | 71 | private MessageFooterView mMessageFooterView; |
| 72 | private ConversationMessage mMessage; |
| 73 | private MessageScrollView mScrollView; |
| 74 | |
| 75 | private ConversationViewProgressController mProgressController; |
| 76 | private FormattedDateBuilder mDateBuilder; |
| 77 | |
| 78 | private int mSideMarginInWebPx; |
| 79 | |
| 80 | public SecureConversationViewController(SecureConversationViewControllerCallbacks callbacks) { |
| 81 | mCallbacks = callbacks; |
| 82 | } |
| 83 | |
| 84 | public View onCreateView(LayoutInflater inflater, ViewGroup container, |
| 85 | Bundle savedInstanceState) { |
| 86 | View rootView = inflater.inflate(R.layout.secure_conversation_view, container, false); |
| 87 | mScrollView = (MessageScrollView) rootView.findViewById(R.id.scroll_view); |
| 88 | mConversationHeaderView = (ConversationViewHeader) rootView.findViewById(R.id.conv_header); |
| 89 | mMessageHeaderView = (MessageHeaderView) rootView.findViewById(R.id.message_header); |
Martin Hibdon | 50554de | 2014-01-07 16:28:04 -0800 | [diff] [blame] | 90 | mSnapHeaderView = (MessageHeaderView) rootView.findViewById(R.id.snap_header); |
Andrew Sapperstein | 4ddda2f | 2013-06-10 11:15:38 -0700 | [diff] [blame] | 91 | mMessageFooterView = (MessageFooterView) rootView.findViewById(R.id.message_footer); |
| 92 | |
Martin Hibdon | 50554de | 2014-01-07 16:28:04 -0800 | [diff] [blame] | 93 | mScrollView.addScrollListener(this); |
| 94 | |
Andrew Sapperstein | e7e2c0a | 2013-08-02 17:09:54 -0700 | [diff] [blame] | 95 | // Add color backgrounds to the header and footer. |
| 96 | // Otherwise the backgrounds are grey. They can't |
| 97 | // be set in xml because that would add more overdraw |
| 98 | // in ConversationViewFragment. |
| 99 | final int color = rootView.getResources().getColor( |
| 100 | R.color.message_header_background_color); |
| 101 | mMessageHeaderView.setBackgroundColor(color); |
Andrew Sapperstein | 2ed8c04 | 2014-02-27 18:52:32 -0800 | [diff] [blame] | 102 | mSnapHeaderView.findViewById(R.id.upper_header).setBackgroundColor(color); |
Andrew Sapperstein | e7e2c0a | 2013-08-02 17:09:54 -0700 | [diff] [blame] | 103 | mMessageFooterView.setBackgroundColor(color); |
| 104 | |
| 105 | ((BorderView) rootView.findViewById(R.id.top_border)).disableCardBottomBorder(); |
| 106 | ((BorderView) rootView.findViewById(R.id.bottom_border)).disableCardTopBorder(); |
| 107 | |
Andrew Sapperstein | 4ddda2f | 2013-06-10 11:15:38 -0700 | [diff] [blame] | 108 | mProgressController = new ConversationViewProgressController( |
| 109 | mCallbacks.getFragment(), mCallbacks.getHandler()); |
| 110 | mProgressController.instantiateProgressIndicators(rootView); |
| 111 | mWebView = (MessageWebView) rootView.findViewById(R.id.webview); |
Andrew Sapperstein | e45fd11 | 2013-08-29 17:34:34 -0700 | [diff] [blame] | 112 | mWebView.setOverScrollMode(View.OVER_SCROLL_NEVER); |
Andrew Sapperstein | 4ddda2f | 2013-06-10 11:15:38 -0700 | [diff] [blame] | 113 | mWebView.setWebViewClient(mCallbacks.getWebViewClient()); |
Andrew Sapperstein | 8ec43e8 | 2013-12-17 18:27:55 -0800 | [diff] [blame] | 114 | final InlineAttachmentViewIntentBuilderCreator creator = |
| 115 | InlineAttachmentViewIntentBuilderCreatorHolder. |
Martin Hibdon | 50554de | 2014-01-07 16:28:04 -0800 | [diff] [blame] | 116 | getInlineAttachmentViewIntentCreator(); |
Andrew Sapperstein | 8ec43e8 | 2013-12-17 18:27:55 -0800 | [diff] [blame] | 117 | mWebView.setOnCreateContextMenuListener(new WebViewContextMenu( |
| 118 | mCallbacks.getFragment().getActivity(), |
Andy Huang | 3c6fd44 | 2014-03-24 19:56:46 -0700 | [diff] [blame] | 119 | creator.createInlineAttachmentViewIntentBuilder(null, -1))); |
Andrew Sapperstein | 4ddda2f | 2013-06-10 11:15:38 -0700 | [diff] [blame] | 120 | mWebView.setFocusable(false); |
| 121 | final WebSettings settings = mWebView.getSettings(); |
| 122 | |
| 123 | settings.setJavaScriptEnabled(false); |
| 124 | settings.setLayoutAlgorithm(WebSettings.LayoutAlgorithm.NORMAL); |
| 125 | |
| 126 | ConversationViewUtils.setTextZoom(mCallbacks.getFragment().getResources(), settings); |
| 127 | |
| 128 | settings.setSupportZoom(true); |
| 129 | settings.setBuiltInZoomControls(true); |
| 130 | settings.setDisplayZoomControls(false); |
| 131 | |
| 132 | mScrollView.setInnerScrollableView(mWebView); |
| 133 | |
| 134 | return rootView; |
| 135 | } |
| 136 | |
| 137 | public void onActivityCreated(Bundle savedInstanceState) { |
| 138 | mCallbacks.setupConversationHeaderView(mConversationHeaderView); |
| 139 | |
| 140 | final Fragment fragment = mCallbacks.getFragment(); |
| 141 | |
| 142 | mDateBuilder = new FormattedDateBuilder(fragment.getActivity()); |
Andrew Sapperstein | 14f9374 | 2013-07-25 14:29:56 -0700 | [diff] [blame] | 143 | mMessageHeaderView.initialize( |
Andrew Sapperstein | 4ddda2f | 2013-06-10 11:15:38 -0700 | [diff] [blame] | 144 | mCallbacks.getConversationAccountController(), mCallbacks.getAddressCache()); |
Andrew Sapperstein | 4ddda2f | 2013-06-10 11:15:38 -0700 | [diff] [blame] | 145 | mMessageHeaderView.setContactInfoSource(mCallbacks.getContactInfoSource()); |
| 146 | mMessageHeaderView.setCallbacks(this); |
| 147 | mMessageHeaderView.setExpandable(false); |
| 148 | mMessageHeaderView.setViewOnlyMode(mCallbacks.isViewOnlyMode()); |
| 149 | |
Martin Hibdon | 50554de | 2014-01-07 16:28:04 -0800 | [diff] [blame] | 150 | mSnapHeaderView.setSnappy(); |
| 151 | mSnapHeaderView.initialize( |
| 152 | mCallbacks.getConversationAccountController(), mCallbacks.getAddressCache()); |
| 153 | mSnapHeaderView.setContactInfoSource(mCallbacks.getContactInfoSource()); |
| 154 | mSnapHeaderView.setCallbacks(this); |
| 155 | mSnapHeaderView.setExpandable(false); |
| 156 | mSnapHeaderView.setViewOnlyMode(mCallbacks.isViewOnlyMode()); |
| 157 | |
Andrew Sapperstein | 4ddda2f | 2013-06-10 11:15:38 -0700 | [diff] [blame] | 158 | mCallbacks.setupMessageHeaderVeiledMatcher(mMessageHeaderView); |
Martin Hibdon | 50554de | 2014-01-07 16:28:04 -0800 | [diff] [blame] | 159 | mCallbacks.setupMessageHeaderVeiledMatcher(mSnapHeaderView); |
Andrew Sapperstein | 4ddda2f | 2013-06-10 11:15:38 -0700 | [diff] [blame] | 160 | |
Andrew Sapperstein | f59d01c | 2014-02-20 10:27:06 -0800 | [diff] [blame] | 161 | mMessageFooterView.initialize(fragment.getLoaderManager(), fragment.getFragmentManager(), |
Andrew Sapperstein | 381c322 | 2014-04-20 12:23:57 -0700 | [diff] [blame] | 162 | mCallbacks.getConversationAccountController(), this); |
Andrew Sapperstein | 4ddda2f | 2013-06-10 11:15:38 -0700 | [diff] [blame] | 163 | |
| 164 | mCallbacks.startMessageLoader(); |
| 165 | |
| 166 | mProgressController.showLoadingStatus(mCallbacks.isViewVisibleToUser()); |
| 167 | |
| 168 | final Resources r = mCallbacks.getFragment().getResources(); |
Andrew Sapperstein | 90eccf9 | 2013-08-22 11:53:23 -0700 | [diff] [blame] | 169 | mSideMarginInWebPx = (int) (r.getDimensionPixelOffset( |
| 170 | R.dimen.conversation_message_content_margin_side) / r.getDisplayMetrics().density); |
Andrew Sapperstein | 4ddda2f | 2013-06-10 11:15:38 -0700 | [diff] [blame] | 171 | } |
| 172 | |
Andrew Sapperstein | 381c322 | 2014-04-20 12:23:57 -0700 | [diff] [blame] | 173 | public void onDestroyView() { |
Andrew Sapperstein | 41d2b6b | 2014-04-23 14:20:15 -0700 | [diff] [blame] | 174 | if (mMessage != null && mMessage.getConversation() != null) { |
| 175 | AttachmentActionHandler.unregisterDismissListeners(mMessage.getConversation().uri); |
| 176 | } |
Andrew Sapperstein | 381c322 | 2014-04-20 12:23:57 -0700 | [diff] [blame] | 177 | } |
| 178 | |
Martin Hibdon | 50554de | 2014-01-07 16:28:04 -0800 | [diff] [blame] | 179 | @Override |
| 180 | public void onNotifierScroll(final int y) { |
| 181 | // We need to decide whether or not to display the snap header. |
| 182 | // Get the location of the moveable message header inside the scroll view. |
| 183 | Rect rect = new Rect(); |
| 184 | mScrollView.offsetDescendantRectToMyCoords(mMessageHeaderView, rect); |
| 185 | |
| 186 | // If we have scrolled further than the distance from the top of the scrollView to the top |
| 187 | // of the message header, then the message header is at least partially ofscreen. As soon |
| 188 | // as the message header goes partially offscreen we need to display the snap header. |
| 189 | if (y > rect.top) { |
| 190 | mSnapHeaderView.setVisibility(View.VISIBLE); |
| 191 | } else { |
| 192 | mSnapHeaderView.setVisibility(View.GONE); |
| 193 | } |
| 194 | } |
| 195 | |
Andrew Sapperstein | 4ddda2f | 2013-06-10 11:15:38 -0700 | [diff] [blame] | 196 | /** |
| 197 | * Populate the adapter with overlay views (message headers, super-collapsed |
| 198 | * blocks, a conversation header), and return an HTML document with spacer |
| 199 | * divs inserted for all overlays. |
| 200 | */ |
| 201 | public void renderMessage(ConversationMessage message) { |
| 202 | mMessage = message; |
| 203 | |
Andrew Sapperstein | 8ec43e8 | 2013-12-17 18:27:55 -0800 | [diff] [blame] | 204 | final boolean alwaysShowImages = mCallbacks.shouldAlwaysShowImages(); |
| 205 | mWebView.getSettings().setBlockNetworkImage( |
| 206 | !alwaysShowImages && !mMessage.alwaysShowImages); |
Andrew Sapperstein | 4ddda2f | 2013-06-10 11:15:38 -0700 | [diff] [blame] | 207 | |
| 208 | // Add formatting to message body |
| 209 | // At this point, only adds margins. |
| 210 | StringBuilder dataBuilder = new StringBuilder( |
| 211 | String.format(BEGIN_HTML, mSideMarginInWebPx)); |
| 212 | dataBuilder.append(mMessage.getBodyAsHtml()); |
| 213 | dataBuilder.append(END_HTML); |
| 214 | |
| 215 | mWebView.loadDataWithBaseURL(mCallbacks.getBaseUri(), dataBuilder.toString(), |
| 216 | "text/html", "utf-8", null); |
| 217 | final MessageHeaderItem item = ConversationViewAdapter.newMessageHeaderItem( |
Andrew Sapperstein | 14f9374 | 2013-07-25 14:29:56 -0700 | [diff] [blame] | 218 | null, mDateBuilder, mMessage, true, mMessage.alwaysShowImages); |
Tony Mantler | 37ce607 | 2013-10-04 09:28:43 -0700 | [diff] [blame] | 219 | // Clear out the old info from the header before (re)binding |
| 220 | mMessageHeaderView.unbind(); |
Andrew Sapperstein | 4ddda2f | 2013-06-10 11:15:38 -0700 | [diff] [blame] | 221 | mMessageHeaderView.bind(item, false); |
Martin Hibdon | 50554de | 2014-01-07 16:28:04 -0800 | [diff] [blame] | 222 | |
| 223 | mSnapHeaderView.unbind(); |
| 224 | mSnapHeaderView.bind(item, false); |
| 225 | |
Andrew Sapperstein | 4ddda2f | 2013-06-10 11:15:38 -0700 | [diff] [blame] | 226 | if (mMessage.hasAttachments) { |
| 227 | mMessageFooterView.setVisibility(View.VISIBLE); |
Andrew Sapperstein | 381c322 | 2014-04-20 12:23:57 -0700 | [diff] [blame] | 228 | mMessageFooterView.bind( |
| 229 | item, ConversationViewAdapter.newMessageFooterItem(null, item), false); |
Andrew Sapperstein | 4ddda2f | 2013-06-10 11:15:38 -0700 | [diff] [blame] | 230 | } |
| 231 | } |
| 232 | |
| 233 | public ConversationMessage getMessage() { |
| 234 | return mMessage; |
| 235 | } |
| 236 | |
| 237 | public ConversationViewHeader getConversationHeaderView() { |
| 238 | return mConversationHeaderView; |
| 239 | } |
| 240 | |
| 241 | public void dismissLoadingStatus() { |
| 242 | mProgressController.dismissLoadingStatus(); |
| 243 | } |
| 244 | |
| 245 | public void setSubject(String subject) { |
Andrew Sapperstein | e6bf30d | 2014-03-13 19:19:26 -0700 | [diff] [blame] | 246 | mConversationHeaderView.setSubject(subject); |
Andrew Sapperstein | 4ddda2f | 2013-06-10 11:15:38 -0700 | [diff] [blame] | 247 | } |
| 248 | |
Andrew Sapperstein | 562c5ba | 2013-10-09 18:31:50 -0700 | [diff] [blame] | 249 | public void printMessage() { |
| 250 | final Conversation conversation = mMessage.getConversation(); |
Andrew Sapperstein | 234d353 | 2013-10-29 14:54:04 -0700 | [diff] [blame] | 251 | PrintUtils.printMessage(mCallbacks.getFragment().getActivity(), mMessage, |
Andrew Sapperstein | 562c5ba | 2013-10-09 18:31:50 -0700 | [diff] [blame] | 252 | conversation != null ? conversation.subject : mMessage.subject, |
| 253 | mCallbacks.getAddressCache(), mCallbacks.getBaseUri(), false /* useJavascript */); |
| 254 | |
Andrew Sapperstein | 5c1692a | 2013-09-16 11:56:13 -0700 | [diff] [blame] | 255 | } |
| 256 | |
Andrew Sapperstein | 4ddda2f | 2013-06-10 11:15:38 -0700 | [diff] [blame] | 257 | // Start MessageHeaderViewCallbacks implementations |
| 258 | |
| 259 | @Override |
| 260 | public void setMessageSpacerHeight(MessageHeaderItem item, int newSpacerHeight) { |
| 261 | // Do nothing. |
| 262 | } |
| 263 | |
| 264 | @Override |
Andrew Sapperstein | cee3c90 | 2013-07-31 10:52:02 -0700 | [diff] [blame] | 265 | public void setMessageExpanded(MessageHeaderItem item, int newSpacerHeight, |
| 266 | int topBorderHeight, int bottomBorderHeight) { |
Andrew Sapperstein | 4ddda2f | 2013-06-10 11:15:38 -0700 | [diff] [blame] | 267 | // Do nothing. |
| 268 | } |
| 269 | |
| 270 | @Override |
| 271 | public void setMessageDetailsExpanded(MessageHeaderItem i, boolean expanded, int heightBefore) { |
| 272 | // Do nothing. |
| 273 | } |
| 274 | |
| 275 | @Override |
| 276 | public void showExternalResources(final Message msg) { |
| 277 | mWebView.getSettings().setBlockNetworkImage(false); |
| 278 | } |
| 279 | |
| 280 | @Override |
| 281 | public void showExternalResources(final String rawSenderAddress) { |
| 282 | mWebView.getSettings().setBlockNetworkImage(false); |
| 283 | } |
| 284 | |
| 285 | @Override |
| 286 | public boolean supportsMessageTransforms() { |
| 287 | return false; |
| 288 | } |
| 289 | |
| 290 | @Override |
| 291 | public String getMessageTransforms(final Message msg) { |
| 292 | return null; |
| 293 | } |
| 294 | |
Andrew Sapperstein | 21a6ed2 | 2013-07-17 18:33:00 -0700 | [diff] [blame] | 295 | @Override |
James Lemieux | 8e1ffbf | 2014-04-22 15:53:31 -0700 | [diff] [blame] | 296 | public boolean isSecure() { |
| 297 | return true; |
| 298 | } |
| 299 | |
| 300 | @Override |
Andrew Sapperstein | 21a6ed2 | 2013-07-17 18:33:00 -0700 | [diff] [blame] | 301 | public FragmentManager getFragmentManager() { |
| 302 | return mCallbacks.getFragment().getFragmentManager(); |
| 303 | } |
| 304 | |
Andrew Sapperstein | 4ddda2f | 2013-06-10 11:15:38 -0700 | [diff] [blame] | 305 | // End MessageHeaderViewCallbacks implementations |
Andrew Sapperstein | 381c322 | 2014-04-20 12:23:57 -0700 | [diff] [blame] | 306 | |
| 307 | // START MessageFooterCallbacks |
| 308 | |
| 309 | @Override |
| 310 | public void setMessageSpacerHeight(MessageFooterItem item, int newSpacerHeight) { |
| 311 | // Do nothing. |
| 312 | } |
| 313 | |
| 314 | @Override |
| 315 | public MessageFooterView getViewForItem(MessageFooterItem item) { |
| 316 | return mMessageFooterView; |
| 317 | } |
| 318 | |
| 319 | @Override |
| 320 | public int getUpdatedHeight(MessageFooterItem item) { |
| 321 | return 0; // should never get called since we'll always have a footer view |
| 322 | } |
| 323 | |
| 324 | // END MessageFooterCallbacks |
Andrew Sapperstein | 4ddda2f | 2013-06-10 11:15:38 -0700 | [diff] [blame] | 325 | } |