diff options
author | Sarmad Hashmi <mhashmi@google.com> | 2016-03-11 23:51:59 +0000 |
---|---|---|
committer | android-build-merger <android-build-merger@google.com> | 2016-03-11 23:51:59 +0000 |
commit | 4dd273c86dc35397248fa6b548ed11cb369bc785 (patch) | |
tree | f5e7d9258d8d4273512e3095b4b2e53fef1e90f8 /src/com | |
parent | ab1319e179d3e54c172b7574686db5f8fa6caa98 (diff) | |
parent | cf4e90702260cc04c42c202affac7da351454058 (diff) |
Add share button to voicemail cards. am: 83f27f563c
am: cf4e907022
* commit 'cf4e90702260cc04c42c202affac7da351454058':
Add share button to voicemail cards.
Diffstat (limited to 'src/com')
-rw-r--r-- | src/com/android/dialer/voicemail/VoicemailPlaybackLayout.java | 14 | ||||
-rw-r--r-- | src/com/android/dialerbind/ObjectFactory.java | 4 |
2 files changed, 18 insertions, 0 deletions
diff --git a/src/com/android/dialer/voicemail/VoicemailPlaybackLayout.java b/src/com/android/dialer/voicemail/VoicemailPlaybackLayout.java index 0cbe7f2c2..8c869d183 100644 --- a/src/com/android/dialer/voicemail/VoicemailPlaybackLayout.java +++ b/src/com/android/dialer/voicemail/VoicemailPlaybackLayout.java @@ -275,7 +275,11 @@ public class VoicemailPlaybackLayout extends LinearLayout private ImageButton mPlaybackSpeakerphone; private ImageButton mDeleteButton; private ImageButton mArchiveButton; + private ImageButton mShareButton; + private Space mArchiveSpace; + private Space mShareSpace; + private TextView mStateText; private TextView mPositionText; private TextView mTotalDurationText; @@ -304,6 +308,12 @@ public class VoicemailPlaybackLayout extends LinearLayout updateArchiveUI(mVoicemailUri); updateArchiveButton(mVoicemailUri); } + + if (ObjectFactory.isVoicemailShareEnabled(mContext)) { + // Show share button and space before it + mShareSpace.setVisibility(View.VISIBLE); + mShareButton.setVisibility(View.VISIBLE); + } } @Override @@ -315,7 +325,11 @@ public class VoicemailPlaybackLayout extends LinearLayout mPlaybackSpeakerphone = (ImageButton) findViewById(R.id.playback_speakerphone); mDeleteButton = (ImageButton) findViewById(R.id.delete_voicemail); mArchiveButton =(ImageButton) findViewById(R.id.archive_voicemail); + mShareButton = (ImageButton) findViewById(R.id.share_voicemail); + mArchiveSpace = (Space) findViewById(R.id.space_before_archive_voicemail); + mShareSpace = (Space) findViewById(R.id.space_before_share_voicemail); + mStateText = (TextView) findViewById(R.id.playback_state_text); mPositionText = (TextView) findViewById(R.id.playback_position_text); mTotalDurationText = (TextView) findViewById(R.id.total_duration_text); diff --git a/src/com/android/dialerbind/ObjectFactory.java b/src/com/android/dialerbind/ObjectFactory.java index 935c9f73a..9f75e3912 100644 --- a/src/com/android/dialerbind/ObjectFactory.java +++ b/src/com/android/dialerbind/ObjectFactory.java @@ -48,6 +48,10 @@ public class ObjectFactory { return false; } + public static boolean isVoicemailShareEnabled(Context context) { + return false; + } + @Nullable public static ExtendedBlockingButtonRenderer newExtendedBlockingButtonRenderer( Context context, ExtendedBlockingButtonRenderer.Listener listener) { |