diff --git a/app/build.gradle b/app/build.gradle index 266f7fadb..536d304c8 100644 --- a/app/build.gradle +++ b/app/build.gradle @@ -32,10 +32,10 @@ android { dependencies { testCompile 'junit:junit:4.12' - compile 'com.android.support:appcompat-v7:25.1.0' - compile 'com.android.support:support-v4:25.1.0' - compile 'com.android.support:design:25.1.0' - compile 'com.android.support:recyclerview-v7:25.1.0' + compile 'com.android.support:appcompat-v7:25.0.0' + compile 'com.android.support:support-v4:25.0.0' + compile 'com.android.support:design:25.0.0' + compile 'com.android.support:recyclerview-v7:25.0.0' compile 'org.jsoup:jsoup:1.8.3' compile 'org.mozilla:rhino:1.7.7' compile 'info.guardianproject.netcipher:netcipher:1.2' diff --git a/app/src/main/java/org/schabi/newpipe/App.java b/app/src/main/java/org/schabi/newpipe/App.java index f9b95c457..cb4dce3ea 100644 --- a/app/src/main/java/org/schabi/newpipe/App.java +++ b/app/src/main/java/org/schabi/newpipe/App.java @@ -48,6 +48,7 @@ public class App extends Application { @Override public void onCreate() { super.onCreate(); + // init crashreport try { final ACRAConfiguration acraConfig = new ConfigurationBuilder(this) diff --git a/app/src/main/java/org/schabi/newpipe/ChannelActivity.java b/app/src/main/java/org/schabi/newpipe/ChannelActivity.java index 83936475c..71e02c197 100644 --- a/app/src/main/java/org/schabi/newpipe/ChannelActivity.java +++ b/app/src/main/java/org/schabi/newpipe/ChannelActivity.java @@ -4,6 +4,7 @@ import android.content.Intent; import android.net.Uri; import android.os.Bundle; import android.os.Handler; +import android.preference.PreferenceManager; import android.support.design.widget.CollapsingToolbarLayout; import android.support.design.widget.FloatingActionButton; import android.support.v7.app.AppCompatActivity; @@ -31,6 +32,7 @@ import org.schabi.newpipe.info_list.InfoListAdapter; import org.schabi.newpipe.report.ErrorActivity; import java.io.IOException; +import java.util.Objects; /** * Copyright (C) Christian Schabesberger 2016 @@ -71,6 +73,10 @@ public class ChannelActivity extends AppCompatActivity { @Override protected void onCreate(Bundle savedInstanceState) { + if (Objects.equals(PreferenceManager.getDefaultSharedPreferences(this) + .getString("theme", getResources().getString(R.string.light_theme_title)), getResources().getString(R.string.dark_theme_title))) { + setTheme(R.style.DarkTheme_NoActionBar); + } super.onCreate(savedInstanceState); setContentView(R.layout.activity_channel); Toolbar toolbar = (Toolbar) findViewById(R.id.toolbar); @@ -128,7 +134,7 @@ public class ChannelActivity extends AppCompatActivity { CollapsingToolbarLayout ctl = (CollapsingToolbarLayout) findViewById(R.id.channel_toolbar_layout); ProgressBar progressBar = (ProgressBar) findViewById(R.id.progressBar); ImageView channelBanner = (ImageView) findViewById(R.id.channel_banner_image); - FloatingActionButton feedButton = (FloatingActionButton) findViewById(R.id.channel_rss_fab); + final FloatingActionButton feedButton = (FloatingActionButton) findViewById(R.id.channel_rss_fab); ImageView avatarView = (ImageView) findViewById(R.id.channel_avatar_view); ImageView haloView = (ImageView) findViewById(R.id.channel_avatar_halo); diff --git a/app/src/main/java/org/schabi/newpipe/MainActivity.java b/app/src/main/java/org/schabi/newpipe/MainActivity.java index bfeb74287..9472d5903 100644 --- a/app/src/main/java/org/schabi/newpipe/MainActivity.java +++ b/app/src/main/java/org/schabi/newpipe/MainActivity.java @@ -1,7 +1,9 @@ package org.schabi.newpipe; +import android.app.Activity; import android.content.Intent; import android.media.AudioManager; +import android.preference.PreferenceManager; import android.support.v4.app.Fragment; import android.support.v4.app.NavUtils; import android.support.v7.app.AppCompatActivity; @@ -9,9 +11,14 @@ import android.os.Bundle; import android.view.Menu; import android.view.MenuInflater; import android.view.MenuItem; +import android.widget.Toast; +import org.schabi.newpipe.settings.NewPipeSettings; import org.schabi.newpipe.settings.SettingsActivity; +import java.util.Objects; +import java.util.prefs.Preferences; + /** * Created by Christian Schabesberger on 02.08.16. * @@ -32,7 +39,7 @@ import org.schabi.newpipe.settings.SettingsActivity; * along with NewPipe. If not, see . */ -public class MainActivity extends AppCompatActivity { +public class MainActivity extends Themer { private Fragment mainFragment = null; @@ -40,7 +47,6 @@ public class MainActivity extends AppCompatActivity { protected void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.activity_main); - setVolumeControlStream(AudioManager.STREAM_MUSIC); mainFragment = getSupportFragmentManager() .findFragmentById(R.id.search_fragment); diff --git a/app/src/main/java/org/schabi/newpipe/Themer.java b/app/src/main/java/org/schabi/newpipe/Themer.java new file mode 100644 index 000000000..048837cec --- /dev/null +++ b/app/src/main/java/org/schabi/newpipe/Themer.java @@ -0,0 +1,21 @@ +package org.schabi.newpipe; + +import android.os.Bundle; +import android.preference.PreferenceManager; +import android.support.v7.app.AppCompatActivity; + +import java.util.Objects; + +import static org.schabi.newpipe.R.attr.theme; + +public class Themer extends AppCompatActivity { + + @Override + protected void onCreate(Bundle savedInstanceState) { + super.onCreate(savedInstanceState); + if (Objects.equals(PreferenceManager.getDefaultSharedPreferences(this) + .getString("theme", getResources().getString(R.string.light_theme_title)), getResources().getString(R.string.dark_theme_title))) { + setTheme(R.style.DarkTheme); + } + } +} \ No newline at end of file diff --git a/app/src/main/java/org/schabi/newpipe/detail/VideoItemDetailActivity.java b/app/src/main/java/org/schabi/newpipe/detail/VideoItemDetailActivity.java index 256547004..05895fef4 100644 --- a/app/src/main/java/org/schabi/newpipe/detail/VideoItemDetailActivity.java +++ b/app/src/main/java/org/schabi/newpipe/detail/VideoItemDetailActivity.java @@ -14,6 +14,7 @@ import android.widget.Toast; import org.schabi.newpipe.App; import org.schabi.newpipe.MainActivity; import org.schabi.newpipe.R; +import org.schabi.newpipe.Themer; import org.schabi.newpipe.extractor.NewPipe; import org.schabi.newpipe.extractor.StreamingService; @@ -39,7 +40,7 @@ import java.util.HashSet; * along with NewPipe. If not, see . */ -public class VideoItemDetailActivity extends AppCompatActivity { +public class VideoItemDetailActivity extends Themer { /** * Removes invisible separators (\p{Z}) and punctuation characters including diff --git a/app/src/main/java/org/schabi/newpipe/detail/VideoItemDetailFragment.java b/app/src/main/java/org/schabi/newpipe/detail/VideoItemDetailFragment.java index a93f37654..98620b15d 100644 --- a/app/src/main/java/org/schabi/newpipe/detail/VideoItemDetailFragment.java +++ b/app/src/main/java/org/schabi/newpipe/detail/VideoItemDetailFragment.java @@ -21,6 +21,7 @@ import android.util.Log; import android.view.LayoutInflater; import android.view.Menu; import android.view.MenuInflater; +import android.view.MenuItem; import android.view.MotionEvent; import android.view.View; import android.view.ViewGroup; @@ -30,7 +31,6 @@ import android.widget.LinearLayout; import android.widget.ProgressBar; import android.widget.RelativeLayout; import android.widget.TextView; -import android.view.MenuItem; import android.widget.Toast; import com.google.android.exoplayer.util.Util; @@ -39,26 +39,26 @@ import com.nostra13.universalimageloader.core.ImageLoader; import com.nostra13.universalimageloader.core.assist.FailReason; import com.nostra13.universalimageloader.core.listener.ImageLoadingListener; -import java.util.Vector; - import org.schabi.newpipe.ActivityCommunicator; import org.schabi.newpipe.ChannelActivity; -import org.schabi.newpipe.ReCaptchaActivity; -import org.schabi.newpipe.extractor.stream_info.StreamInfo; -import org.schabi.newpipe.extractor.stream_info.StreamPreviewInfo; -import org.schabi.newpipe.info_list.InfoItemBuilder; -import org.schabi.newpipe.report.ErrorActivity; import org.schabi.newpipe.ImageErrorLoadingListener; import org.schabi.newpipe.Localization; import org.schabi.newpipe.R; +import org.schabi.newpipe.ReCaptchaActivity; import org.schabi.newpipe.download.DownloadDialog; -import org.schabi.newpipe.extractor.stream_info.AudioStream; import org.schabi.newpipe.extractor.MediaFormat; import org.schabi.newpipe.extractor.NewPipe; +import org.schabi.newpipe.extractor.stream_info.AudioStream; +import org.schabi.newpipe.extractor.stream_info.StreamInfo; +import org.schabi.newpipe.extractor.stream_info.StreamPreviewInfo; import org.schabi.newpipe.extractor.stream_info.VideoStream; +import org.schabi.newpipe.info_list.InfoItemBuilder; import org.schabi.newpipe.player.BackgroundPlayer; -import org.schabi.newpipe.player.PlayVideoActivity; import org.schabi.newpipe.player.ExoPlayerActivity; +import org.schabi.newpipe.player.PlayVideoActivity; +import org.schabi.newpipe.report.ErrorActivity; + +import java.util.Vector; import static android.app.Activity.RESULT_OK; import static org.schabi.newpipe.ReCaptchaActivity.RECAPTCHA_REQUEST; @@ -650,7 +650,6 @@ public class VideoItemDetailFragment extends Fragment { public void onStart() { super.onStart(); Activity a = getActivity(); - infoItemBuilder = new InfoItemBuilder(a, a.findViewById(android.R.id.content)); if (android.os.Build.VERSION.SDK_INT < 18) { diff --git a/app/src/main/java/org/schabi/newpipe/download/DownloadActivity.java b/app/src/main/java/org/schabi/newpipe/download/DownloadActivity.java index a7e52c486..2f77cadb2 100644 --- a/app/src/main/java/org/schabi/newpipe/download/DownloadActivity.java +++ b/app/src/main/java/org/schabi/newpipe/download/DownloadActivity.java @@ -28,6 +28,7 @@ import android.widget.SeekBar; import android.widget.TextView; import android.widget.Toast; +import org.schabi.newpipe.Themer; import org.schabi.newpipe.report.ErrorActivity; import org.schabi.newpipe.R; import org.schabi.newpipe.settings.SettingsActivity; @@ -42,7 +43,7 @@ import us.shandian.giga.ui.fragment.MissionsFragment; import us.shandian.giga.util.CrashHandler; import us.shandian.giga.util.Utility; -public class DownloadActivity extends AppCompatActivity implements AdapterView.OnItemClickListener{ +public class DownloadActivity extends Themer implements AdapterView.OnItemClickListener{ public static final String INTENT_DOWNLOAD = "us.shandian.giga.intent.DOWNLOAD"; diff --git a/app/src/main/java/org/schabi/newpipe/info_list/InfoItemHolder.java b/app/src/main/java/org/schabi/newpipe/info_list/InfoItemHolder.java index dbba4ac5f..a5e73470e 100644 --- a/app/src/main/java/org/schabi/newpipe/info_list/InfoItemHolder.java +++ b/app/src/main/java/org/schabi/newpipe/info_list/InfoItemHolder.java @@ -48,4 +48,5 @@ public class InfoItemHolder extends RecyclerView.ViewHolder { itemViewCountView = (TextView) v.findViewById(R.id.itemViewCountView); itemButton = (Button) v.findViewById(R.id.item_button); } + } diff --git a/app/src/main/java/org/schabi/newpipe/report/ErrorActivity.java b/app/src/main/java/org/schabi/newpipe/report/ErrorActivity.java index 8ebb9b155..b87fa8af8 100644 --- a/app/src/main/java/org/schabi/newpipe/report/ErrorActivity.java +++ b/app/src/main/java/org/schabi/newpipe/report/ErrorActivity.java @@ -35,6 +35,7 @@ import org.schabi.newpipe.BuildConfig; import org.schabi.newpipe.Downloader; import org.schabi.newpipe.MainActivity; import org.schabi.newpipe.R; +import org.schabi.newpipe.Themer; import org.schabi.newpipe.extractor.Parser; import java.io.PrintWriter; @@ -65,7 +66,7 @@ import java.util.Vector; * along with NewPipe. If not, see . */ -public class ErrorActivity extends AppCompatActivity { +public class ErrorActivity extends Themer { public static class ErrorInfo implements Parcelable { public int userAction; public String request; diff --git a/app/src/main/java/org/schabi/newpipe/settings/SettingsActivity.java b/app/src/main/java/org/schabi/newpipe/settings/SettingsActivity.java index e62f90c45..be4dbfc03 100644 --- a/app/src/main/java/org/schabi/newpipe/settings/SettingsActivity.java +++ b/app/src/main/java/org/schabi/newpipe/settings/SettingsActivity.java @@ -5,6 +5,7 @@ import android.content.Intent; import android.content.res.Configuration; import android.os.Bundle; import android.preference.PreferenceActivity; +import android.preference.PreferenceManager; import android.support.annotation.LayoutRes; import android.support.annotation.NonNull; import android.support.v7.app.ActionBar; @@ -16,6 +17,8 @@ import android.view.ViewGroup; import org.schabi.newpipe.R; +import java.util.Objects; + /** * Created by Christian Schabesberger on 31.08.15. @@ -43,6 +46,10 @@ public class SettingsActivity extends PreferenceActivity { @Override protected void onCreate(Bundle savedInstanceBundle) { + if (Objects.equals(PreferenceManager.getDefaultSharedPreferences(this) + .getString("theme", getResources().getString(R.string.light_theme_title)), getResources().getString(R.string.dark_theme_title))) { + setTheme(R.style.DarkTheme); + } getDelegate().installViewFactory(); getDelegate().onCreate(savedInstanceBundle); super.onCreate(savedInstanceBundle); diff --git a/app/src/main/java/org/schabi/newpipe/settings/SettingsFragment.java b/app/src/main/java/org/schabi/newpipe/settings/SettingsFragment.java index a5521dfc5..a6466daf9 100644 --- a/app/src/main/java/org/schabi/newpipe/settings/SettingsFragment.java +++ b/app/src/main/java/org/schabi/newpipe/settings/SettingsFragment.java @@ -1,6 +1,7 @@ package org.schabi.newpipe.settings; import android.app.Activity; +import android.app.ListActivity; import android.content.ClipData; import android.content.Intent; import android.content.SharedPreferences; @@ -20,6 +21,7 @@ import org.schabi.newpipe.App; import org.schabi.newpipe.R; import java.util.ArrayList; +import java.util.Objects; import info.guardianproject.netcipher.proxy.OrbotHelper; @@ -55,6 +57,7 @@ public class SettingsFragment extends PreferenceFragment String DOWNLOAD_PATH_PREFERENCE; String DOWNLOAD_PATH_AUDIO_PREFERENCE; String USE_TOR_KEY; + String THEME; public static final int REQUEST_INSTALL_ORBOT = 0x1234; @@ -63,11 +66,11 @@ public class SettingsFragment extends PreferenceFragment private ListPreference searchLanguagePreference; private Preference downloadPathPreference; private Preference downloadPathAudioPreference; + private Preference themePreference; private SharedPreferences defaultPreferences; - @Override - public void onCreate(Bundle savedInstanceState) { + public void onCreate(final Bundle savedInstanceState) { super.onCreate(savedInstanceState); addPreferencesFromResource(R.xml.settings); @@ -81,6 +84,7 @@ public class SettingsFragment extends PreferenceFragment SEARCH_LANGUAGE_PREFERENCE = getString(R.string.search_language_key); DOWNLOAD_PATH_PREFERENCE = getString(R.string.download_path_key); DOWNLOAD_PATH_AUDIO_PREFERENCE = getString(R.string.download_path_audio_key); + THEME = getString(R.string.theme_key); USE_TOR_KEY = getString(R.string.use_tor_key); // get pref objects @@ -92,6 +96,7 @@ public class SettingsFragment extends PreferenceFragment (ListPreference) findPreference(SEARCH_LANGUAGE_PREFERENCE); downloadPathPreference = findPreference(DOWNLOAD_PATH_PREFERENCE); downloadPathAudioPreference = findPreference(DOWNLOAD_PATH_AUDIO_PREFERENCE); + themePreference = findPreference(THEME); prefListener = new SharedPreferences.OnSharedPreferenceChangeListener() { @Override @@ -132,6 +137,11 @@ public class SettingsFragment extends PreferenceFragment downloadPathAudioPreference .setSummary(downloadPath); } + else if (key == THEME) + { + String theme = sharedPreferences.getString(THEME, "Light"); + themePreference.setSummary(theme); + } updateSummary(); } }; @@ -161,7 +171,6 @@ public class SettingsFragment extends PreferenceFragment activity.startActivityForResult(i, R.string.download_path_audio_key); } } - return super.onPreferenceTreeClick(preferenceScreen, preference); } @@ -216,8 +225,8 @@ public class SettingsFragment extends PreferenceFragment // installing the app does not necessarily return RESULT_OK App.configureTor(requestCode == REQUEST_INSTALL_ORBOT && OrbotHelper.requestStartTor(a)); - } + updateSummary(); super.onActivityResult(requestCode, resultCode, data); } @@ -239,6 +248,9 @@ public class SettingsFragment extends PreferenceFragment downloadPathAudioPreference.setSummary( defaultPreferences.getString(DOWNLOAD_PATH_AUDIO_PREFERENCE, getString(R.string.download_path_audio_summary))); + themePreference.setSummary( + defaultPreferences.getString(THEME, + getString(R.string.light_theme_title))); } @Override diff --git a/app/src/main/res/drawable-hdpi/ic_cast_black_24dp.png b/app/src/main/res/drawable-hdpi/ic_cast_black_24dp.png new file mode 100644 index 000000000..a35e1c672 Binary files /dev/null and b/app/src/main/res/drawable-hdpi/ic_cast_black_24dp.png differ diff --git a/app/src/main/res/drawable-hdpi/ic_cast_white_24dp.png b/app/src/main/res/drawable-hdpi/ic_cast_white_24dp.png new file mode 100644 index 000000000..60d3915ed Binary files /dev/null and b/app/src/main/res/drawable-hdpi/ic_cast_white_24dp.png differ diff --git a/app/src/main/res/drawable-hdpi/ic_file_download_black_24dp.png b/app/src/main/res/drawable-hdpi/ic_file_download_black_24dp.png new file mode 100644 index 000000000..d9aacea4c Binary files /dev/null and b/app/src/main/res/drawable-hdpi/ic_file_download_black_24dp.png differ diff --git a/app/src/main/res/drawable-hdpi/ic_file_download_white_24dp.png b/app/src/main/res/drawable-hdpi/ic_file_download_white_24dp.png new file mode 100644 index 000000000..c8a2039c5 Binary files /dev/null and b/app/src/main/res/drawable-hdpi/ic_file_download_white_24dp.png differ diff --git a/app/src/main/res/drawable-hdpi/ic_headset_white_24dp.png b/app/src/main/res/drawable-hdpi/ic_headset_white_24dp.png new file mode 100644 index 000000000..d25d3888e Binary files /dev/null and b/app/src/main/res/drawable-hdpi/ic_headset_white_24dp.png differ diff --git a/app/src/main/res/drawable-hdpi/ic_rss_feed_black_24dp.png b/app/src/main/res/drawable-hdpi/ic_rss_feed_black_24dp.png new file mode 100644 index 000000000..b0adc2912 Binary files /dev/null and b/app/src/main/res/drawable-hdpi/ic_rss_feed_black_24dp.png differ diff --git a/app/src/main/res/drawable-hdpi/ic_share_white_24dp.png b/app/src/main/res/drawable-hdpi/ic_share_white_24dp.png new file mode 100644 index 000000000..b09a6926d Binary files /dev/null and b/app/src/main/res/drawable-hdpi/ic_share_white_24dp.png differ diff --git a/app/src/main/res/drawable-hdpi/ic_thumb_down_black_24dp.png b/app/src/main/res/drawable-hdpi/ic_thumb_down_black_24dp.png new file mode 100644 index 000000000..c7807e4d6 Binary files /dev/null and b/app/src/main/res/drawable-hdpi/ic_thumb_down_black_24dp.png differ diff --git a/app/src/main/res/drawable-hdpi/ic_thumb_down_white_24dp.png b/app/src/main/res/drawable-hdpi/ic_thumb_down_white_24dp.png new file mode 100644 index 000000000..3be775a52 Binary files /dev/null and b/app/src/main/res/drawable-hdpi/ic_thumb_down_white_24dp.png differ diff --git a/app/src/main/res/drawable-hdpi/ic_thumb_up_black_24dp.png b/app/src/main/res/drawable-hdpi/ic_thumb_up_black_24dp.png new file mode 100644 index 000000000..7ffe4fa78 Binary files /dev/null and b/app/src/main/res/drawable-hdpi/ic_thumb_up_black_24dp.png differ diff --git a/app/src/main/res/drawable-hdpi/ic_thumb_up_white_24dp.png b/app/src/main/res/drawable-hdpi/ic_thumb_up_white_24dp.png new file mode 100644 index 000000000..c21a4643d Binary files /dev/null and b/app/src/main/res/drawable-hdpi/ic_thumb_up_white_24dp.png differ diff --git a/app/src/main/res/drawable-mdpi/ic_cast_black_24dp.png b/app/src/main/res/drawable-mdpi/ic_cast_black_24dp.png new file mode 100644 index 000000000..aa5d6cd2a Binary files /dev/null and b/app/src/main/res/drawable-mdpi/ic_cast_black_24dp.png differ diff --git a/app/src/main/res/drawable-mdpi/ic_cast_white_24dp.png b/app/src/main/res/drawable-mdpi/ic_cast_white_24dp.png new file mode 100644 index 000000000..d62923f16 Binary files /dev/null and b/app/src/main/res/drawable-mdpi/ic_cast_white_24dp.png differ diff --git a/app/src/main/res/drawable-mdpi/ic_file_download_black_24dp.png b/app/src/main/res/drawable-mdpi/ic_file_download_black_24dp.png new file mode 100644 index 000000000..c2c845e84 Binary files /dev/null and b/app/src/main/res/drawable-mdpi/ic_file_download_black_24dp.png differ diff --git a/app/src/main/res/drawable-mdpi/ic_file_download_white_24dp.png b/app/src/main/res/drawable-mdpi/ic_file_download_white_24dp.png new file mode 100644 index 000000000..d400472fd Binary files /dev/null and b/app/src/main/res/drawable-mdpi/ic_file_download_white_24dp.png differ diff --git a/app/src/main/res/drawable-mdpi/ic_headset_black_24dp.png b/app/src/main/res/drawable-mdpi/ic_headset_black_24dp.png new file mode 100644 index 000000000..d872b05d5 Binary files /dev/null and b/app/src/main/res/drawable-mdpi/ic_headset_black_24dp.png differ diff --git a/app/src/main/res/drawable-mdpi/ic_headset_white_24dp.png b/app/src/main/res/drawable-mdpi/ic_headset_white_24dp.png new file mode 100644 index 000000000..df063799d Binary files /dev/null and b/app/src/main/res/drawable-mdpi/ic_headset_white_24dp.png differ diff --git a/app/src/main/res/drawable-mdpi/ic_rss_feed_black_24dp.png b/app/src/main/res/drawable-mdpi/ic_rss_feed_black_24dp.png new file mode 100644 index 000000000..7fb28d5c5 Binary files /dev/null and b/app/src/main/res/drawable-mdpi/ic_rss_feed_black_24dp.png differ diff --git a/app/src/main/res/drawable-mdpi/ic_share_white_24dp.png b/app/src/main/res/drawable-mdpi/ic_share_white_24dp.png new file mode 100644 index 000000000..e944fd70c Binary files /dev/null and b/app/src/main/res/drawable-mdpi/ic_share_white_24dp.png differ diff --git a/app/src/main/res/drawable-mdpi/ic_thumb_down_black_24dp.png b/app/src/main/res/drawable-mdpi/ic_thumb_down_black_24dp.png new file mode 100644 index 000000000..fa4d6ff7e Binary files /dev/null and b/app/src/main/res/drawable-mdpi/ic_thumb_down_black_24dp.png differ diff --git a/app/src/main/res/drawable-mdpi/ic_thumb_down_white_24dp.png b/app/src/main/res/drawable-mdpi/ic_thumb_down_white_24dp.png new file mode 100644 index 000000000..ccb7bb76b Binary files /dev/null and b/app/src/main/res/drawable-mdpi/ic_thumb_down_white_24dp.png differ diff --git a/app/src/main/res/drawable-mdpi/ic_thumb_up_black_24dp.png b/app/src/main/res/drawable-mdpi/ic_thumb_up_black_24dp.png new file mode 100644 index 000000000..04162adc8 Binary files /dev/null and b/app/src/main/res/drawable-mdpi/ic_thumb_up_black_24dp.png differ diff --git a/app/src/main/res/drawable-mdpi/ic_thumb_up_white_24dp.png b/app/src/main/res/drawable-mdpi/ic_thumb_up_white_24dp.png new file mode 100644 index 000000000..10a6de71f Binary files /dev/null and b/app/src/main/res/drawable-mdpi/ic_thumb_up_white_24dp.png differ diff --git a/app/src/main/res/drawable-nodpi/thumbs_down.png b/app/src/main/res/drawable-nodpi/thumbs_down.png deleted file mode 100644 index 23c0f0487..000000000 Binary files a/app/src/main/res/drawable-nodpi/thumbs_down.png and /dev/null differ diff --git a/app/src/main/res/drawable-nodpi/thumbs_up.png b/app/src/main/res/drawable-nodpi/thumbs_up.png deleted file mode 100644 index 1fdd2293f..000000000 Binary files a/app/src/main/res/drawable-nodpi/thumbs_up.png and /dev/null differ diff --git a/app/src/main/res/drawable-xhdpi/ic_cast_black_24dp.png b/app/src/main/res/drawable-xhdpi/ic_cast_black_24dp.png new file mode 100644 index 000000000..1fe4879df Binary files /dev/null and b/app/src/main/res/drawable-xhdpi/ic_cast_black_24dp.png differ diff --git a/app/src/main/res/drawable-xhdpi/ic_cast_white_24dp.png b/app/src/main/res/drawable-xhdpi/ic_cast_white_24dp.png new file mode 100644 index 000000000..f5f7c14b3 Binary files /dev/null and b/app/src/main/res/drawable-xhdpi/ic_cast_white_24dp.png differ diff --git a/app/src/main/res/drawable-xhdpi/ic_file_download_black_24dp.png b/app/src/main/res/drawable-xhdpi/ic_file_download_black_24dp.png new file mode 100644 index 000000000..f5afb24dc Binary files /dev/null and b/app/src/main/res/drawable-xhdpi/ic_file_download_black_24dp.png differ diff --git a/app/src/main/res/drawable-xhdpi/ic_file_download_white_24dp.png b/app/src/main/res/drawable-xhdpi/ic_file_download_white_24dp.png new file mode 100644 index 000000000..f53cc0c62 Binary files /dev/null and b/app/src/main/res/drawable-xhdpi/ic_file_download_white_24dp.png differ diff --git a/app/src/main/res/drawable-xhdpi/ic_headset_black_24dp.png b/app/src/main/res/drawable-xhdpi/ic_headset_black_24dp.png new file mode 100644 index 000000000..f2664dcde Binary files /dev/null and b/app/src/main/res/drawable-xhdpi/ic_headset_black_24dp.png differ diff --git a/app/src/main/res/drawable-xhdpi/ic_headset_white_24dp.png b/app/src/main/res/drawable-xhdpi/ic_headset_white_24dp.png new file mode 100644 index 000000000..d7a741b61 Binary files /dev/null and b/app/src/main/res/drawable-xhdpi/ic_headset_white_24dp.png differ diff --git a/app/src/main/res/drawable-xhdpi/ic_rss_feed_black_24dp.png b/app/src/main/res/drawable-xhdpi/ic_rss_feed_black_24dp.png new file mode 100644 index 000000000..7eb9897d8 Binary files /dev/null and b/app/src/main/res/drawable-xhdpi/ic_rss_feed_black_24dp.png differ diff --git a/app/src/main/res/drawable-xhdpi/ic_share_white_24dp.png b/app/src/main/res/drawable-xhdpi/ic_share_white_24dp.png new file mode 100644 index 000000000..22a8783e7 Binary files /dev/null and b/app/src/main/res/drawable-xhdpi/ic_share_white_24dp.png differ diff --git a/app/src/main/res/drawable-xhdpi/ic_thumb_down_black_24dp.png b/app/src/main/res/drawable-xhdpi/ic_thumb_down_black_24dp.png new file mode 100644 index 000000000..a5679f360 Binary files /dev/null and b/app/src/main/res/drawable-xhdpi/ic_thumb_down_black_24dp.png differ diff --git a/app/src/main/res/drawable-xhdpi/ic_thumb_down_white_24dp.png b/app/src/main/res/drawable-xhdpi/ic_thumb_down_white_24dp.png new file mode 100644 index 000000000..709b89291 Binary files /dev/null and b/app/src/main/res/drawable-xhdpi/ic_thumb_down_white_24dp.png differ diff --git a/app/src/main/res/drawable-xhdpi/ic_thumb_up_black_24dp.png b/app/src/main/res/drawable-xhdpi/ic_thumb_up_black_24dp.png new file mode 100644 index 000000000..76ccf695a Binary files /dev/null and b/app/src/main/res/drawable-xhdpi/ic_thumb_up_black_24dp.png differ diff --git a/app/src/main/res/drawable-xhdpi/ic_thumb_up_white_24dp.png b/app/src/main/res/drawable-xhdpi/ic_thumb_up_white_24dp.png new file mode 100644 index 000000000..75ae1f5f1 Binary files /dev/null and b/app/src/main/res/drawable-xhdpi/ic_thumb_up_white_24dp.png differ diff --git a/app/src/main/res/drawable-xxhdpi/ic_cast_black_24dp.png b/app/src/main/res/drawable-xxhdpi/ic_cast_black_24dp.png new file mode 100644 index 000000000..454b66b62 Binary files /dev/null and b/app/src/main/res/drawable-xxhdpi/ic_cast_black_24dp.png differ diff --git a/app/src/main/res/drawable-xxhdpi/ic_cast_white_24dp.png b/app/src/main/res/drawable-xxhdpi/ic_cast_white_24dp.png new file mode 100644 index 000000000..7a7673fb9 Binary files /dev/null and b/app/src/main/res/drawable-xxhdpi/ic_cast_white_24dp.png differ diff --git a/app/src/main/res/drawable-xxhdpi/ic_file_download_black_24dp.png b/app/src/main/res/drawable-xxhdpi/ic_file_download_black_24dp.png new file mode 100644 index 000000000..ce97c85df Binary files /dev/null and b/app/src/main/res/drawable-xxhdpi/ic_file_download_black_24dp.png differ diff --git a/app/src/main/res/drawable-xxhdpi/ic_file_download_white_24dp.png b/app/src/main/res/drawable-xxhdpi/ic_file_download_white_24dp.png new file mode 100644 index 000000000..78aa59166 Binary files /dev/null and b/app/src/main/res/drawable-xxhdpi/ic_file_download_white_24dp.png differ diff --git a/app/src/main/res/drawable-xxhdpi/ic_headset_black_24dp.png b/app/src/main/res/drawable-xxhdpi/ic_headset_black_24dp.png new file mode 100644 index 000000000..baf3ee295 Binary files /dev/null and b/app/src/main/res/drawable-xxhdpi/ic_headset_black_24dp.png differ diff --git a/app/src/main/res/drawable-xxhdpi/ic_headset_white_24dp.png b/app/src/main/res/drawable-xxhdpi/ic_headset_white_24dp.png new file mode 100644 index 000000000..82db5427b Binary files /dev/null and b/app/src/main/res/drawable-xxhdpi/ic_headset_white_24dp.png differ diff --git a/app/src/main/res/drawable-xxhdpi/ic_rss_feed_black_24dp.png b/app/src/main/res/drawable-xxhdpi/ic_rss_feed_black_24dp.png new file mode 100644 index 000000000..3e3d4d97a Binary files /dev/null and b/app/src/main/res/drawable-xxhdpi/ic_rss_feed_black_24dp.png differ diff --git a/app/src/main/res/drawable-xxhdpi/ic_share_white_24dp.png b/app/src/main/res/drawable-xxhdpi/ic_share_white_24dp.png new file mode 100644 index 000000000..a35b3cd14 Binary files /dev/null and b/app/src/main/res/drawable-xxhdpi/ic_share_white_24dp.png differ diff --git a/app/src/main/res/drawable-xxhdpi/ic_thumb_down_black_24dp.png b/app/src/main/res/drawable-xxhdpi/ic_thumb_down_black_24dp.png new file mode 100644 index 000000000..37ce6c909 Binary files /dev/null and b/app/src/main/res/drawable-xxhdpi/ic_thumb_down_black_24dp.png differ diff --git a/app/src/main/res/drawable-xxhdpi/ic_thumb_down_white_24dp.png b/app/src/main/res/drawable-xxhdpi/ic_thumb_down_white_24dp.png new file mode 100644 index 000000000..a6e0b10c6 Binary files /dev/null and b/app/src/main/res/drawable-xxhdpi/ic_thumb_down_white_24dp.png differ diff --git a/app/src/main/res/drawable-xxhdpi/ic_thumb_up_black_24dp.png b/app/src/main/res/drawable-xxhdpi/ic_thumb_up_black_24dp.png new file mode 100644 index 000000000..d7004fe5b Binary files /dev/null and b/app/src/main/res/drawable-xxhdpi/ic_thumb_up_black_24dp.png differ diff --git a/app/src/main/res/drawable-xxhdpi/ic_thumb_up_white_24dp.png b/app/src/main/res/drawable-xxhdpi/ic_thumb_up_white_24dp.png new file mode 100644 index 000000000..cedf001de Binary files /dev/null and b/app/src/main/res/drawable-xxhdpi/ic_thumb_up_white_24dp.png differ diff --git a/app/src/main/res/drawable-xxxhdpi/ic_cast_black_24dp.png b/app/src/main/res/drawable-xxxhdpi/ic_cast_black_24dp.png new file mode 100644 index 000000000..9dbfcd941 Binary files /dev/null and b/app/src/main/res/drawable-xxxhdpi/ic_cast_black_24dp.png differ diff --git a/app/src/main/res/drawable-xxxhdpi/ic_cast_white_24dp.png b/app/src/main/res/drawable-xxxhdpi/ic_cast_white_24dp.png new file mode 100644 index 000000000..bb3539c64 Binary files /dev/null and b/app/src/main/res/drawable-xxxhdpi/ic_cast_white_24dp.png differ diff --git a/app/src/main/res/drawable-xxxhdpi/ic_file_download_black_24dp.png b/app/src/main/res/drawable-xxxhdpi/ic_file_download_black_24dp.png new file mode 100644 index 000000000..8c83bffa7 Binary files /dev/null and b/app/src/main/res/drawable-xxxhdpi/ic_file_download_black_24dp.png differ diff --git a/app/src/main/res/drawable-xxxhdpi/ic_file_download_white_24dp.png b/app/src/main/res/drawable-xxxhdpi/ic_file_download_white_24dp.png new file mode 100644 index 000000000..ded5652e4 Binary files /dev/null and b/app/src/main/res/drawable-xxxhdpi/ic_file_download_white_24dp.png differ diff --git a/app/src/main/res/drawable-xxxhdpi/ic_headset_black_24dp.png b/app/src/main/res/drawable-xxxhdpi/ic_headset_black_24dp.png new file mode 100644 index 000000000..974457ee1 Binary files /dev/null and b/app/src/main/res/drawable-xxxhdpi/ic_headset_black_24dp.png differ diff --git a/app/src/main/res/drawable-xxxhdpi/ic_headset_white_24dp.png b/app/src/main/res/drawable-xxxhdpi/ic_headset_white_24dp.png new file mode 100644 index 000000000..0f0b2e154 Binary files /dev/null and b/app/src/main/res/drawable-xxxhdpi/ic_headset_white_24dp.png differ diff --git a/app/src/main/res/drawable-xxxhdpi/ic_rss_feed_black_24dp.png b/app/src/main/res/drawable-xxxhdpi/ic_rss_feed_black_24dp.png new file mode 100644 index 000000000..d2cc96ac7 Binary files /dev/null and b/app/src/main/res/drawable-xxxhdpi/ic_rss_feed_black_24dp.png differ diff --git a/app/src/main/res/drawable-xxxhdpi/ic_share_white_24dp.png b/app/src/main/res/drawable-xxxhdpi/ic_share_white_24dp.png new file mode 100644 index 000000000..e351c7beb Binary files /dev/null and b/app/src/main/res/drawable-xxxhdpi/ic_share_white_24dp.png differ diff --git a/app/src/main/res/drawable-xxxhdpi/ic_thumb_down_black_24dp.png b/app/src/main/res/drawable-xxxhdpi/ic_thumb_down_black_24dp.png new file mode 100644 index 000000000..cea7381b5 Binary files /dev/null and b/app/src/main/res/drawable-xxxhdpi/ic_thumb_down_black_24dp.png differ diff --git a/app/src/main/res/drawable-xxxhdpi/ic_thumb_down_white_24dp.png b/app/src/main/res/drawable-xxxhdpi/ic_thumb_down_white_24dp.png new file mode 100644 index 000000000..afecc66b7 Binary files /dev/null and b/app/src/main/res/drawable-xxxhdpi/ic_thumb_down_white_24dp.png differ diff --git a/app/src/main/res/drawable-xxxhdpi/ic_thumb_up_black_24dp.png b/app/src/main/res/drawable-xxxhdpi/ic_thumb_up_black_24dp.png new file mode 100644 index 000000000..8d9682036 Binary files /dev/null and b/app/src/main/res/drawable-xxxhdpi/ic_thumb_up_black_24dp.png differ diff --git a/app/src/main/res/drawable-xxxhdpi/ic_thumb_up_white_24dp.png b/app/src/main/res/drawable-xxxhdpi/ic_thumb_up_white_24dp.png new file mode 100644 index 000000000..f43cef8ec Binary files /dev/null and b/app/src/main/res/drawable-xxxhdpi/ic_thumb_up_white_24dp.png differ diff --git a/app/src/main/res/drawable/splash_screen.xml b/app/src/main/res/drawable/splash_screen.xml index 96edac61b..e049c2941 100644 --- a/app/src/main/res/drawable/splash_screen.xml +++ b/app/src/main/res/drawable/splash_screen.xml @@ -2,7 +2,7 @@ + android:drawable="?android:attr/windowBackground"/> + xmlns:tools="http://schemas.android.com/tools" + xmlns:app="http://schemas.android.com/apk/res-auto" + tools:context=".detail.VideoItemDetailFragment" + android:textIsSelectable="true" + style="?android:attr/textAppearanceLarge" + android:layout_width="match_parent" + android:layout_height="match_parent" + android:id="@+id/video_item_detail"> + android:layout_width="wrap_content" + android:layout_height="wrap_content" + android:layout_centerInParent="true" + android:indeterminate="true"/> + android:contentDescription="@string/detail_thumbnail_view_description" + android:layout_width="match_parent" + android:layout_height="wrap_content" + android:scaleType="fitCenter" + android:adjustViewBounds="true" + android:layout_alignParentLeft="true" + android:layout_alignParentStart="true" + android:layout_alignParentTop="true" + android:background="@android:color/black" + android:src="@drawable/dummy_thumbnail_dark"/> + android:layout_width="wrap_content" + android:layout_height="wrap_content" + android:background="@android:color/transparent" + android:layout_centerInParent="true" + android:src="@drawable/new_play_arrow" + android:visibility="invisible"/>