1
0
mirror of https://github.com/TeamNewPipe/NewPipe synced 2024-12-24 09:00:31 +00:00

removed settings entry

This commit is contained in:
Harshal Lele 2020-02-04 18:01:39 +05:30
parent af411a61ae
commit bc393e6bcd
4 changed files with 10 additions and 23 deletions

View File

@ -3,7 +3,6 @@ package org.schabi.newpipe.info_list.holder;
import android.content.ClipData;
import android.content.ClipboardManager;
import android.content.Context;
import android.preference.PreferenceManager;
import android.text.util.Linkify;
import android.view.View;
import android.view.ViewGroup;
@ -128,17 +127,13 @@ public class CommentsMiniInfoItemHolder extends InfoItemHolder {
}
});
boolean copyCommentOnLongPress = PreferenceManager.getDefaultSharedPreferences(
itemBuilder.getContext()).getBoolean(itemBuilder.getContext().getString(R.string.copy_comment_long_press),
false);
if(copyCommentOnLongPress){
itemView.setOnLongClickListener(new View.OnLongClickListener() {
@Override
public boolean onLongClick(View view) {
ClipboardManager clipboardManager = (ClipboardManager) itemBuilder.getContext().getSystemService(Context.CLIPBOARD_SERVICE);
ClipboardManager clipboardManager = (ClipboardManager) itemBuilder.getContext()
.getSystemService(Context.CLIPBOARD_SERVICE);
clipboardManager.setPrimaryClip(ClipData.newPlainText(null,itemContentView.getText()));
Toast.makeText(itemBuilder.getContext(), R.string.msg_copied, Toast.LENGTH_SHORT).show();
return true;
@ -147,7 +142,6 @@ public class CommentsMiniInfoItemHolder extends InfoItemHolder {
});
}
}
private void ellipsize() {
if (itemContentView.getLineCount() > commentDefaultLines){

View File

@ -159,7 +159,6 @@
<string name="show_play_with_kodi_key" translatable="false">show_play_with_kodi</string>
<string name="show_next_video_key" translatable="false">show_next_video</string>
<string name="show_comments_key" translatable="false">show_comments</string>
<string name="copy_comment_long_press" translatable="false">copy_comment_long_press</string>
<string name="stream_info_selected_tab_key" translatable="false">stream_info_selected_tab</string>
<string name="show_hold_to_append_key" translatable="false">show_hold_to_append</string>
<string name="default_language_value">en</string>

View File

@ -76,7 +76,6 @@
<string name="download_thumbnail_title">Load thumbnails</string>
<string name="show_comments_title">Show comments</string>
<string name="show_comments_summary">Disable to stop showing comments</string>
<string name="copy_comment_long_press_title">Copy comment on long press</string>
<string name="download_thumbnail_summary">Turn off to prevent loading thumbnails, saving data and memory usage. Changes clear both in-memory and on-disk image cache.</string>
<string name="thumbnail_cache_wipe_complete_notice">Image cache wiped</string>
<string name="metadata_cache_wipe_title">Wipe cached metadata</string>

View File

@ -65,11 +65,6 @@
android:title="@string/show_comments_title"
android:summary="@string/show_comments_summary"/>
<SwitchPreference
app:iconSpaceReserved="false"
android:defaultValue="false"
android:key="@string/copy_comment_long_press"
android:title="@string/copy_comment_long_press_title"/>
<Preference
app:iconSpaceReserved="false"