Removed suggestions
This commit is contained in:
parent
43cb27ae5f
commit
b46175e20b
28 changed files with 145 additions and 440 deletions
|
@ -164,6 +164,5 @@ dependencies {
|
||||||
implementation 'com.github.takahirom.downloadable.calligraphy:downloadable-calligraphy:0.1.3'
|
implementation 'com.github.takahirom.downloadable.calligraphy:downloadable-calligraphy:0.1.3'
|
||||||
implementation 'androidx.constraintlayout:constraintlayout:2.0.0-alpha2'
|
implementation 'androidx.constraintlayout:constraintlayout:2.0.0-alpha2'
|
||||||
implementation project(':appthemehelper')
|
implementation project(':appthemehelper')
|
||||||
implementation project(':library')
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -153,6 +153,6 @@ class ArtistImageLoader(private val context: Context, private val lastFMClient:
|
||||||
|
|
||||||
companion object {
|
companion object {
|
||||||
// we need these very low values to make sure our artist image loading calls doesn't block the image loading queue
|
// we need these very low values to make sure our artist image loading calls doesn't block the image loading queue
|
||||||
private const val TIMEOUT = 500
|
private const val TIMEOUT = 700
|
||||||
}
|
}
|
||||||
}
|
}
|
|
@ -12,33 +12,33 @@
|
||||||
* See the GNU General Public License for more details.
|
* See the GNU General Public License for more details.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package code.name.monkey.retromusic.util.schedulers;
|
package code.name.monkey.retromusic.lyrics;
|
||||||
|
|
||||||
import androidx.annotation.NonNull;
|
|
||||||
|
|
||||||
import io.reactivex.Scheduler;
|
|
||||||
import io.reactivex.schedulers.Schedulers;
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Created by hemanths on 12/08/17.
|
* Desc : 歌词实体
|
||||||
|
* Author : Lauzy
|
||||||
|
* Date : 2017/10/13
|
||||||
|
* Blog : http://www.jianshu.com/u/e76853f863a9
|
||||||
|
* Email : freedompaladin@gmail.com
|
||||||
*/
|
*/
|
||||||
|
public class Lrc {
|
||||||
|
private long time;
|
||||||
|
private String text;
|
||||||
|
|
||||||
public class ImmediateScheduler implements BaseSchedulerProvider {
|
public long getTime() {
|
||||||
@NonNull
|
return time;
|
||||||
@Override
|
|
||||||
public Scheduler computation() {
|
|
||||||
return Schedulers.trampoline();
|
|
||||||
}
|
}
|
||||||
|
|
||||||
@NonNull
|
public void setTime(long time) {
|
||||||
@Override
|
this.time = time;
|
||||||
public Scheduler io() {
|
|
||||||
return Schedulers.trampoline();
|
|
||||||
}
|
}
|
||||||
|
|
||||||
@NonNull
|
public String getText() {
|
||||||
@Override
|
return text;
|
||||||
public Scheduler ui() {
|
|
||||||
return Schedulers.trampoline();
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public void setText(String text) {
|
||||||
|
this.text = text;
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
|
@ -1,4 +1,18 @@
|
||||||
package com.lauzy.freedom.library;
|
/*
|
||||||
|
* Copyright (c) 2019 Hemanth Savarala.
|
||||||
|
*
|
||||||
|
* Licensed under the GNU General Public License v3
|
||||||
|
*
|
||||||
|
* This is free software: you can redistribute it and/or modify it under
|
||||||
|
* the terms of the GNU General Public License as published by
|
||||||
|
* the Free Software Foundation either version 3 of the License, or (at your option) any later version.
|
||||||
|
*
|
||||||
|
* This software is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY;
|
||||||
|
* without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
|
||||||
|
* See the GNU General Public License for more details.
|
||||||
|
*/
|
||||||
|
|
||||||
|
package code.name.monkey.retromusic.lyrics;
|
||||||
|
|
||||||
import android.content.Context;
|
import android.content.Context;
|
||||||
|
|
|
@ -1,4 +1,18 @@
|
||||||
package com.lauzy.freedom.library
|
/*
|
||||||
|
* Copyright (c) 2019 Hemanth Savarala.
|
||||||
|
*
|
||||||
|
* Licensed under the GNU General Public License v3
|
||||||
|
*
|
||||||
|
* This is free software: you can redistribute it and/or modify it under
|
||||||
|
* the terms of the GNU General Public License as published by
|
||||||
|
* the Free Software Foundation either version 3 of the License, or (at your option) any later version.
|
||||||
|
*
|
||||||
|
* This software is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY;
|
||||||
|
* without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
|
||||||
|
* See the GNU General Public License for more details.
|
||||||
|
*/
|
||||||
|
package code.name.monkey.retromusic.lyrics
|
||||||
|
|
||||||
|
|
||||||
import android.animation.ValueAnimator
|
import android.animation.ValueAnimator
|
||||||
import android.content.Context
|
import android.content.Context
|
||||||
|
@ -23,6 +37,7 @@ import androidx.annotation.ColorInt
|
||||||
import androidx.core.content.ContextCompat
|
import androidx.core.content.ContextCompat
|
||||||
import androidx.core.content.res.ResourcesCompat
|
import androidx.core.content.res.ResourcesCompat
|
||||||
import androidx.core.view.ViewCompat
|
import androidx.core.view.ViewCompat
|
||||||
|
import code.name.monkey.retromusic.R
|
||||||
import java.util.*
|
import java.util.*
|
||||||
|
|
||||||
/**
|
/**
|
|
@ -22,7 +22,6 @@ import code.name.monkey.retromusic.ui.adapter.HomeAdapter.Companion.GENRES
|
||||||
import code.name.monkey.retromusic.ui.adapter.HomeAdapter.Companion.PLAYLISTS
|
import code.name.monkey.retromusic.ui.adapter.HomeAdapter.Companion.PLAYLISTS
|
||||||
import code.name.monkey.retromusic.ui.adapter.HomeAdapter.Companion.RECENT_ALBUMS
|
import code.name.monkey.retromusic.ui.adapter.HomeAdapter.Companion.RECENT_ALBUMS
|
||||||
import code.name.monkey.retromusic.ui.adapter.HomeAdapter.Companion.RECENT_ARTISTS
|
import code.name.monkey.retromusic.ui.adapter.HomeAdapter.Companion.RECENT_ARTISTS
|
||||||
import code.name.monkey.retromusic.ui.adapter.HomeAdapter.Companion.SUGGESTIONS
|
|
||||||
import code.name.monkey.retromusic.ui.adapter.HomeAdapter.Companion.TOP_ALBUMS
|
import code.name.monkey.retromusic.ui.adapter.HomeAdapter.Companion.TOP_ALBUMS
|
||||||
import code.name.monkey.retromusic.ui.adapter.HomeAdapter.Companion.TOP_ARTISTS
|
import code.name.monkey.retromusic.ui.adapter.HomeAdapter.Companion.TOP_ARTISTS
|
||||||
import code.name.monkey.retromusic.util.PreferenceUtil
|
import code.name.monkey.retromusic.util.PreferenceUtil
|
||||||
|
@ -80,7 +79,7 @@ class HomePresenter(private val view: HomeContract.HomeView) : Presenter(), Home
|
||||||
disposable += repository.topAlbums
|
disposable += repository.topAlbums
|
||||||
.observeOn(AndroidSchedulers.mainThread())
|
.observeOn(AndroidSchedulers.mainThread())
|
||||||
.subscribe({
|
.subscribe({
|
||||||
if (it.isNotEmpty()) hashSet.add(Home(2, R.string.top_albums, 0, it, TOP_ALBUMS, R.drawable.ic_album_white_24dp))
|
if (it.isNotEmpty()) hashSet.add(Home(3, R.string.top_albums, 0, it, TOP_ALBUMS, R.drawable.ic_album_white_24dp))
|
||||||
view.showData(ArrayList(hashSet))
|
view.showData(ArrayList(hashSet))
|
||||||
}, {
|
}, {
|
||||||
view.showEmpty()
|
view.showEmpty()
|
||||||
|
@ -91,7 +90,7 @@ class HomePresenter(private val view: HomeContract.HomeView) : Presenter(), Home
|
||||||
disposable += repository.topArtists
|
disposable += repository.topArtists
|
||||||
.observeOn(AndroidSchedulers.mainThread())
|
.observeOn(AndroidSchedulers.mainThread())
|
||||||
.subscribe({
|
.subscribe({
|
||||||
if (it.isNotEmpty()) hashSet.add(Home(3, R.string.top_artists, 0, it, TOP_ARTISTS, R.drawable.ic_artist_white_24dp))
|
if (it.isNotEmpty()) hashSet.add(Home(2, R.string.top_artists, 0, it, TOP_ARTISTS, R.drawable.ic_artist_white_24dp))
|
||||||
view.showData(ArrayList(hashSet))
|
view.showData(ArrayList(hashSet))
|
||||||
}, {
|
}, {
|
||||||
view.showEmpty()
|
view.showEmpty()
|
||||||
|
|
|
@ -10,6 +10,8 @@ import android.widget.ArrayAdapter
|
||||||
import android.widget.SeekBar
|
import android.widget.SeekBar
|
||||||
import android.widget.TextView
|
import android.widget.TextView
|
||||||
import code.name.monkey.appthemehelper.ThemeStore
|
import code.name.monkey.appthemehelper.ThemeStore
|
||||||
|
import code.name.monkey.appthemehelper.util.ColorUtil
|
||||||
|
import code.name.monkey.appthemehelper.util.MaterialValueHelper
|
||||||
import code.name.monkey.appthemehelper.util.TintHelper
|
import code.name.monkey.appthemehelper.util.TintHelper
|
||||||
import code.name.monkey.appthemehelper.util.ToolbarContentTintHelper
|
import code.name.monkey.appthemehelper.util.ToolbarContentTintHelper
|
||||||
import code.name.monkey.retromusic.R
|
import code.name.monkey.retromusic.R
|
||||||
|
@ -24,17 +26,7 @@ import kotlinx.android.synthetic.main.activity_equalizer.*
|
||||||
|
|
||||||
class EqualizerActivity : AbsMusicServiceActivity(), AdapterView.OnItemSelectedListener {
|
class EqualizerActivity : AbsMusicServiceActivity(), AdapterView.OnItemSelectedListener {
|
||||||
|
|
||||||
|
private val seekBarChangeListener = object : SeekBar.OnSeekBarChangeListener {
|
||||||
/*private val mListener = { buttonView, isChecked ->
|
|
||||||
when (buttonView.getId()) {
|
|
||||||
R.id.equalizerSwitch -> {
|
|
||||||
EqualizerHelper.instance!!.equalizer.enabled = isChecked
|
|
||||||
TransitionManager.beginDelayedTransition(content)
|
|
||||||
content.visibility = if (isChecked) View.VISIBLE else View.GONE
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}*/
|
|
||||||
private val mSeekBarChangeListener = object : SeekBar.OnSeekBarChangeListener {
|
|
||||||
override fun onProgressChanged(seekBar: SeekBar, progress: Int, fromUser: Boolean) {
|
override fun onProgressChanged(seekBar: SeekBar, progress: Int, fromUser: Boolean) {
|
||||||
if (fromUser) {
|
if (fromUser) {
|
||||||
if (seekBar === bassBoostStrength) {
|
if (seekBar === bassBoostStrength) {
|
||||||
|
@ -58,14 +50,12 @@ class EqualizerActivity : AbsMusicServiceActivity(), AdapterView.OnItemSelectedL
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
private var presetsNamesAdapter: ArrayAdapter<String>? = null
|
||||||
private var mPresetsNamesAdapter: ArrayAdapter<String>? = null
|
|
||||||
|
|
||||||
override fun onCreate(savedInstanceState: Bundle?) {
|
override fun onCreate(savedInstanceState: Bundle?) {
|
||||||
super.onCreate(savedInstanceState)
|
super.onCreate(savedInstanceState)
|
||||||
setContentView(R.layout.activity_equalizer)
|
setContentView(R.layout.activity_equalizer)
|
||||||
|
|
||||||
|
|
||||||
setStatusbarColorAuto()
|
setStatusbarColorAuto()
|
||||||
setNavigationbarColorAuto()
|
setNavigationbarColorAuto()
|
||||||
setTaskDescriptionColorAuto()
|
setTaskDescriptionColorAuto()
|
||||||
|
@ -74,7 +64,10 @@ class EqualizerActivity : AbsMusicServiceActivity(), AdapterView.OnItemSelectedL
|
||||||
setupToolbar()
|
setupToolbar()
|
||||||
|
|
||||||
equalizerSwitch.isChecked = EqualizerHelper.instance!!.equalizer.enabled
|
equalizerSwitch.isChecked = EqualizerHelper.instance!!.equalizer.enabled
|
||||||
TintHelper.setTintAuto(equalizerSwitch, ThemeStore.accentColor(this), false)
|
equalizerSwitch.setBackgroundColor(ThemeStore.accentColor(this))
|
||||||
|
val widgetColor = MaterialValueHelper.getPrimaryTextColor(this, ColorUtil.isColorLight(ThemeStore.accentColor(this)))
|
||||||
|
equalizerSwitch.setTextColor(widgetColor)
|
||||||
|
TintHelper.setTintAuto(equalizerSwitch, widgetColor, false)
|
||||||
equalizerSwitch.setOnCheckedChangeListener { buttonView, isChecked ->
|
equalizerSwitch.setOnCheckedChangeListener { buttonView, isChecked ->
|
||||||
when (buttonView.id) {
|
when (buttonView.id) {
|
||||||
R.id.equalizerSwitch -> {
|
R.id.equalizerSwitch -> {
|
||||||
|
@ -85,17 +78,17 @@ class EqualizerActivity : AbsMusicServiceActivity(), AdapterView.OnItemSelectedL
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
mPresetsNamesAdapter = ArrayAdapter(this, android.R.layout.simple_list_item_1)
|
presetsNamesAdapter = ArrayAdapter(this, android.R.layout.simple_list_item_1)
|
||||||
presets.adapter = mPresetsNamesAdapter
|
presets.adapter = presetsNamesAdapter
|
||||||
presets.onItemSelectedListener = this
|
presets.onItemSelectedListener = this
|
||||||
|
|
||||||
bassBoostStrength.progress = EqualizerHelper.instance!!.bassBoostStrength
|
bassBoostStrength.progress = EqualizerHelper.instance!!.bassBoostStrength
|
||||||
ViewUtil.setProgressDrawable(bassBoostStrength, ThemeStore.accentColor(this))
|
ViewUtil.setProgressDrawable(bassBoostStrength, ThemeStore.accentColor(this))
|
||||||
bassBoostStrength.setOnSeekBarChangeListener(mSeekBarChangeListener)
|
bassBoostStrength.setOnSeekBarChangeListener(seekBarChangeListener)
|
||||||
|
|
||||||
virtualizerStrength.progress = EqualizerHelper.instance!!.virtualizerStrength
|
virtualizerStrength.progress = EqualizerHelper.instance!!.virtualizerStrength
|
||||||
ViewUtil.setProgressDrawable(virtualizerStrength, ThemeStore.accentColor(this))
|
ViewUtil.setProgressDrawable(virtualizerStrength, ThemeStore.accentColor(this))
|
||||||
virtualizerStrength.setOnSeekBarChangeListener(mSeekBarChangeListener)
|
virtualizerStrength.setOnSeekBarChangeListener(seekBarChangeListener)
|
||||||
|
|
||||||
setupUI()
|
setupUI()
|
||||||
addPresets()
|
addPresets()
|
||||||
|
@ -124,12 +117,12 @@ class EqualizerActivity : AbsMusicServiceActivity(), AdapterView.OnItemSelectedL
|
||||||
}
|
}
|
||||||
|
|
||||||
private fun addPresets() {
|
private fun addPresets() {
|
||||||
mPresetsNamesAdapter!!.clear()
|
presetsNamesAdapter!!.clear()
|
||||||
mPresetsNamesAdapter!!.add("Custom")
|
presetsNamesAdapter!!.add("Custom")
|
||||||
for (j in 0 until EqualizerHelper.instance!!.equalizer.numberOfPresets) {
|
for (j in 0 until EqualizerHelper.instance!!.equalizer.numberOfPresets) {
|
||||||
mPresetsNamesAdapter!!
|
presetsNamesAdapter!!
|
||||||
.add(EqualizerHelper.instance!!.equalizer.getPresetName(j.toShort()))
|
.add(EqualizerHelper.instance!!.equalizer.getPresetName(j.toShort()))
|
||||||
mPresetsNamesAdapter!!.notifyDataSetChanged()
|
presetsNamesAdapter!!.notifyDataSetChanged()
|
||||||
}
|
}
|
||||||
presets.setSelection(EqualizerHelper.instance!!.equalizer.currentPreset.toInt() + 1)
|
presets.setSelection(EqualizerHelper.instance!!.equalizer.currentPreset.toInt() + 1)
|
||||||
}
|
}
|
||||||
|
|
|
@ -22,6 +22,8 @@ import code.name.monkey.retromusic.App
|
||||||
import code.name.monkey.retromusic.R
|
import code.name.monkey.retromusic.R
|
||||||
import code.name.monkey.retromusic.helper.MusicPlayerRemote
|
import code.name.monkey.retromusic.helper.MusicPlayerRemote
|
||||||
import code.name.monkey.retromusic.helper.MusicProgressViewUpdateHelper
|
import code.name.monkey.retromusic.helper.MusicProgressViewUpdateHelper
|
||||||
|
import code.name.monkey.retromusic.lyrics.LrcHelper
|
||||||
|
import code.name.monkey.retromusic.lyrics.LrcView
|
||||||
import code.name.monkey.retromusic.model.Song
|
import code.name.monkey.retromusic.model.Song
|
||||||
import code.name.monkey.retromusic.model.lyrics.Lyrics
|
import code.name.monkey.retromusic.model.lyrics.Lyrics
|
||||||
import code.name.monkey.retromusic.ui.activities.base.AbsMusicServiceActivity
|
import code.name.monkey.retromusic.ui.activities.base.AbsMusicServiceActivity
|
||||||
|
@ -33,8 +35,6 @@ import code.name.monkey.retromusic.util.PreferenceUtil
|
||||||
import code.name.monkey.retromusic.util.RetroUtil
|
import code.name.monkey.retromusic.util.RetroUtil
|
||||||
import com.afollestad.materialdialogs.MaterialDialog
|
import com.afollestad.materialdialogs.MaterialDialog
|
||||||
import com.afollestad.materialdialogs.input.input
|
import com.afollestad.materialdialogs.input.input
|
||||||
import com.lauzy.freedom.library.LrcHelper
|
|
||||||
import com.lauzy.freedom.library.LrcView
|
|
||||||
import kotlinx.android.synthetic.main.activity_lyrics.*
|
import kotlinx.android.synthetic.main.activity_lyrics.*
|
||||||
import kotlinx.android.synthetic.main.fragment_lyrics.*
|
import kotlinx.android.synthetic.main.fragment_lyrics.*
|
||||||
import kotlinx.android.synthetic.main.fragment_synced.*
|
import kotlinx.android.synthetic.main.fragment_synced.*
|
||||||
|
|
|
@ -41,7 +41,6 @@ class HomeAdapter(private val activity: AppCompatActivity, private var homes: Li
|
||||||
override fun onCreateViewHolder(parent: ViewGroup, viewType: Int): RecyclerView.ViewHolder {
|
override fun onCreateViewHolder(parent: ViewGroup, viewType: Int): RecyclerView.ViewHolder {
|
||||||
val layout = LayoutInflater.from(activity).inflate(R.layout.section_recycler_view, parent, false)
|
val layout = LayoutInflater.from(activity).inflate(R.layout.section_recycler_view, parent, false)
|
||||||
return when (viewType) {
|
return when (viewType) {
|
||||||
SUGGESTIONS -> SuggestionViewHolder(LayoutInflater.from(activity).inflate(R.layout.section_item_collage, parent, false))
|
|
||||||
RECENT_ARTISTS, TOP_ARTISTS -> ArtistViewHolder(layout)
|
RECENT_ARTISTS, TOP_ARTISTS -> ArtistViewHolder(layout)
|
||||||
GENRES -> GenreViewHolder(layout)
|
GENRES -> GenreViewHolder(layout)
|
||||||
PLAYLISTS -> PlaylistViewHolder(layout)
|
PLAYLISTS -> PlaylistViewHolder(layout)
|
||||||
|
@ -54,10 +53,7 @@ class HomeAdapter(private val activity: AppCompatActivity, private var homes: Li
|
||||||
override fun onBindViewHolder(holder: RecyclerView.ViewHolder, position: Int) {
|
override fun onBindViewHolder(holder: RecyclerView.ViewHolder, position: Int) {
|
||||||
val home = homes[position]
|
val home = homes[position]
|
||||||
when (getItemViewType(position)) {
|
when (getItemViewType(position)) {
|
||||||
SUGGESTIONS -> {
|
|
||||||
val viewHolder = holder as SuggestionViewHolder
|
|
||||||
viewHolder.bindView(home)
|
|
||||||
}
|
|
||||||
RECENT_ALBUMS, TOP_ALBUMS -> {
|
RECENT_ALBUMS, TOP_ALBUMS -> {
|
||||||
val viewHolder = holder as AlbumViewHolder
|
val viewHolder = holder as AlbumViewHolder
|
||||||
viewHolder.bindView(home)
|
viewHolder.bindView(home)
|
||||||
|
@ -88,17 +84,16 @@ class HomeAdapter(private val activity: AppCompatActivity, private var homes: Li
|
||||||
|
|
||||||
companion object {
|
companion object {
|
||||||
|
|
||||||
@IntDef(SUGGESTIONS, RECENT_ALBUMS, TOP_ALBUMS, RECENT_ARTISTS, TOP_ARTISTS, GENRES, PLAYLISTS)
|
@IntDef(RECENT_ALBUMS, TOP_ALBUMS, RECENT_ARTISTS, TOP_ARTISTS, GENRES, PLAYLISTS)
|
||||||
@Retention(AnnotationRetention.SOURCE)
|
@Retention(AnnotationRetention.SOURCE)
|
||||||
annotation class HomeSection
|
annotation class HomeSection
|
||||||
|
|
||||||
const val SUGGESTIONS = 0
|
const val RECENT_ALBUMS = 0
|
||||||
const val RECENT_ALBUMS = 1
|
const val TOP_ALBUMS = 1
|
||||||
const val TOP_ALBUMS = 2
|
const val RECENT_ARTISTS = 2
|
||||||
const val RECENT_ARTISTS = 3
|
const val TOP_ARTISTS = 3
|
||||||
const val TOP_ARTISTS = 4
|
const val GENRES = 4
|
||||||
const val GENRES = 5
|
const val PLAYLISTS = 5
|
||||||
const val PLAYLISTS = 6
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -1,145 +0,0 @@
|
||||||
/*
|
|
||||||
* Copyright (c) 2019 Hemanth Savarala.
|
|
||||||
*
|
|
||||||
* Licensed under the GNU General Public License v3
|
|
||||||
*
|
|
||||||
* This is free software: you can redistribute it and/or modify it under
|
|
||||||
* the terms of the GNU General Public License as published by
|
|
||||||
* the Free Software Foundation either version 3 of the License, or (at your option) any later version.
|
|
||||||
*
|
|
||||||
* This software is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY;
|
|
||||||
* without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
|
|
||||||
* See the GNU General Public License for more details.
|
|
||||||
*/
|
|
||||||
|
|
||||||
package code.name.monkey.retromusic.util.color;
|
|
||||||
|
|
||||||
import android.content.Context;
|
|
||||||
import android.content.res.Resources;
|
|
||||||
import android.graphics.Bitmap;
|
|
||||||
import android.graphics.Color;
|
|
||||||
import android.graphics.drawable.AnimationDrawable;
|
|
||||||
import android.graphics.drawable.BitmapDrawable;
|
|
||||||
import android.graphics.drawable.Drawable;
|
|
||||||
import android.graphics.drawable.VectorDrawable;
|
|
||||||
import android.util.Log;
|
|
||||||
import android.util.Pair;
|
|
||||||
|
|
||||||
import java.util.WeakHashMap;
|
|
||||||
|
|
||||||
import code.name.monkey.retromusic.util.ImageUtil;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Helper class to process legacy (Holo) notifications to make them look like quantum
|
|
||||||
* notifications.
|
|
||||||
*
|
|
||||||
* @hide
|
|
||||||
*/
|
|
||||||
public class NotificationColorUtil {
|
|
||||||
|
|
||||||
private static final String TAG = "NotificationColorUtil";
|
|
||||||
private static final Object sLock = new Object();
|
|
||||||
private static NotificationColorUtil sInstance;
|
|
||||||
|
|
||||||
private final WeakHashMap<Bitmap, Pair<Boolean, Integer>> mGrayscaleBitmapCache =
|
|
||||||
new WeakHashMap<Bitmap, Pair<Boolean, Integer>>();
|
|
||||||
|
|
||||||
public static NotificationColorUtil getInstance() {
|
|
||||||
synchronized (sLock) {
|
|
||||||
if (sInstance == null) {
|
|
||||||
sInstance = new NotificationColorUtil();
|
|
||||||
}
|
|
||||||
return sInstance;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Checks whether a bitmap is grayscale. Grayscale here means "very close to a perfect gray".
|
|
||||||
*
|
|
||||||
* @param bitmap The bitmap to test.
|
|
||||||
* @return Whether the bitmap is grayscale.
|
|
||||||
*/
|
|
||||||
public boolean isGrayscale(Bitmap bitmap) {
|
|
||||||
synchronized (sLock) {
|
|
||||||
Pair<Boolean, Integer> cached = mGrayscaleBitmapCache.get(bitmap);
|
|
||||||
if (cached != null) {
|
|
||||||
if (cached.second == bitmap.getGenerationId()) {
|
|
||||||
return cached.first;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
boolean result;
|
|
||||||
int generationId;
|
|
||||||
|
|
||||||
result = ImageUtil.isGrayscale(bitmap);
|
|
||||||
// generationId and the check whether the Bitmap is grayscale can't be read atomically
|
|
||||||
// here. However, since the thread is in the process of posting the notification, we can
|
|
||||||
// assume that it doesn't modify the bitmap while we are checking the pixels.
|
|
||||||
generationId = bitmap.getGenerationId();
|
|
||||||
|
|
||||||
synchronized (sLock) {
|
|
||||||
mGrayscaleBitmapCache.put(bitmap, Pair.create(result, generationId));
|
|
||||||
}
|
|
||||||
return result;
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Checks whether a drawable is grayscale. Grayscale here means "very close to a perfect gray".
|
|
||||||
*
|
|
||||||
* @param d The drawable to test.
|
|
||||||
* @return Whether the drawable is grayscale.
|
|
||||||
*/
|
|
||||||
public boolean isGrayscale(Drawable d) {
|
|
||||||
if (d == null) {
|
|
||||||
return false;
|
|
||||||
} else if (d instanceof BitmapDrawable) {
|
|
||||||
BitmapDrawable bd = (BitmapDrawable) d;
|
|
||||||
return bd.getBitmap() != null && isGrayscale(bd.getBitmap());
|
|
||||||
} else if (d instanceof AnimationDrawable) {
|
|
||||||
AnimationDrawable ad = (AnimationDrawable) d;
|
|
||||||
int count = ad.getNumberOfFrames();
|
|
||||||
return count > 0 && isGrayscale(ad.getFrame(0));
|
|
||||||
} else if (d instanceof VectorDrawable) {
|
|
||||||
// We just assume you're doing the right thing if using vectors
|
|
||||||
return true;
|
|
||||||
} else {
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Checks whether a drawable with a resoure id is grayscale. Grayscale here means "very close to a
|
|
||||||
* perfect gray".
|
|
||||||
*
|
|
||||||
* @param context The context to load the drawable from.
|
|
||||||
* @return Whether the drawable is grayscale.
|
|
||||||
*/
|
|
||||||
public boolean isGrayscale(Context context, int drawableResId) {
|
|
||||||
if (drawableResId != 0) {
|
|
||||||
try {
|
|
||||||
return isGrayscale(context.getDrawable(drawableResId));
|
|
||||||
} catch (Resources.NotFoundException ex) {
|
|
||||||
Log.e(TAG, "Drawable not found: " + drawableResId);
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
} else {
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Inverts all the grayscale colors set by {@link android.text.style.TextAppearanceSpan}s on the
|
|
||||||
* text.
|
|
||||||
*
|
|
||||||
* @param charSequence The text to process.
|
|
||||||
* @return The color inverted text.
|
|
||||||
*/
|
|
||||||
|
|
||||||
|
|
||||||
private int processColor(int color) {
|
|
||||||
return Color.argb(Color.alpha(color),
|
|
||||||
255 - Color.red(color),
|
|
||||||
255 - Color.green(color),
|
|
||||||
255 - Color.blue(color));
|
|
||||||
}
|
|
||||||
}
|
|
Before Width: | Height: | Size: 707 B After Width: | Height: | Size: 707 B |
|
@ -8,52 +8,38 @@
|
||||||
<com.google.android.material.appbar.AppBarLayout
|
<com.google.android.material.appbar.AppBarLayout
|
||||||
android:id="@+id/appBarLayout"
|
android:id="@+id/appBarLayout"
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content">
|
||||||
android:elevation="0dp"
|
|
||||||
app:elevation="0dp">
|
|
||||||
|
|
||||||
<com.google.android.material.appbar.CollapsingToolbarLayout xmlns:tools="http://schemas.android.com/tools"
|
<androidx.appcompat.widget.Toolbar
|
||||||
|
android:id="@+id/toolbar"
|
||||||
|
style="@style/Toolbar"
|
||||||
|
app:layout_collapseMode="pin"
|
||||||
|
app:title=""
|
||||||
|
tools:ignore="UnusedAttribute">
|
||||||
|
|
||||||
|
<code.name.monkey.appthemehelper.common.views.ATEPrimaryTextView
|
||||||
|
android:id="@+id/bannerTitle"
|
||||||
|
style="@style/BigTitleTextAppearanceToolbar"
|
||||||
|
android:text="@string/equalizer" />
|
||||||
|
|
||||||
|
</androidx.appcompat.widget.Toolbar>
|
||||||
|
|
||||||
|
<androidx.appcompat.widget.SwitchCompat
|
||||||
|
android:id="@+id/equalizerSwitch"
|
||||||
|
style="@style/TextAppearance.MaterialComponents.Subtitle1"
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
app:layout_scrollFlags="scroll|enterAlwaysCollapsed"
|
android:background="@color/md_red_A400"
|
||||||
app:titleEnabled="false">
|
android:fontFamily="@font/circular_std_medium"
|
||||||
|
android:padding="16dp"
|
||||||
<androidx.appcompat.widget.Toolbar
|
android:text="@string/on" />
|
||||||
android:id="@+id/toolbar"
|
|
||||||
style="@style/Toolbar"
|
|
||||||
app:layout_collapseMode="pin"
|
|
||||||
app:title=""
|
|
||||||
tools:ignore="UnusedAttribute">
|
|
||||||
|
|
||||||
|
|
||||||
<code.name.monkey.appthemehelper.common.views.ATEPrimaryTextView
|
|
||||||
android:id="@+id/bannerTitle"
|
|
||||||
android:textStyle="bold"
|
|
||||||
android:layout_width="wrap_content"
|
|
||||||
android:layout_height="wrap_content"
|
|
||||||
android:layout_gravity="center"
|
|
||||||
android:gravity="center"
|
|
||||||
android:text="@string/equalizer"
|
|
||||||
style="@style/BigTitleTextAppearanceToolbar"
|
|
||||||
tools:ignore="MissingPrefix" />
|
|
||||||
|
|
||||||
<androidx.appcompat.widget.SwitchCompat
|
|
||||||
android:id="@+id/equalizerSwitch"
|
|
||||||
android:layout_width="wrap_content"
|
|
||||||
android:layout_height="wrap_content"
|
|
||||||
android:layout_gravity="end"
|
|
||||||
android:layout_marginEnd="16dp" />
|
|
||||||
|
|
||||||
</androidx.appcompat.widget.Toolbar>
|
|
||||||
</com.google.android.material.appbar.CollapsingToolbarLayout>
|
|
||||||
</com.google.android.material.appbar.AppBarLayout>
|
</com.google.android.material.appbar.AppBarLayout>
|
||||||
|
|
||||||
|
|
||||||
<androidx.core.widget.NestedScrollView
|
<androidx.core.widget.NestedScrollView
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
app:layout_behavior="@string/appbar_scrolling_view_behavior">
|
app:layout_behavior="com.google.android.material.appbar.AppBarLayout$ScrollingViewBehavior">
|
||||||
|
|
||||||
<LinearLayout
|
<LinearLayout
|
||||||
android:id="@+id/content"
|
android:id="@+id/content"
|
||||||
|
@ -61,6 +47,7 @@
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:orientation="vertical">
|
android:orientation="vertical">
|
||||||
|
|
||||||
|
|
||||||
<LinearLayout
|
<LinearLayout
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
|
@ -68,19 +55,19 @@
|
||||||
android:orientation="horizontal">
|
android:orientation="horizontal">
|
||||||
|
|
||||||
<TextView
|
<TextView
|
||||||
android:layout_width="wrap_content"
|
style="@style/TextAppearance.MaterialComponents.Subtitle2"
|
||||||
android:layout_height="wrap_content"
|
|
||||||
android:layout_weight="0"
|
|
||||||
android:padding="16dp"
|
|
||||||
android:text="Select preset"
|
|
||||||
android:textAppearance="@style/TextAppearance.AppCompat.Subhead" />
|
|
||||||
|
|
||||||
<Spinner
|
|
||||||
android:id="@+id/presets"
|
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:layout_weight="1"
|
android:layout_weight="1"
|
||||||
android:background="@android:color/transparent" />
|
android:padding="16dp"
|
||||||
|
android:text="@string/select_preset" />
|
||||||
|
|
||||||
|
<Spinner
|
||||||
|
android:id="@+id/presets"
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_weight="0" />
|
||||||
|
|
||||||
</LinearLayout>
|
</LinearLayout>
|
||||||
|
|
||||||
<LinearLayout
|
<LinearLayout
|
||||||
|
@ -91,12 +78,12 @@
|
||||||
|
|
||||||
<code.name.monkey.appthemehelper.common.views.ATEPrimaryTextView
|
<code.name.monkey.appthemehelper.common.views.ATEPrimaryTextView
|
||||||
android:id="@+id/bassBoost"
|
android:id="@+id/bassBoost"
|
||||||
|
style="@style/TextAppearance.MaterialComponents.Subtitle2"
|
||||||
android:layout_width="wrap_content"
|
android:layout_width="wrap_content"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:layout_weight="0"
|
android:layout_weight="0"
|
||||||
android:padding="16dp"
|
android:padding="16dp"
|
||||||
android:text="@string/bass_boost"
|
android:text="@string/bass_boost" />
|
||||||
android:textAppearance="@style/TextAppearance.AppCompat.Subhead" />
|
|
||||||
|
|
||||||
<SeekBar
|
<SeekBar
|
||||||
android:id="@+id/bassBoostStrength"
|
android:id="@+id/bassBoostStrength"
|
||||||
|
@ -120,12 +107,12 @@
|
||||||
|
|
||||||
<code.name.monkey.appthemehelper.common.views.ATEPrimaryTextView
|
<code.name.monkey.appthemehelper.common.views.ATEPrimaryTextView
|
||||||
android:id="@+id/virtualizer"
|
android:id="@+id/virtualizer"
|
||||||
|
style="@style/TextAppearance.MaterialComponents.Subtitle2"
|
||||||
android:layout_width="wrap_content"
|
android:layout_width="wrap_content"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:layout_weight="0"
|
android:layout_weight="0"
|
||||||
android:padding="16dp"
|
android:padding="16dp"
|
||||||
android:text="@string/virtualizer"
|
android:text="@string/virtualizer" />
|
||||||
android:textAppearance="@style/TextAppearance.AppCompat.Subhead" />
|
|
||||||
|
|
||||||
<SeekBar
|
<SeekBar
|
||||||
android:id="@+id/virtualizerStrength"
|
android:id="@+id/virtualizerStrength"
|
||||||
|
|
|
@ -31,8 +31,6 @@
|
||||||
</LinearLayout>
|
</LinearLayout>
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<code.name.monkey.retromusic.views.WidthFitSquareLayout
|
<code.name.monkey.retromusic.views.WidthFitSquareLayout
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
|
@ -55,6 +53,7 @@
|
||||||
android:scaleType="centerCrop" />
|
android:scaleType="centerCrop" />
|
||||||
</com.google.android.material.card.MaterialCardView>
|
</com.google.android.material.card.MaterialCardView>
|
||||||
</code.name.monkey.retromusic.views.WidthFitSquareLayout>
|
</code.name.monkey.retromusic.views.WidthFitSquareLayout>
|
||||||
|
|
||||||
<TextView
|
<TextView
|
||||||
android:id="@+id/slide"
|
android:id="@+id/slide"
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
|
|
|
@ -6,7 +6,7 @@
|
||||||
android:orientation="vertical"
|
android:orientation="vertical"
|
||||||
app:layout_behavior="@string/appbar_scrolling_view_behavior">
|
app:layout_behavior="@string/appbar_scrolling_view_behavior">
|
||||||
|
|
||||||
<com.lauzy.freedom.library.LrcView
|
<code.name.monkey.retromusic.lyrics.LrcView
|
||||||
android:id="@+id/lyricsView"
|
android:id="@+id/lyricsView"
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="match_parent" />
|
android:layout_height="match_parent" />
|
||||||
|
|
|
@ -43,4 +43,27 @@
|
||||||
<attr name="optionTitle" format="reference" />
|
<attr name="optionTitle" format="reference" />
|
||||||
<attr name="optionIcon" format="reference" />
|
<attr name="optionIcon" format="reference" />
|
||||||
</declare-styleable>
|
</declare-styleable>
|
||||||
|
|
||||||
|
|
||||||
|
<declare-styleable name="LrcView">
|
||||||
|
<attr name="lrcTextSize" format="dimension"/>
|
||||||
|
<attr name="lrcLineSpaceSize" format="dimension"/>
|
||||||
|
<attr name="lrcNormalTextColor" format="reference|color"/>
|
||||||
|
<attr name="lrcCurrentTextColor" format="reference|color"/>
|
||||||
|
<attr name="lrcTouchDelay" format="integer"/>
|
||||||
|
<attr name="noLrcTextSize" format="dimension"/>
|
||||||
|
<attr name="noLrcTextColor" format="reference|color"/>
|
||||||
|
<attr name="indicatorLineHeight" format="dimension"/>
|
||||||
|
<attr name="indicatorTextSize" format="dimension"/>
|
||||||
|
<attr name="indicatorTextColor" format="reference|color"/>
|
||||||
|
<attr name="currentIndicateLrcColor" format="reference|color"/>
|
||||||
|
<attr name="indicatorTouchDelay" format="integer"/>
|
||||||
|
<attr name="indicatorLineColor" format="reference|color"/>
|
||||||
|
<attr name="indicatorStartEndMargin" format="dimension"/>
|
||||||
|
<attr name="iconLineGap" format="dimension"/>
|
||||||
|
<attr name="playIconWidth" format="dimension"/>
|
||||||
|
<attr name="playIconHeight" format="dimension"/>
|
||||||
|
<attr name="playIcon" format="reference"/>
|
||||||
|
</declare-styleable>
|
||||||
|
|
||||||
</resources>
|
</resources>
|
|
@ -614,5 +614,7 @@
|
||||||
<string name="dialog_message_set_ringtone">Allow Retro Music to modify audio settings</string>
|
<string name="dialog_message_set_ringtone">Allow Retro Music to modify audio settings</string>
|
||||||
<string name="about_settings_summary">Team, social links</string>
|
<string name="about_settings_summary">Team, social links</string>
|
||||||
<string name="other_settings_summary">Advanced testing features</string>
|
<string name="other_settings_summary">Advanced testing features</string>
|
||||||
|
<string name="on">On</string>
|
||||||
|
<string name="select_preset">Select preset</string>
|
||||||
|
|
||||||
</resources>
|
</resources>
|
||||||
|
|
1
library/.gitignore
vendored
1
library/.gitignore
vendored
|
@ -1 +0,0 @@
|
||||||
/build
|
|
|
@ -1,41 +0,0 @@
|
||||||
apply plugin: 'com.android.library'
|
|
||||||
apply plugin: 'kotlin-android-extensions'
|
|
||||||
apply plugin: 'kotlin-android'
|
|
||||||
|
|
||||||
android {
|
|
||||||
compileSdkVersion 28
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
defaultConfig {
|
|
||||||
minSdkVersion 21
|
|
||||||
targetSdkVersion 27
|
|
||||||
versionCode 1
|
|
||||||
versionName "1.0"
|
|
||||||
|
|
||||||
testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner"
|
|
||||||
|
|
||||||
}
|
|
||||||
|
|
||||||
buildTypes {
|
|
||||||
release {
|
|
||||||
minifyEnabled false
|
|
||||||
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
}
|
|
||||||
|
|
||||||
dependencies {
|
|
||||||
implementation fileTree(dir: 'libs', include: ['*.jar'])
|
|
||||||
|
|
||||||
implementation 'com.android.support:appcompat-v7:28.0.0'
|
|
||||||
testImplementation 'junit:junit:4.12'
|
|
||||||
androidTestImplementation 'com.android.support.test:runner:1.0.1'
|
|
||||||
androidTestImplementation 'com.android.support.test.espresso:espresso-core:3.0.1'
|
|
||||||
implementation 'androidx.core:core-ktx:1.1.0-alpha05'
|
|
||||||
implementation "org.jetbrains.kotlin:kotlin-stdlib-jdk7:$kotlin_version"
|
|
||||||
}
|
|
||||||
repositories {
|
|
||||||
mavenCentral()
|
|
||||||
}
|
|
21
library/proguard-rules.pro
vendored
21
library/proguard-rules.pro
vendored
|
@ -1,21 +0,0 @@
|
||||||
# Add project specific ProGuard rules here.
|
|
||||||
# You can control the set of applied configuration files using the
|
|
||||||
# proguardFiles setting in build.gradle.
|
|
||||||
#
|
|
||||||
# For more details, see
|
|
||||||
# http://developer.android.com/guide/developing/tools/proguard.html
|
|
||||||
|
|
||||||
# If your project uses WebView with JS, uncomment the following
|
|
||||||
# and specify the fully qualified class name to the JavaScript interface
|
|
||||||
# class:
|
|
||||||
#-keepclassmembers class fqcn.of.javascript.interface.for.webview {
|
|
||||||
# public *;
|
|
||||||
#}
|
|
||||||
|
|
||||||
# Uncomment this to preserve the line number information for
|
|
||||||
# debugging stack traces.
|
|
||||||
#-keepattributes SourceFile,LineNumberTable
|
|
||||||
|
|
||||||
# If you keep the line number information, uncomment this to
|
|
||||||
# hide the original source file name.
|
|
||||||
#-renamesourcefileattribute SourceFile
|
|
|
@ -1,26 +0,0 @@
|
||||||
package com.lauzy.freedom.library;
|
|
||||||
|
|
||||||
import android.content.Context;
|
|
||||||
import android.support.test.InstrumentationRegistry;
|
|
||||||
import android.support.test.runner.AndroidJUnit4;
|
|
||||||
|
|
||||||
import org.junit.Test;
|
|
||||||
import org.junit.runner.RunWith;
|
|
||||||
|
|
||||||
import static org.junit.Assert.*;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Instrumented test, which will execute on an Android device.
|
|
||||||
*
|
|
||||||
* @see <a href="http://d.android.com/tools/testing">Testing documentation</a>
|
|
||||||
*/
|
|
||||||
@RunWith(AndroidJUnit4.class)
|
|
||||||
public class ExampleInstrumentedTest {
|
|
||||||
@Test
|
|
||||||
public void useAppContext() {
|
|
||||||
// Context of the app under test.
|
|
||||||
Context appContext = InstrumentationRegistry.getTargetContext();
|
|
||||||
|
|
||||||
assertEquals("com.lauzy.freedom.library.test", appContext.getPackageName());
|
|
||||||
}
|
|
||||||
}
|
|
|
@ -1,2 +0,0 @@
|
||||||
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
|
|
||||||
package="com.lauzy.freedom.library"/>
|
|
|
@ -1,30 +0,0 @@
|
||||||
package com.lauzy.freedom.library;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Desc : 歌词实体
|
|
||||||
* Author : Lauzy
|
|
||||||
* Date : 2017/10/13
|
|
||||||
* Blog : http://www.jianshu.com/u/e76853f863a9
|
|
||||||
* Email : freedompaladin@gmail.com
|
|
||||||
*/
|
|
||||||
public class Lrc {
|
|
||||||
private long time;
|
|
||||||
private String text;
|
|
||||||
|
|
||||||
public void setTime(long time) {
|
|
||||||
this.time = time;
|
|
||||||
}
|
|
||||||
|
|
||||||
public void setText(String text) {
|
|
||||||
this.text = text;
|
|
||||||
}
|
|
||||||
|
|
||||||
public long getTime() {
|
|
||||||
return time;
|
|
||||||
}
|
|
||||||
|
|
||||||
public String getText() {
|
|
||||||
return text;
|
|
||||||
}
|
|
||||||
|
|
||||||
}
|
|
|
@ -1,11 +0,0 @@
|
||||||
<?xml version="1.0" encoding="utf-8"?>
|
|
||||||
<font-family xmlns:android="http://schemas.android.com/apk/res/android">
|
|
||||||
<font
|
|
||||||
android:font="@font/circular_std_book"
|
|
||||||
android:fontStyle="normal"
|
|
||||||
android:fontWeight="400" />
|
|
||||||
<font
|
|
||||||
android:font="@font/circular_std_black"
|
|
||||||
android:fontWeight="900" />
|
|
||||||
|
|
||||||
</font-family>
|
|
Binary file not shown.
Binary file not shown.
|
@ -1,24 +0,0 @@
|
||||||
<?xml version="1.0" encoding="utf-8"?>
|
|
||||||
<resources>
|
|
||||||
<declare-styleable name="LrcView">
|
|
||||||
<attr name="lrcTextSize" format="dimension"/>
|
|
||||||
<attr name="lrcLineSpaceSize" format="dimension"/>
|
|
||||||
<attr name="lrcNormalTextColor" format="reference|color"/>
|
|
||||||
<attr name="lrcCurrentTextColor" format="reference|color"/>
|
|
||||||
<attr name="lrcTouchDelay" format="integer"/>
|
|
||||||
<attr name="noLrcTextSize" format="dimension"/>
|
|
||||||
<attr name="noLrcTextColor" format="reference|color"/>
|
|
||||||
<attr name="indicatorLineHeight" format="dimension"/>
|
|
||||||
<attr name="indicatorTextSize" format="dimension"/>
|
|
||||||
<attr name="indicatorTextColor" format="reference|color"/>
|
|
||||||
<attr name="currentIndicateLrcColor" format="reference|color"/>
|
|
||||||
<attr name="indicatorTouchDelay" format="integer"/>
|
|
||||||
<attr name="indicatorLineColor" format="reference|color"/>
|
|
||||||
<attr name="indicatorStartEndMargin" format="dimension"/>
|
|
||||||
<attr name="iconLineGap" format="dimension"/>
|
|
||||||
<attr name="playIconWidth" format="dimension"/>
|
|
||||||
<attr name="playIconHeight" format="dimension"/>
|
|
||||||
<attr name="playIcon" format="reference"/>
|
|
||||||
</declare-styleable>
|
|
||||||
|
|
||||||
</resources>
|
|
|
@ -1,3 +0,0 @@
|
||||||
<resources>
|
|
||||||
<string name="app_name">library</string>
|
|
||||||
</resources>
|
|
|
@ -1,17 +0,0 @@
|
||||||
package com.lauzy.freedom.library;
|
|
||||||
|
|
||||||
import org.junit.Test;
|
|
||||||
|
|
||||||
import static org.junit.Assert.*;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Example local unit test, which will execute on the development machine (host).
|
|
||||||
*
|
|
||||||
* @see <a href="http://d.android.com/tools/testing">Testing documentation</a>
|
|
||||||
*/
|
|
||||||
public class ExampleUnitTest {
|
|
||||||
@Test
|
|
||||||
public void addition_isCorrect() {
|
|
||||||
assertEquals(4, 2 + 2);
|
|
||||||
}
|
|
||||||
}
|
|
Loading…
Reference in a new issue