mirror of
https://github.com/oxen-io/session-android.git
synced 2024-12-25 09:17:44 +00:00
Hide emoji button in media flows when system emoji are enabled.
Fixes #8581
This commit is contained in:
parent
e74c429695
commit
c6d3bed8da
@ -180,8 +180,6 @@ public class MediaSendFragment extends Fragment implements ViewTreeObserver.OnGl
|
|||||||
captionText.clearFocus();
|
captionText.clearFocus();
|
||||||
composeText.requestFocus();
|
composeText.requestFocus();
|
||||||
|
|
||||||
emojiToggle.setOnClickListener(this::onEmojiToggleClicked);
|
|
||||||
|
|
||||||
fragmentPagerAdapter = new MediaSendFragmentPagerAdapter(requireActivity().getSupportFragmentManager(), locale);
|
fragmentPagerAdapter = new MediaSendFragmentPagerAdapter(requireActivity().getSupportFragmentManager(), locale);
|
||||||
fragmentPager.setAdapter(fragmentPagerAdapter);
|
fragmentPager.setAdapter(fragmentPagerAdapter);
|
||||||
|
|
||||||
@ -210,6 +208,13 @@ public class MediaSendFragment extends Fragment implements ViewTreeObserver.OnGl
|
|||||||
sendButton.disableTransport(transportOption.getType() == TransportOption.Type.SMS ? TransportOption.Type.TEXTSECURE : TransportOption.Type.SMS);
|
sendButton.disableTransport(transportOption.getType() == TransportOption.Type.SMS ? TransportOption.Type.TEXTSECURE : TransportOption.Type.SMS);
|
||||||
|
|
||||||
composeText.append(getArguments().getString(KEY_BODY));
|
composeText.append(getArguments().getString(KEY_BODY));
|
||||||
|
|
||||||
|
|
||||||
|
if (TextSecurePreferences.isSystemEmojiPreferred(getContext())) {
|
||||||
|
emojiToggle.setVisibility(View.GONE);
|
||||||
|
} else {
|
||||||
|
emojiToggle.setOnClickListener(this::onEmojiToggleClicked);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
@ -177,13 +177,17 @@ public class ScribbleHud extends InputAwareLayout implements ViewTreeObserver.On
|
|||||||
composeText.setOnClickListener(composeKeyPressedListener);
|
composeText.setOnClickListener(composeKeyPressedListener);
|
||||||
composeText.setOnFocusChangeListener(composeKeyPressedListener);
|
composeText.setOnFocusChangeListener(composeKeyPressedListener);
|
||||||
|
|
||||||
emojiToggle.setOnClickListener(this::onEmojiToggleClicked);
|
|
||||||
|
|
||||||
colorPaletteAdapter = new ColorPaletteAdapter();
|
colorPaletteAdapter = new ColorPaletteAdapter();
|
||||||
colorPaletteAdapter.setEventListener(colorPicker::setActiveColor);
|
colorPaletteAdapter.setEventListener(colorPicker::setActiveColor);
|
||||||
|
|
||||||
colorPalette.setLayoutManager(new LinearLayoutManager(getContext()));
|
colorPalette.setLayoutManager(new LinearLayoutManager(getContext()));
|
||||||
colorPalette.setAdapter(colorPaletteAdapter);
|
colorPalette.setAdapter(colorPaletteAdapter);
|
||||||
|
|
||||||
|
if (TextSecurePreferences.isSystemEmojiPreferred(getContext())) {
|
||||||
|
emojiToggle.setVisibility(GONE);
|
||||||
|
} else {
|
||||||
|
emojiToggle.setOnClickListener(this::onEmojiToggleClicked);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
public void setLocale(@NonNull Locale locale) {
|
public void setLocale(@NonNull Locale locale) {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user