Merge pull request #3929 from dhebbeker/feature/remove-unused-interface-OnLayoutChangedListener
Removed unused interface OnLayoutChangedListener.
This commit is contained in:
commit
3e1a8da32a
3 changed files with 1 additions and 27 deletions
|
@ -35,14 +35,13 @@ import com.fsck.k9.mail.Address;
|
||||||
import com.fsck.k9.mailstore.AttachmentResolver;
|
import com.fsck.k9.mailstore.AttachmentResolver;
|
||||||
import com.fsck.k9.mailstore.AttachmentViewInfo;
|
import com.fsck.k9.mailstore.AttachmentViewInfo;
|
||||||
import com.fsck.k9.mailstore.MessageViewInfo;
|
import com.fsck.k9.mailstore.MessageViewInfo;
|
||||||
import com.fsck.k9.view.MessageHeader.OnLayoutChangedListener;
|
|
||||||
import com.fsck.k9.view.MessageWebView;
|
import com.fsck.k9.view.MessageWebView;
|
||||||
import com.fsck.k9.view.MessageWebView.OnPageFinishedListener;
|
import com.fsck.k9.view.MessageWebView.OnPageFinishedListener;
|
||||||
|
|
||||||
import static android.app.DownloadManager.Request.VISIBILITY_VISIBLE_NOTIFY_COMPLETED;
|
import static android.app.DownloadManager.Request.VISIBILITY_VISIBLE_NOTIFY_COMPLETED;
|
||||||
|
|
||||||
|
|
||||||
public class MessageContainerView extends LinearLayout implements OnLayoutChangedListener, OnCreateContextMenuListener {
|
public class MessageContainerView extends LinearLayout implements OnCreateContextMenuListener {
|
||||||
private static final int MENU_ITEM_LINK_VIEW = Menu.FIRST;
|
private static final int MENU_ITEM_LINK_VIEW = Menu.FIRST;
|
||||||
private static final int MENU_ITEM_LINK_SHARE = Menu.FIRST + 1;
|
private static final int MENU_ITEM_LINK_SHARE = Menu.FIRST + 1;
|
||||||
private static final int MENU_ITEM_LINK_COPY = Menu.FIRST + 2;
|
private static final int MENU_ITEM_LINK_COPY = Menu.FIRST + 2;
|
||||||
|
@ -505,13 +504,6 @@ public class MessageContainerView extends LinearLayout implements OnLayoutChange
|
||||||
clearDisplayedContent();
|
clearDisplayedContent();
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
|
||||||
public void onLayoutChanged() {
|
|
||||||
if (mMessageContentView != null) {
|
|
||||||
mMessageContentView.invalidate();
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
public void enableAttachmentButtons(AttachmentViewInfo attachment) {
|
public void enableAttachmentButtons(AttachmentViewInfo attachment) {
|
||||||
getAttachmentView(attachment).enableButtons();
|
getAttachmentView(attachment).enableButtons();
|
||||||
}
|
}
|
||||||
|
|
|
@ -66,7 +66,6 @@ public class MessageTopView extends LinearLayout {
|
||||||
super.onFinishInflate();
|
super.onFinishInflate();
|
||||||
|
|
||||||
mHeaderContainer = findViewById(R.id.header_container);
|
mHeaderContainer = findViewById(R.id.header_container);
|
||||||
// mHeaderContainer.setOnLayoutChangedListener(this);
|
|
||||||
mInflater = LayoutInflater.from(getContext());
|
mInflater = LayoutInflater.from(getContext());
|
||||||
|
|
||||||
viewAnimator = findViewById(R.id.message_layout_animator);
|
viewAnimator = findViewById(R.id.message_layout_animator);
|
||||||
|
|
|
@ -79,7 +79,6 @@ public class MessageHeader extends LinearLayout implements OnClickListener, OnLo
|
||||||
private ContactPictureLoader mContactsPictureLoader;
|
private ContactPictureLoader mContactsPictureLoader;
|
||||||
private ContactBadge mContactBadge;
|
private ContactBadge mContactBadge;
|
||||||
|
|
||||||
private OnLayoutChangedListener mOnLayoutChangedListener;
|
|
||||||
private OnCryptoClickListener onCryptoClickListener;
|
private OnCryptoClickListener onCryptoClickListener;
|
||||||
private OnMenuItemClickListener onMenuItemClickListener;
|
private OnMenuItemClickListener onMenuItemClickListener;
|
||||||
|
|
||||||
|
@ -168,7 +167,6 @@ public class MessageHeader extends LinearLayout implements OnClickListener, OnLo
|
||||||
onAddSenderToContacts();
|
onAddSenderToContacts();
|
||||||
} else if (id == R.id.to || id == R.id.cc || id == R.id.bcc) {
|
} else if (id == R.id.to || id == R.id.cc || id == R.id.bcc) {
|
||||||
expand((TextView)view, ((TextView)view).getEllipsize() != null);
|
expand((TextView)view, ((TextView)view).getEllipsize() != null);
|
||||||
layoutChanged();
|
|
||||||
} else if (id == R.id.crypto_status_icon) {
|
} else if (id == R.id.crypto_status_icon) {
|
||||||
onCryptoClickListener.onCryptoClick();
|
onCryptoClickListener.onCryptoClick();
|
||||||
} else if (id == R.id.icon_single_message_options) {
|
} else if (id == R.id.icon_single_message_options) {
|
||||||
|
@ -399,7 +397,6 @@ public class MessageHeader extends LinearLayout implements OnClickListener, OnLo
|
||||||
expand(mToView, true);
|
expand(mToView, true);
|
||||||
expand(mCcView, true);
|
expand(mCcView, true);
|
||||||
}
|
}
|
||||||
layoutChanged();
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
@ -522,20 +519,6 @@ public class MessageHeader extends LinearLayout implements OnClickListener, OnLo
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
public interface OnLayoutChangedListener {
|
|
||||||
void onLayoutChanged();
|
|
||||||
}
|
|
||||||
|
|
||||||
public void setOnLayoutChangedListener(OnLayoutChangedListener listener) {
|
|
||||||
mOnLayoutChangedListener = listener;
|
|
||||||
}
|
|
||||||
|
|
||||||
private void layoutChanged() {
|
|
||||||
if (mOnLayoutChangedListener != null) {
|
|
||||||
mOnLayoutChangedListener.onLayoutChanged();
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
public void setOnCryptoClickListener(OnCryptoClickListener onCryptoClickListener) {
|
public void setOnCryptoClickListener(OnCryptoClickListener onCryptoClickListener) {
|
||||||
this.onCryptoClickListener = onCryptoClickListener;
|
this.onCryptoClickListener = onCryptoClickListener;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue