Fix accent
This commit is contained in:
parent
5d651f4e83
commit
fa4f832942
|
@ -17,7 +17,6 @@ package app.fedilab.android.drawers;
|
|||
|
||||
import android.content.Context;
|
||||
import android.content.Intent;
|
||||
import android.content.SharedPreferences;
|
||||
import android.graphics.drawable.Drawable;
|
||||
import android.os.Bundle;
|
||||
|
||||
|
@ -37,7 +36,6 @@ import app.fedilab.android.helper.Helper;
|
|||
import app.fedilab.android.R;
|
||||
import app.fedilab.android.activities.ListActivity;
|
||||
|
||||
import static app.fedilab.android.helper.Helper.changeDrawableColor;
|
||||
|
||||
|
||||
/**
|
||||
|
@ -84,19 +82,8 @@ public class ListAdapter extends BaseAdapter {
|
|||
} else {
|
||||
holder = (ViewHolder) convertView.getTag();
|
||||
}
|
||||
SharedPreferences sharedpreferences = context.getSharedPreferences(Helper.APP_PREFS, Context.MODE_PRIVATE);
|
||||
int theme = sharedpreferences.getInt(Helper.SET_THEME, Helper.THEME_DARK);
|
||||
|
||||
if (theme == Helper.THEME_LIGHT) {
|
||||
holder.search_container.setBackgroundResource(R.color.mastodonC3__);
|
||||
Helper.changeDrawableColor(context, R.drawable.ic_keyboard_arrow_right, R.color.black);
|
||||
} else if (theme == Helper.THEME_DARK) {
|
||||
holder.search_container.setBackgroundResource(R.color.mastodonC1_);
|
||||
Helper.changeDrawableColor(context, R.drawable.ic_keyboard_arrow_right, R.color.dark_text);
|
||||
} else if (theme == Helper.THEME_BLACK) {
|
||||
holder.search_container.setBackgroundResource(R.color.black_2);
|
||||
Helper.changeDrawableColor(context, R.drawable.ic_keyboard_arrow_right, R.color.dark_text);
|
||||
}
|
||||
Helper.changeDrawableColor(context, R.drawable.ic_keyboard_arrow_right, R.attr.iconColorMenu);
|
||||
Drawable next = ContextCompat.getDrawable(context, R.drawable.ic_keyboard_arrow_right);
|
||||
holder.search_title.setText(list.getTitle());
|
||||
assert next != null;
|
||||
|
|
|
@ -98,16 +98,7 @@ public class PlaylistAdapter extends BaseAdapter implements OnPlaylistActionInte
|
|||
SharedPreferences sharedpreferences = context.getSharedPreferences(Helper.APP_PREFS, Context.MODE_PRIVATE);
|
||||
int theme = sharedpreferences.getInt(Helper.SET_THEME, Helper.THEME_DARK);
|
||||
|
||||
if (theme == Helper.THEME_LIGHT) {
|
||||
holder.search_container.setBackgroundResource(R.color.mastodonC3__);
|
||||
Helper.changeDrawableColor(context, R.drawable.ic_keyboard_arrow_right, R.color.black);
|
||||
} else if (theme == Helper.THEME_DARK) {
|
||||
holder.search_container.setBackgroundResource(R.color.mastodonC1_);
|
||||
Helper.changeDrawableColor(context, R.drawable.ic_keyboard_arrow_right, R.color.dark_text);
|
||||
} else if (theme == Helper.THEME_BLACK) {
|
||||
holder.search_container.setBackgroundResource(R.color.black_2);
|
||||
Helper.changeDrawableColor(context, R.drawable.ic_keyboard_arrow_right, R.color.dark_text);
|
||||
}
|
||||
Helper.changeDrawableColor(context, R.drawable.ic_keyboard_arrow_right, R.attr.iconColorMenu);
|
||||
Drawable next = ContextCompat.getDrawable(context, R.drawable.ic_keyboard_arrow_right);
|
||||
holder.search_title.setText(playlist.getDisplayName());
|
||||
assert next != null;
|
||||
|
|
|
@ -96,16 +96,7 @@ public class SearchTootsListAdapter extends BaseAdapter {
|
|||
}
|
||||
SharedPreferences sharedpreferences = context.getSharedPreferences(Helper.APP_PREFS, android.content.Context.MODE_PRIVATE);
|
||||
int theme = sharedpreferences.getInt(Helper.SET_THEME, Helper.THEME_DARK);
|
||||
if (theme == Helper.THEME_LIGHT) {
|
||||
holder.search_container.setBackgroundResource(R.color.mastodonC3__);
|
||||
Helper.changeDrawableColor(context, R.drawable.ic_keyboard_arrow_right, R.color.black);
|
||||
} else if (theme == Helper.THEME_DARK) {
|
||||
holder.search_container.setBackgroundResource(R.color.mastodonC1_);
|
||||
Helper.changeDrawableColor(context, R.drawable.ic_keyboard_arrow_right, R.color.dark_text);
|
||||
} else if (theme == Helper.THEME_BLACK) {
|
||||
holder.search_container.setBackgroundResource(R.color.black_2);
|
||||
Helper.changeDrawableColor(context, R.drawable.ic_keyboard_arrow_right, R.color.dark_text);
|
||||
}
|
||||
Helper.changeDrawableColor(context, R.drawable.ic_keyboard_arrow_right, R.attr.iconColorMenu);
|
||||
Drawable next = ContextCompat.getDrawable(context, R.drawable.ic_keyboard_arrow_right);
|
||||
holder.search_title.setText(search);
|
||||
final float scale = context.getResources().getDisplayMetrics().density;
|
||||
|
|
|
@ -14,7 +14,6 @@ package app.fedilab.android.fragments;
|
|||
* You should have received a copy of the GNU General Public License along with Fedilab; if not,
|
||||
* see <http://www.gnu.org/licenses>. */
|
||||
|
||||
import android.annotation.SuppressLint;
|
||||
import android.app.Activity;
|
||||
import android.content.Context;
|
||||
import android.content.DialogInterface;
|
||||
|
@ -43,6 +42,8 @@ import android.widget.ListView;
|
|||
import android.widget.RelativeLayout;
|
||||
import android.widget.Toast;
|
||||
|
||||
import org.jetbrains.annotations.NotNull;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
|
||||
|
@ -160,7 +161,7 @@ public class DisplayListsFragment extends Fragment implements OnListActionInterf
|
|||
|
||||
|
||||
@Override
|
||||
public void onAttach(Context context) {
|
||||
public void onAttach(@NotNull Context context) {
|
||||
super.onAttach(context);
|
||||
this.context = context;
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue