Compare commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
dcdd83243b | ||
|
|
bc3e5a706d | ||
|
|
0b56d9dd23 | ||
|
|
62ccdf8eba | ||
|
|
72f4226419 | ||
|
|
f6a45beac5 | ||
|
|
a657ddef58 | ||
|
|
726e38ff2e | ||
|
|
191d3f760e | ||
|
|
2cd3b0f39c | ||
|
|
abd990eef7 | ||
|
|
cd875af7d7 | ||
|
|
b1e8f93371 | ||
|
|
64afd0222b | ||
|
|
32369f1f38 | ||
|
|
f00be506cc | ||
|
|
248fd1ce9c | ||
|
|
3e2d4bb665 | ||
|
|
92689941ca | ||
|
|
c46110cfea | ||
|
|
b5250e0b8d | ||
|
|
0e81397305 | ||
|
|
95d306eaed | ||
|
|
339a4fe01f | ||
|
|
48cdbc7681 | ||
|
|
5e85ba10f4 | ||
|
|
ea7dd7aba5 | ||
|
|
c60b766f37 | ||
|
|
da9ded2ae1 | ||
|
|
29eb517bb9 | ||
|
|
84a3f6caff | ||
|
|
b34821463a | ||
|
|
127abbaaeb | ||
|
|
d462d42775 | ||
|
|
5e80ad7e4e | ||
|
|
e1aadade5f | ||
|
|
77d6f5d977 | ||
|
|
c4ae2ec0a3 | ||
|
|
07ee9269b7 | ||
|
|
3ee43f1c50 | ||
|
|
dd65196af9 | ||
|
|
5547de006b | ||
|
|
0fbf571c60 | ||
|
|
f5f05697b6 | ||
|
|
5f179f6a26 | ||
|
|
37c6d29e84 | ||
|
|
0e81ba31cb | ||
|
|
1f24d32109 | ||
|
|
ff16f84c43 | ||
|
|
5b929bf515 | ||
|
|
bdcb3db238 | ||
|
|
f7960b1695 | ||
|
|
825d1b95da | ||
|
|
0e7abaf3f0 | ||
|
|
2731989ae8 | ||
|
|
5ad09e11df | ||
|
|
653d2eeeee | ||
|
|
756ad615ed |
@@ -118,6 +118,19 @@ public class PreferencesUtil {
|
||||
fragment.ay().d(preference); // fragment.getPreferenceScreen().addPreference(preference)
|
||||
}
|
||||
|
||||
public static void addPreferenceDrawable(MaterialPreferenceToolbarFragment fragment, String key, CharSequence title, CharSequence summary, @Nullable Drawable icon, Preference.c listener) {
|
||||
Preference preference = new Preference(getContext());
|
||||
preference.b(summary); // setSummary
|
||||
preference.c(title); // setTitle
|
||||
preference.d(key); // setKey
|
||||
|
||||
if (icon != null)
|
||||
preference.a(icon); // preference.setIcon
|
||||
preference.a(listener); // preference.setOnPreferenceClickListener(listener)
|
||||
|
||||
fragment.ay().d(preference); // fragment.getPreferenceScreen().addPreference(preference)
|
||||
}
|
||||
|
||||
public static void addPreferenceCategory(MaterialPreferenceToolbarFragment fragment, CharSequence title) {
|
||||
PreferenceCategory preference = new PreferenceCategory(getContext(), null);
|
||||
preference.c(title); // setTitle
|
||||
|
||||
@@ -1,11 +1,10 @@
|
||||
package ru.vtosters.lite.ui.fragments;
|
||||
|
||||
import static ru.vtosters.lite.utils.Globals.getString;
|
||||
import static ru.vtosters.lite.utils.Globals.restartApplicationWithTimer;
|
||||
|
||||
import android.os.Bundle;
|
||||
import android.support.v7.preference.Preference;
|
||||
|
||||
import com.vk.core.util.ToastUtils;
|
||||
import com.vtosters.lite.R;
|
||||
import com.vtosters.lite.fragments.MaterialPreferenceToolbarFragment;
|
||||
|
||||
@@ -18,16 +17,20 @@ public class InterfaceFragment extends MaterialPreferenceToolbarFragment {
|
||||
}
|
||||
|
||||
private void prefs() {
|
||||
a("newfeed").a(new a());
|
||||
a("newfeed").a(new restart());
|
||||
a("dateformat").a(new restart());
|
||||
a("stories").a(new restart());
|
||||
a("swipe").a(new restart());
|
||||
a("dockcounter").a(new restart());
|
||||
}
|
||||
|
||||
public boolean restart(Preference preference, Object obj) {
|
||||
ToastUtils.a(getString("restartapp"));
|
||||
restartApplicationWithTimer();
|
||||
return true;
|
||||
}
|
||||
|
||||
public class a implements Preference.b {
|
||||
a() {
|
||||
public class restart implements Preference.b {
|
||||
restart() {
|
||||
}
|
||||
|
||||
@Override // android.support.v7.preference.Preference.b
|
||||
|
||||
@@ -1,6 +1,9 @@
|
||||
package ru.vtosters.lite.ui.fragments;
|
||||
|
||||
import static ru.vtosters.lite.utils.Globals.restartApplicationWithTimer;
|
||||
|
||||
import android.os.Bundle;
|
||||
import android.support.v7.preference.Preference;
|
||||
|
||||
import com.vtosters.lite.R;
|
||||
import com.vtosters.lite.fragments.MaterialPreferenceToolbarFragment;
|
||||
@@ -10,5 +13,25 @@ public class MessagesFragment extends MaterialPreferenceToolbarFragment {
|
||||
public void b(Bundle bundle) {
|
||||
super.b(bundle);
|
||||
a(R.xml.preferences_messages);
|
||||
prefs();
|
||||
}
|
||||
|
||||
private void prefs() {
|
||||
a("vkme").a(new MessagesFragment.restart());
|
||||
}
|
||||
|
||||
public boolean restart(Preference preference, Object obj) {
|
||||
restartApplicationWithTimer();
|
||||
return true;
|
||||
}
|
||||
|
||||
public class restart implements Preference.b {
|
||||
restart() {
|
||||
}
|
||||
|
||||
@Override // android.support.v7.preference.Preference.b
|
||||
public boolean a(Preference preference, Object obj) {
|
||||
return MessagesFragment.this.restart(preference, obj);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -2,6 +2,7 @@ package ru.vtosters.lite.ui.fragments;
|
||||
|
||||
import static ru.vtosters.lite.utils.Globals.componentSwitcher;
|
||||
import static ru.vtosters.lite.utils.Globals.getString;
|
||||
import static ru.vtosters.lite.utils.Globals.restartApplicationWithTimer;
|
||||
|
||||
import android.os.Bundle;
|
||||
import android.support.v7.preference.Preference;
|
||||
@@ -34,14 +35,15 @@ public class ThemesFragment extends MaterialPreferenceToolbarFragment {
|
||||
|
||||
private void prefs() {
|
||||
a("iconvk").a(new a());
|
||||
a("darktheme").a(new b());
|
||||
a("lighttheme").a(new b());
|
||||
a("darktheme").a(new restart());
|
||||
a("lighttheme").a(new restart());
|
||||
a("navbar").a(new restart());
|
||||
}
|
||||
|
||||
public static class b implements Preference.b {
|
||||
public static class restart implements Preference.b {
|
||||
@Override // android.support.v7.preference.Preference.b
|
||||
public boolean a(Preference preference, Object obj) {
|
||||
ToastUtils.a(getString("restartapp"));
|
||||
restartApplicationWithTimer();
|
||||
return true;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -0,0 +1,385 @@
|
||||
package ru.vtosters.lite.ui.fragments;
|
||||
|
||||
import static bruhcollective.itaysonlab.libvkx.client.LibVKXClient.isIntegrationEnabled;
|
||||
import static ru.vtosters.lite.f0x1d.VTVerifications.vtverif;
|
||||
import static ru.vtosters.lite.ui.fragments.multiaccount.MultiAccountManager.getAccountPrefsCount;
|
||||
import static ru.vtosters.lite.ui.fragments.multiaccount.MultiAccountManager.getCurrentAccount;
|
||||
import static ru.vtosters.lite.ui.fragments.multiaccount.MultiAccountManager.withRegex;
|
||||
import static ru.vtosters.lite.ui.fragments.multiaccount.MultiAccountManager.workingAccounts;
|
||||
import static ru.vtosters.lite.utils.About.getBuildNumber;
|
||||
import static ru.vtosters.lite.utils.About.getCommitLink;
|
||||
import static ru.vtosters.lite.utils.Globals.drawableFromUrl;
|
||||
import static ru.vtosters.lite.utils.Globals.edit;
|
||||
import static ru.vtosters.lite.utils.Globals.getContext;
|
||||
import static ru.vtosters.lite.utils.Globals.getIdentifier;
|
||||
import static ru.vtosters.lite.utils.Globals.getPrefsValue;
|
||||
import static ru.vtosters.lite.utils.Globals.getString;
|
||||
import static ru.vtosters.lite.utils.Globals.getUserId;
|
||||
import static ru.vtosters.lite.utils.Globals.isGmsInstalled;
|
||||
import static ru.vtosters.lite.utils.Globals.restartApplicationWithTimer;
|
||||
import static ru.vtosters.lite.utils.Preferences.ads;
|
||||
import static ru.vtosters.lite.utils.Preferences.devmenu;
|
||||
import static ru.vtosters.lite.utils.Preferences.disableSettingsSumms;
|
||||
import static ru.vtosters.lite.utils.Preferences.hasSpecialVerif;
|
||||
import static ru.vtosters.lite.utils.Preferences.navbar;
|
||||
import static ru.vtosters.lite.utils.Preferences.offline;
|
||||
import static ru.vtosters.lite.utils.Preferences.shortinfo;
|
||||
import static ru.vtosters.lite.utils.Preferences.vkme;
|
||||
import static ru.vtosters.lite.utils.Themes.applyTheme;
|
||||
import static ru.vtosters.lite.utils.Themes.getDarkTheme;
|
||||
import static ru.vtosters.lite.utils.Themes.getImDarkTheme;
|
||||
import static ru.vtosters.lite.utils.Themes.getImLightTheme;
|
||||
import static ru.vtosters.lite.utils.Themes.getLightTheme;
|
||||
import static ru.vtosters.lite.utils.Themes.setTheme;
|
||||
|
||||
import android.content.Context;
|
||||
import android.content.Intent;
|
||||
import android.net.Uri;
|
||||
import android.os.Build;
|
||||
import android.os.Bundle;
|
||||
|
||||
import com.aefyr.tsg.g2.TelegramStickersService;
|
||||
import com.vk.about.AboutAppFragment;
|
||||
import com.vk.identity.fragments.IdentityListFragment;
|
||||
import com.vk.navigation.Navigator;
|
||||
import com.vk.notifications.settings.NotificationsSettingsFragment;
|
||||
import com.vk.webapp.Bugs;
|
||||
import com.vk.webapp.PrivacyFragment;
|
||||
import com.vk.webapp.SSFS;
|
||||
import com.vk.webapp.VKConnect;
|
||||
import com.vtosters.lite.auth.VKAccountManager;
|
||||
import com.vtosters.lite.fragments.MaterialPreferenceToolbarFragment;
|
||||
import com.vtosters.lite.fragments.SettingsAccountFragment;
|
||||
import com.vtosters.lite.fragments.SettingsDebugFragment;
|
||||
import com.vtosters.lite.fragments.SettingsGeneralFragment;
|
||||
import com.vtosters.lite.fragments.k.BlacklistFragment;
|
||||
import com.vtosters.lite.fragments.money.music.control.subscription.MusicSubscriptionControlFragment;
|
||||
|
||||
import ru.vtosters.lite.ui.PreferencesUtil;
|
||||
import ru.vtosters.lite.ui.fragments.dockbar.DockBarFragment;
|
||||
import ru.vtosters.lite.ui.fragments.dockbar.DockBarManager;
|
||||
import ru.vtosters.lite.ui.fragments.multiaccount.MultiAccountFragment;
|
||||
import ru.vtosters.lite.ui.fragments.tgstickers.StickersFragment;
|
||||
|
||||
public class VTSettings extends MaterialPreferenceToolbarFragment {
|
||||
|
||||
@Override
|
||||
public void b(Bundle bundle) {
|
||||
super.b(bundle);
|
||||
|
||||
String keyVKAccount = getCurrentAccount().getString("key_vk_account", "");
|
||||
String avatarUrl = withRegex(keyVKAccount, ".*\"photo\":\\{.*?:\"(.*?)\"\\}.*", "https://vk.com/images/camera_200.png").replace("\\/", "/");
|
||||
String name = withRegex(keyVKAccount, ".*\"name\":\\{.*?:\"(.*?)\"\\}.*", "");
|
||||
String id = "@id" + getUserId();
|
||||
|
||||
String feedsumm = getValAsString("vtlfeedsumm", ads());
|
||||
String docksumm = getDocksumm();
|
||||
String musicsumm = getValAsString("vtlmusicsumm", isIntegrationEnabled());
|
||||
String msgsumm = getValAsString("vtlmsgsumm", vkme());
|
||||
String activitysumm = getValAsString("vtlactivitysumm", !offline());
|
||||
String themessumm = getValAsString("vtlthemessumm", navbar());
|
||||
String tgssumm = getTGSsumm();
|
||||
String interfacesumm = getValAsString("vtlinterfacesumm", shortinfo());
|
||||
String proxysumm = getValAsString("vtlproxysumm", !getPrefsValue("proxy").equals("noproxy"));
|
||||
String othersumm = getValAsString("vtlothersumm", vtverif());
|
||||
String multiaccsumm = getMultiAccsumm();
|
||||
String ssfs = getSSFSsumm();
|
||||
String about = "Commit: " + getBuildNumber();
|
||||
|
||||
int vtosterXml = getIdentifier("empty", "xml");
|
||||
this.a(vtosterXml);
|
||||
|
||||
if (vkme()) {
|
||||
PreferencesUtil.addPreferenceDrawable(this, "", name, id, drawableFromUrl(avatarUrl), preference -> {
|
||||
Context context = getContext();
|
||||
Intent a2 = new Navigator(MultiAccountFragment.class).a(context);
|
||||
context.startActivity(a2);
|
||||
return false;
|
||||
});
|
||||
} else {
|
||||
PreferencesUtil.addPreference(this, "", getString("accounts"), multiaccsumm, "ic_user_24", preference -> {
|
||||
Context context = getContext();
|
||||
Intent a2 = new Navigator(MultiAccountFragment.class).a(context);
|
||||
context.startActivity(a2);
|
||||
return false;
|
||||
});
|
||||
|
||||
PreferencesUtil.addPreferenceCategory(this, getString("vtsettdarktheme"));
|
||||
}
|
||||
|
||||
PreferencesUtil.addMaterialSwitchPreference(this, "isdark", getString("vtsettdarktheme"), "", "ic_palette_24", false, (preference, o) -> {
|
||||
boolean value = (boolean) o;
|
||||
|
||||
if(value){
|
||||
applyTheme(getLightTheme(), getImLightTheme());
|
||||
} else {
|
||||
applyTheme(getDarkTheme(), getImDarkTheme());
|
||||
}
|
||||
|
||||
edit().putBoolean("isdark", value).commit();
|
||||
|
||||
setTheme(this.p());
|
||||
|
||||
restartApplicationWithTimer();
|
||||
return true;
|
||||
});
|
||||
|
||||
if (Build.VERSION.SDK_INT >= 28) {
|
||||
PreferencesUtil.addMaterialSwitchPreference(this, "systemtheme", getString("appearance_theme_use_system"), getString("appearance_theme_use_system_summary"), "ic_recent_24", true, (preference, o) -> {
|
||||
boolean value = (boolean) o;
|
||||
|
||||
edit().putBoolean("systemtheme", value).commit();
|
||||
|
||||
return true;
|
||||
});
|
||||
}
|
||||
|
||||
if (!isGmsInstalled()) {
|
||||
PreferencesUtil.addPreference(this, "", getString("installgms"), "", "ic_alert", preference -> {
|
||||
Context context = getContext();
|
||||
Intent a2 = new Navigator(InstallGMSFragment.class).a(context);
|
||||
context.startActivity(a2);
|
||||
return false;
|
||||
});
|
||||
}
|
||||
|
||||
if(devmenu()){
|
||||
PreferencesUtil.addPreferenceCategory(this, getString("sett_debug"));
|
||||
|
||||
PreferencesUtil.addPreference(this, "", getString("sett_debug"), "", "ic_bug_24", preference -> {
|
||||
Context context = getContext();
|
||||
Intent a2 = new Navigator(SettingsDebugFragment.class).a(context);
|
||||
context.startActivity(a2);
|
||||
return false;
|
||||
});
|
||||
|
||||
PreferencesUtil.addMaterialSwitchPreference(this, "ssl", getString("debug_developer_force_ssl"), getString("debug_developer_force_ssl_summary"), "ic_globe_24", true, (preference, o) -> {
|
||||
boolean value = (boolean) o;
|
||||
edit().putBoolean("ssl", value).commit();
|
||||
return true;
|
||||
});
|
||||
}
|
||||
|
||||
PreferencesUtil.addPreferenceCategory(this, getString("vtsettaccount"));
|
||||
|
||||
PreferencesUtil.addPreference(this, "", getString("vkconnect"), "", "ic_tags_24", preference -> {
|
||||
Context context = getContext();
|
||||
Intent a2 = new Navigator(VKConnect.class).a(context);
|
||||
context.startActivity(a2);
|
||||
return false;
|
||||
});
|
||||
|
||||
PreferencesUtil.addPreference(this, "", getString("privacy_settings"), "", "ic_privacy_24", preference -> {
|
||||
Context context = getContext();
|
||||
Intent a2 = new Navigator(PrivacyFragment.class).a(context);
|
||||
context.startActivity(a2);
|
||||
return false;
|
||||
});
|
||||
|
||||
PreferencesUtil.addPreference(this, "", getString("sett_account"), "", "ic_user_24", preference -> {
|
||||
Context context = getContext();
|
||||
Intent a2 = new Navigator(SettingsAccountFragment.class).a(context);
|
||||
context.startActivity(a2);
|
||||
return false;
|
||||
});
|
||||
|
||||
PreferencesUtil.addPreference(this, "", getString("bugs"), "", "ic_bug_24", preference -> {
|
||||
Context context = getContext();
|
||||
Intent a2 = new Navigator(Bugs.class).a(context);
|
||||
context.startActivity(a2);
|
||||
return false;
|
||||
});
|
||||
|
||||
PreferencesUtil.addPreference(this, "", getString("vtssfs"), ssfs, "ic_link_24", preference -> {
|
||||
Context context = getContext();
|
||||
Intent a2 = new Navigator(SSFS.class).a(context);
|
||||
context.startActivity(a2);
|
||||
return false;
|
||||
});
|
||||
|
||||
PreferencesUtil.addPreferenceCategory(this, getString("notification_settings"));
|
||||
|
||||
PreferencesUtil.addPreference(this, "", getString("sett_general"), "", "ic_settings_24", preference -> {
|
||||
Context context = getContext();
|
||||
Intent a2 = new Navigator(SettingsGeneralFragment.class).a(context);
|
||||
context.startActivity(a2);
|
||||
return false;
|
||||
});
|
||||
|
||||
PreferencesUtil.addPreference(this, "", getString("blacklist"), "", "ic_users_24", preference -> {
|
||||
Context context = getContext();
|
||||
Intent a2 = new Navigator(BlacklistFragment.class).a(context);
|
||||
context.startActivity(a2);
|
||||
return false;
|
||||
});
|
||||
|
||||
PreferencesUtil.addPreference(this, "", getString("sett_notifications"), "", "ic_notification_24", preference -> {
|
||||
Context context = getContext();
|
||||
Intent a2 = new Navigator(NotificationsSettingsFragment.class).a(context);
|
||||
context.startActivity(a2);
|
||||
return false;
|
||||
});
|
||||
|
||||
if (VKAccountManager.b().isRealMusicSubs()) {
|
||||
PreferencesUtil.addPreference(this, "", getString("subscription_music"), "", "ic_music_24", preference -> {
|
||||
Context context = getContext();
|
||||
Intent a2 = new Navigator(MusicSubscriptionControlFragment.class).a(context);
|
||||
context.startActivity(a2);
|
||||
return false;
|
||||
});
|
||||
}
|
||||
|
||||
if (VKAccountManager.b().ar()) {
|
||||
PreferencesUtil.addPreference(this, "", getString("identity_title"), "", "ic_services_24", preference -> {
|
||||
Context context = getContext();
|
||||
Intent a2 = new Navigator(IdentityListFragment.class).a(context);
|
||||
context.startActivity(a2);
|
||||
return false;
|
||||
});
|
||||
}
|
||||
|
||||
PreferencesUtil.addPreferenceCategory(this, getString("vtsettmod"));
|
||||
|
||||
if (!vkme()) {
|
||||
PreferencesUtil.addPreference(this, "", getString("vtlfeed"), feedsumm, "ic_newsfeed_24", preference -> {
|
||||
Context context = getContext();
|
||||
Intent a2 = new Navigator(FeedFragment.class).a(context);
|
||||
context.startActivity(a2);
|
||||
return false;
|
||||
});
|
||||
|
||||
PreferencesUtil.addPreference(this, "", getString("dockbar_editor"), docksumm, "ic_list_24", preference -> {
|
||||
Context context = getContext();
|
||||
Intent a2 = new Navigator(DockBarFragment.class).a(context);
|
||||
context.startActivity(a2);
|
||||
return false;
|
||||
});
|
||||
|
||||
PreferencesUtil.addPreference(this, "", getString("vtlmusic"), musicsumm, "ic_music_24", preference -> {
|
||||
Context context = getContext();
|
||||
Intent a2 = new Navigator(MusicFragment.class).a(context);
|
||||
context.startActivity(a2);
|
||||
return false;
|
||||
});
|
||||
}
|
||||
|
||||
PreferencesUtil.addPreference(this, "", getString("vtlmessages"), msgsumm, "ic_message_24", preference -> {
|
||||
Context context = getContext();
|
||||
Intent a2 = new Navigator(MessagesFragment.class).a(context);
|
||||
context.startActivity(a2);
|
||||
return false;
|
||||
});
|
||||
|
||||
PreferencesUtil.addPreference(this, "", getString("vtlactivity"), activitysumm, "ic_write_24", preference -> {
|
||||
Context context = getContext();
|
||||
Intent a2 = new Navigator(ActivityFragment.class).a(context);
|
||||
context.startActivity(a2);
|
||||
return false;
|
||||
});
|
||||
|
||||
PreferencesUtil.addPreference(this, "", getString("vtlthemes"), themessumm, "ic_palette_24", preference -> {
|
||||
Context context = getContext();
|
||||
Intent a2 = new Navigator(ThemesFragment.class).a(context);
|
||||
context.startActivity(a2);
|
||||
return false;
|
||||
});
|
||||
|
||||
PreferencesUtil.addPreference(this, "", getString("vtltgs"), tgssumm, "ic_telegram", preference -> {
|
||||
Context context = getContext();
|
||||
Intent a2 = new Navigator(StickersFragment.class).a(context);
|
||||
context.startActivity(a2);
|
||||
return false;
|
||||
});
|
||||
|
||||
PreferencesUtil.addPreference(this, "", getString("vtlinterface"), interfacesumm, "ic_interface", preference -> {
|
||||
Context context = getContext();
|
||||
Intent a2 = new Navigator(InterfaceFragment.class).a(context);
|
||||
context.startActivity(a2);
|
||||
return false;
|
||||
});
|
||||
|
||||
PreferencesUtil.addPreference(this, "", getString("vtlproxy"), proxysumm, "ic_globe_24", preference -> {
|
||||
Context context = getContext();
|
||||
Intent a2 = new Navigator(ProxySettingsFragment.class).a(context);
|
||||
context.startActivity(a2);
|
||||
return false;
|
||||
});
|
||||
|
||||
PreferencesUtil.addPreference(this, "", getString("vtlother"), othersumm, "ic_more_24", preference -> {
|
||||
Context context = getContext();
|
||||
Intent a2 = new Navigator(OtherFragment.class).a(context);
|
||||
context.startActivity(a2);
|
||||
return false;
|
||||
});
|
||||
|
||||
PreferencesUtil.addPreferenceCategory(this, getString("vtsettaboutmod"));
|
||||
|
||||
PreferencesUtil.addPreference(this, "", getString("menu_about"), about, "ic_about_24", preference -> {
|
||||
Context context = getContext();
|
||||
Intent a2 = new Navigator(AboutAppFragment.class).a(context);
|
||||
context.startActivity(a2);
|
||||
return false;
|
||||
});
|
||||
|
||||
PreferencesUtil.addPreference(this, "", getString("opencommit"), "", "ic_link_24", preference -> {
|
||||
getContext().startActivity(new Intent("android.intent.action.VIEW").setData(Uri.parse(getCommitLink())));
|
||||
return false;
|
||||
});
|
||||
|
||||
PreferencesUtil.addPreference(this, "", getString("vtfaq"), "", "ic_help_24", preference -> {
|
||||
getContext().startActivity(new Intent("android.intent.action.VIEW").setData(Uri.parse("https://t.me/s/vtosters_faq")));
|
||||
return false;
|
||||
});
|
||||
|
||||
PreferencesUtil.addPreference(this, "", getString("reportbug"), "", "ic_bug_24", preference -> {
|
||||
getContext().startActivity(new Intent("android.intent.action.VIEW").setData(Uri.parse("https://github.com/vtosters/lite/issues")));
|
||||
return false;
|
||||
});
|
||||
|
||||
PreferencesUtil.addPreference(this, "", getString("download_latest_vtl"), "", "ic_download_24", preference -> {
|
||||
getContext().startActivity(new Intent("android.intent.action.VIEW").setData(Uri.parse("https://github.com/vtosters/lite/releases/latest")));
|
||||
return false;
|
||||
});
|
||||
}
|
||||
|
||||
public static String getValAsString(String stringid, Boolean value) {
|
||||
if(disableSettingsSumms()) return "";
|
||||
|
||||
if (value){
|
||||
return getString(stringid) + ": " + getString("vtlsettenabled");
|
||||
}
|
||||
|
||||
return getString(stringid) + ": " + getString("vtlsettdisabled");
|
||||
}
|
||||
|
||||
public static String getSSFSsumm() {
|
||||
if(disableSettingsSumms()) return "";
|
||||
|
||||
if(hasSpecialVerif()) return getString("vtlssfssumm") + ": " + getString("vtlsettverifyes");
|
||||
|
||||
return getString("vtlssfssumm") + ": " + getString("vtlsettverifno");
|
||||
}
|
||||
|
||||
public static String getDocksumm() {
|
||||
if(disableSettingsSumms()) return "";
|
||||
|
||||
return getString("vtldocksumm") + ": " + DockBarManager.getInstance().getTabCount();
|
||||
}
|
||||
|
||||
public static String getTGSsumm() {
|
||||
if(disableSettingsSumms()) return "";
|
||||
|
||||
return getString("vtltgssumm") + ": " + TelegramStickersService.getInstance(getContext()).getPacksListReference().size();
|
||||
}
|
||||
|
||||
public static String getMultiAccsumm() {
|
||||
if(disableSettingsSumms() || getAccountPrefsCount() <= 1) return "";
|
||||
|
||||
return getString("vtlmultiaccsumm") + ": " + workingAccounts();
|
||||
}
|
||||
|
||||
@Override
|
||||
public int aq() {
|
||||
return getIdentifier("notification_settings", "string");
|
||||
}
|
||||
}
|
||||
@@ -3,7 +3,10 @@ package ru.vtosters.lite.ui.fragments.dockbar;
|
||||
import static ru.vtosters.lite.utils.Globals.getContext;
|
||||
import static ru.vtosters.lite.utils.Globals.getString;
|
||||
import static ru.vtosters.lite.utils.Preferences.newfeed;
|
||||
import static ru.vtosters.lite.utils.Preferences.olddock;
|
||||
import static ru.vtosters.lite.utils.Preferences.oldicons;
|
||||
import static ru.vtosters.lite.utils.Preferences.useNewSettings;
|
||||
import static ru.vtosters.lite.utils.Preferences.vkme;
|
||||
import static ru.vtosters.lite.utils.Preferences.vkme_notifs;
|
||||
|
||||
import com.vk.apps.AppsFragment;
|
||||
import com.vk.discover.DiscoverFragment;
|
||||
@@ -18,7 +21,6 @@ import com.vtosters.lite.R;
|
||||
import com.vtosters.lite.fragments.GamesFragment;
|
||||
import com.vtosters.lite.fragments.PhotosFragment;
|
||||
import com.vtosters.lite.fragments.ProfileFragment;
|
||||
import com.vtosters.lite.fragments.SettingsListFragment;
|
||||
import com.vtosters.lite.fragments.d.DocumentsViewFragment;
|
||||
import com.vtosters.lite.fragments.f.FriendsFragment;
|
||||
import com.vtosters.lite.fragments.g.BirthdaysFragment;
|
||||
@@ -79,11 +81,19 @@ public class DockBarManager {
|
||||
File dockbar = new File(getContext().getFilesDir(), "dockbar.json");
|
||||
|
||||
if (!dockbar.exists()) {
|
||||
mSelectedTabs.add(new DockBarTab("tab_news", olddock() ? R.drawable.ic_newsfeed_28 : R.drawable.ic_menu_newsfeed_outline_28, R.string.newsfeed, R.id.tab_news, newfeed() ? HomeFragment.class : NewsfeedFragment.class));
|
||||
mSelectedTabs.add(new DockBarTab("tab_discover", olddock() ? R.drawable.ic_search_28 : R.drawable.ic_menu_search_outline_28, R.string.search, R.id.tab_discover, DiscoverFragment.class ));
|
||||
mSelectedTabs.add(new DockBarTab("tab_messages", olddock() ? R.drawable.ic_menu_messages_28 : R.drawable.ic_message_28_outline, R.string.messages, R.id.tab_messages, DialogsFragment.class));
|
||||
mSelectedTabs.add(new DockBarTab("tab_feedback", olddock() ? R.drawable.ic_menu_notifications_28 : R.drawable.ic_menu_notification_outline_28, R.string.feedback, R.id.tab_feedback, NotificationsContainerFragment.class));
|
||||
mSelectedTabs.add(new DockBarTab("tab_menu", olddock() ? R.drawable.ic_menu_more_28 : R.drawable.ic_menu_more_outline_28, R.string.menu, R.id.tab_menu, MenuFragment.class));
|
||||
if(vkme()) {
|
||||
mSelectedTabs.add(new DockBarTab("tab_settings", R.drawable.ic_settings_24, R.string.menu_settings, R.id.menu_settings, useNewSettings()));
|
||||
if(vkme_notifs()) mSelectedTabs.add(new DockBarTab("tab_feedback", oldicons() ? R.drawable.ic_menu_notifications_28 : R.drawable.ic_menu_notification_outline_28, R.string.feedback, R.id.tab_feedback, NotificationsContainerFragment.class));
|
||||
mSelectedTabs.add(new DockBarTab("tab_messages", oldicons() ? R.drawable.ic_menu_messages_28 : R.drawable.ic_message_28_outline, R.string.messages, R.id.tab_messages, DialogsFragment.class));
|
||||
mSelectedTabs.add(new DockBarTab("tab_profile", R.drawable.libverify_ic_account_circle_white, R.string.profile, R.id.profile, ProfileFragment.class));
|
||||
return;
|
||||
}
|
||||
|
||||
mSelectedTabs.add(new DockBarTab("tab_news", oldicons() ? R.drawable.ic_newsfeed_28 : R.drawable.ic_menu_newsfeed_outline_28, R.string.newsfeed, R.id.tab_news, newfeed() ? HomeFragment.class : NewsfeedFragment.class));
|
||||
mSelectedTabs.add(new DockBarTab("tab_discover", oldicons() ? R.drawable.ic_search_28 : R.drawable.ic_menu_search_outline_28, R.string.search, R.id.tab_discover, DiscoverFragment.class ));
|
||||
mSelectedTabs.add(new DockBarTab("tab_messages", oldicons() ? R.drawable.ic_menu_messages_28 : R.drawable.ic_message_28_outline, R.string.messages, R.id.tab_messages, DialogsFragment.class));
|
||||
mSelectedTabs.add(new DockBarTab("tab_feedback", oldicons() ? R.drawable.ic_menu_notifications_28 : R.drawable.ic_menu_notification_outline_28, R.string.feedback, R.id.tab_feedback, NotificationsContainerFragment.class));
|
||||
mSelectedTabs.add(new DockBarTab("tab_menu", oldicons() ? R.drawable.ic_menu_more_28 : R.drawable.ic_menu_more_outline_28, R.string.menu, R.id.tab_menu, MenuFragment.class));
|
||||
|
||||
mDisabledTabs.add(new DockBarTab("tab_friends", R.drawable.ic_user_24, R.string.friends, R.id.menu_friends, FriendsFragment.class));
|
||||
mDisabledTabs.add(new DockBarTab("tab_groups", R.drawable.ic_users_24, R.string.groups, R.id.menu_groups, GroupsFragment.class));
|
||||
@@ -98,7 +108,7 @@ public class DockBarManager {
|
||||
mDisabledTabs.add(new DockBarTab("tab_payments", R.drawable.ic_money_transfer_24, R.string.money_transfer_money_transfers, R.id.menu_payments, MoneyTransfersFragment.class));
|
||||
mDisabledTabs.add(new DockBarTab("tab_vk_apps", R.drawable.ic_services_24, R.string.menu_apps, R.id.menu_vk_apps, AppsFragment.class));
|
||||
mDisabledTabs.add(new DockBarTab("tab_profile", R.drawable.libverify_ic_account_circle_white, R.string.profile, R.id.profile, ProfileFragment.class));
|
||||
mDisabledTabs.add(new DockBarTab("tab_settings", R.drawable.ic_settings_24, R.string.menu_settings, R.id.menu_settings, SettingsListFragment.class));
|
||||
mDisabledTabs.add(new DockBarTab("tab_settings", R.drawable.ic_settings_24, R.string.menu_settings, R.id.menu_settings, useNewSettings()));
|
||||
mDisabledTabs.add(new DockBarTab("tab_brtd", R.drawable.ic_menu_birthdays, R.string.birthdays_title, R.id.menu_birthdays, BirthdaysFragment.class));
|
||||
|
||||
} else {
|
||||
@@ -225,8 +235,11 @@ public class DockBarManager {
|
||||
int target = adapter.getIndexByViewType(toPosition, adapter.getItemType(toPosition));
|
||||
if (fromPosition < toPosition) {
|
||||
|
||||
if (mSelectedTabs.size() <= MIN_SELECTED_TABS_LIMIT || mSelectedTabs.get(curr).tag.equals("tab_menu"))
|
||||
return;
|
||||
if(!vkme()){
|
||||
if (mSelectedTabs.size() <= MIN_SELECTED_TABS_LIMIT || mSelectedTabs.get(curr).tag.equals("tab_menu")){
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
||||
DockBarTab tab = mSelectedTabs.get(curr);
|
||||
mSelectedTabs.remove(tab);
|
||||
@@ -296,6 +309,10 @@ public class DockBarManager {
|
||||
return mSelectedTabs.get(getIndexByViewType(pos, 1));
|
||||
}
|
||||
|
||||
public int getTabCount() {
|
||||
return mSelectedTabs.size();
|
||||
}
|
||||
|
||||
public DockBarTab getDisabledTab(int pos) {
|
||||
return mDisabledTabs.get(getIndexByViewType(pos, 2));
|
||||
}
|
||||
|
||||
@@ -38,7 +38,7 @@ public class MultiAccountManager {
|
||||
return getContext().getSharedPreferences("pref_account_manager" + (account != 0 ? account : ""), Context.MODE_PRIVATE);
|
||||
}
|
||||
|
||||
private static int getAccountPrefsCount() {
|
||||
public static int getAccountPrefsCount() {
|
||||
File[] prefs = new File(getContext().getFilesDir().getParent(), "shared_prefs")
|
||||
.listFiles((dir, name) -> {
|
||||
return name.matches("pref_account_manager\\d+\\.xml");
|
||||
@@ -46,7 +46,7 @@ public class MultiAccountManager {
|
||||
return prefs != null ? prefs.length : 0;
|
||||
}
|
||||
|
||||
private static String withRegex(String base, String regex, String def) {
|
||||
public static String withRegex(String base, String regex, String def) {
|
||||
Pattern pattern = Pattern.compile(regex);
|
||||
Matcher matcher = pattern.matcher(base);
|
||||
if (matcher.find()) {
|
||||
@@ -57,7 +57,7 @@ public class MultiAccountManager {
|
||||
|
||||
public static List<MultiAccountItem> buildList() {
|
||||
List<MultiAccountItem> list = new ArrayList<>();
|
||||
for (int i = 0; i <= getAccountPrefsCount(); i++) {
|
||||
for (int i = 0; i <= workingAccounts(); i++) {
|
||||
SharedPreferences prefs = getContext().getSharedPreferences("pref_account_manager" + i, Context.MODE_PRIVATE);
|
||||
String keyVKAccount = prefs.getString("key_vk_account", "");
|
||||
if (!keyVKAccount.isEmpty()) {
|
||||
@@ -72,6 +72,18 @@ public class MultiAccountManager {
|
||||
return list;
|
||||
}
|
||||
|
||||
public static int workingAccounts() {
|
||||
int count = 0;
|
||||
for (int i = 0; i <= getAccountPrefsCount(); i++) {
|
||||
SharedPreferences prefs = getContext().getSharedPreferences("pref_account_manager" + i, Context.MODE_PRIVATE);
|
||||
String keyVKAccount = prefs.getString("key_vk_account", "");
|
||||
if (!keyVKAccount.isEmpty()) {
|
||||
++count;
|
||||
}
|
||||
}
|
||||
return count;
|
||||
}
|
||||
|
||||
public static boolean switchAccount(int i) {
|
||||
int account = getPreferences().getInt("account", 0);
|
||||
if (account == i) return false;
|
||||
@@ -81,7 +93,7 @@ public class MultiAccountManager {
|
||||
}
|
||||
|
||||
public static void addAccount() {
|
||||
getPreferences().edit().putInt("account", getAccountPrefsCount()).commit();
|
||||
getPreferences().edit().putInt("account", workingAccounts()).commit();
|
||||
}
|
||||
|
||||
public static void deleteAccount(int i) {
|
||||
@@ -90,7 +102,7 @@ public class MultiAccountManager {
|
||||
prefs.edit().clear().commit();
|
||||
File file = new File(new File(getContext().getFilesDir().getParent(), "shared_prefs"), "pref_account_manager" + i);
|
||||
if (file.exists()) file.delete();
|
||||
if (account == i && getAccountPrefsCount() > 0) {
|
||||
if (account == i && workingAccounts() > 0) {
|
||||
List<MultiAccountItem> accounts = buildList();
|
||||
if (accounts.size() > 0)
|
||||
switchAccount(buildList().get(0).index);
|
||||
|
||||
@@ -0,0 +1,71 @@
|
||||
package ru.vtosters.lite.utils;
|
||||
|
||||
import static ru.vtosters.lite.utils.Globals.getIdentifier;
|
||||
import static ru.vtosters.lite.utils.Globals.getPrefsValue;
|
||||
|
||||
import android.content.res.Resources;
|
||||
import android.support.v4.app.FragmentTransaction;
|
||||
|
||||
public class FragAnimationKit {
|
||||
// Q
|
||||
private static final int actOpenEnter = getIdentifier("q_enter", "anim");
|
||||
private static final int actCloseExit = getIdentifier("q_pop_exit", "anim");
|
||||
// Slide
|
||||
private static final int SactOpenEnter = getIdentifier("legacy_enter", "anim");
|
||||
private static final int SactCloseExit = getIdentifier("legacy_pop_exit", "anim");
|
||||
// Fade
|
||||
private static final int FadeOpenEnter = getIdentifier("vkme_enter_slide_up", "anim");
|
||||
private static final int FadeCloseExit = getIdentifier("vkme_enter_slide_down", "anim");
|
||||
// System
|
||||
private static final Resources resources = Resources.getSystem();
|
||||
private static final int SSactOpenEnter = resources.getIdentifier("activity_open_enter", "anim","android");
|
||||
private static final int SSactCloseExit = resources.getIdentifier("activity_close_exit", "anim", "android");
|
||||
// System [task]
|
||||
private static final int SSTactOpenEnter = resources.getIdentifier("task_open_enter", "anim","android");
|
||||
private static final int SSTactCloseExit = resources.getIdentifier("task_close_exit", "anim", "android");
|
||||
|
||||
public static void animateOpen(FragmentTransaction transaction) {
|
||||
setAnimations(transaction);
|
||||
}
|
||||
|
||||
public static void animateClose(FragmentTransaction transaction) {
|
||||
setAnimations(transaction);
|
||||
}
|
||||
|
||||
public static void setAnimations(FragmentTransaction transaction) {
|
||||
if (transaction != null && !getPrefsValue("anim_rtrn_type").equals("noanim")) {
|
||||
switch (getPrefsValue("anim_rtrn_type")) {
|
||||
case "q":
|
||||
transaction.a(
|
||||
actOpenEnter,
|
||||
actCloseExit
|
||||
);
|
||||
break;
|
||||
case "fade":
|
||||
transaction.a(
|
||||
FadeOpenEnter,
|
||||
FadeCloseExit
|
||||
);
|
||||
break;
|
||||
case "slide":
|
||||
transaction.a(
|
||||
SactOpenEnter,
|
||||
SactCloseExit
|
||||
);
|
||||
break;
|
||||
case "system":
|
||||
transaction.a(
|
||||
SSactOpenEnter,
|
||||
SSactCloseExit
|
||||
);
|
||||
break;
|
||||
case "system_task":
|
||||
transaction.a(
|
||||
SSTactOpenEnter,
|
||||
SSTactCloseExit
|
||||
);
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -1,7 +1,9 @@
|
||||
package ru.vtosters.lite.utils;
|
||||
|
||||
import static androidx.core.content.ContextCompat.getDrawable;
|
||||
import static ru.vtosters.lite.utils.Preferences.getLocale;
|
||||
import static ru.vtosters.lite.utils.Preferences.preferences;
|
||||
import static ru.vtosters.lite.utils.Themes.isDarkTheme;
|
||||
|
||||
import android.app.Activity;
|
||||
import android.app.Application;
|
||||
@@ -13,23 +15,36 @@ import android.content.Intent;
|
||||
import android.content.SharedPreferences;
|
||||
import android.content.pm.PackageManager;
|
||||
import android.content.res.Resources;
|
||||
import android.graphics.Bitmap;
|
||||
import android.graphics.BitmapFactory;
|
||||
import android.graphics.Canvas;
|
||||
import android.graphics.Path;
|
||||
import android.graphics.drawable.BitmapDrawable;
|
||||
import android.graphics.drawable.Drawable;
|
||||
import android.net.ConnectivityManager;
|
||||
import android.net.NetworkInfo;
|
||||
import android.os.Build;
|
||||
import android.os.Bundle;
|
||||
import android.os.Handler;
|
||||
import android.os.StrictMode;
|
||||
import android.preference.PreferenceManager;
|
||||
import android.util.Log;
|
||||
import android.widget.Toast;
|
||||
|
||||
import androidx.annotation.NonNull;
|
||||
import androidx.annotation.StringRes;
|
||||
|
||||
import com.vk.navigation.Navigator;
|
||||
import com.vtosters.lite.UserProfile;
|
||||
import com.vtosters.lite.VKActivity;
|
||||
import com.vtosters.lite.api.ExtendedUserProfile;
|
||||
import com.vtosters.lite.auth.VKAccountManager;
|
||||
import com.vtosters.lite.im.ImEngineProvider;
|
||||
|
||||
import java.io.InputStream;
|
||||
import java.lang.reflect.Method;
|
||||
import java.net.URL;
|
||||
import java.net.URLConnection;
|
||||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
import java.util.Locale;
|
||||
@@ -91,6 +106,41 @@ public class Globals {
|
||||
return extendedUserProfile.a;
|
||||
}
|
||||
|
||||
@SuppressWarnings("deprecation")
|
||||
public static Drawable drawableFromUrl(String url) {
|
||||
try {
|
||||
URL aryURI = new URL(url);
|
||||
StrictMode.ThreadPolicy policy = new StrictMode.ThreadPolicy.Builder().permitAll().build();
|
||||
StrictMode.setThreadPolicy(policy);
|
||||
|
||||
URLConnection conn = aryURI.openConnection();
|
||||
InputStream is = conn.getInputStream();
|
||||
Bitmap bmp = BitmapFactory.decodeStream(is);
|
||||
|
||||
return new BitmapDrawable(getResources(), Bitmap.createScaledBitmap(getBitmapClippedCircle(bmp), convertDpToPixel(48), convertDpToPixel(48), true));
|
||||
} catch (Exception e) {
|
||||
return getDrawable(getContext(), com.vtosters.lite.R.drawable.libverify_ic_account_circle_white);
|
||||
}
|
||||
}
|
||||
|
||||
public static Bitmap getBitmapClippedCircle(Bitmap bitmap) {
|
||||
final int width = bitmap.getWidth();
|
||||
final int height = bitmap.getHeight();
|
||||
final Bitmap outputBitmap = Bitmap.createBitmap(width, height, Bitmap.Config.ARGB_8888);
|
||||
|
||||
final Path path = new Path();
|
||||
path.addCircle(
|
||||
(float)(width / 2)
|
||||
, (float)(height / 2)
|
||||
, (float) Math.min(width, (height / 2))
|
||||
, Path.Direction.CCW);
|
||||
|
||||
final Canvas canvas = new Canvas(outputBitmap);
|
||||
canvas.clipPath(path);
|
||||
canvas.drawBitmap(bitmap, 0, 0, null);
|
||||
return outputBitmap;
|
||||
}
|
||||
|
||||
public static void restartApplication() {
|
||||
Context ctx = getContext();
|
||||
PackageManager pm = ctx.getPackageManager();
|
||||
@@ -102,6 +152,26 @@ public class Globals {
|
||||
Runtime.getRuntime().exit(0);
|
||||
} // Application restart (works on sdk 29+ too)
|
||||
|
||||
public static void restartApplicationWithTimer() {
|
||||
Handler handler = new Handler();
|
||||
handler.postDelayed(new Runnable() {
|
||||
public void run() {
|
||||
restartApplication();
|
||||
}
|
||||
}, 500);
|
||||
}
|
||||
|
||||
public static void restartApplicationInto(Class Class) {
|
||||
Context ctx = getContext();
|
||||
PackageManager pm = ctx.getPackageManager();
|
||||
|
||||
Intent intent = new Navigator(Class).a(ctx);
|
||||
Intent mainIntent = Intent.makeRestartActivityTask(intent.getComponent());
|
||||
ctx.startActivity(mainIntent);
|
||||
|
||||
Runtime.getRuntime().exit(0);
|
||||
}
|
||||
|
||||
@NonNull
|
||||
public static Context getContext() {
|
||||
try {
|
||||
@@ -143,6 +213,10 @@ public class Globals {
|
||||
return getContext().getString(getIdentifier(resourcename, "string"));
|
||||
} // Get string via getIdentifier
|
||||
|
||||
public static String getStringDate(@StringRes int i, Object... objArr) {
|
||||
return getContext().getString(i, objArr);
|
||||
}
|
||||
|
||||
public static String getPackageName() {
|
||||
return getContext().getPackageName();
|
||||
}
|
||||
@@ -249,6 +323,8 @@ public class Globals {
|
||||
configuration.setLayoutDirection(locale);
|
||||
resources.updateConfiguration(configuration, resources.getDisplayMetrics());
|
||||
|
||||
edit().putBoolean("isdark", isDarkTheme()).commit();
|
||||
|
||||
return context;
|
||||
} // Language changer and BaseContext injector
|
||||
|
||||
|
||||
@@ -39,14 +39,14 @@ public class JsonInjectors {
|
||||
|
||||
public static String haveDonateBanner() {
|
||||
Random random = new Random();
|
||||
int randomshower = random.nextInt(7);
|
||||
int randomshower = random.nextInt(8);
|
||||
|
||||
return hasVerification() || donaterecomm() || randomshower != 1 ? "null" : "info";
|
||||
}
|
||||
|
||||
public static String haveDonateButton() {
|
||||
Random random = new Random();
|
||||
int randomshower = random.nextInt(7);
|
||||
int randomshower = random.nextInt(10);
|
||||
|
||||
return hasVerification() || donaterecomm() || randomshower != 1 ? "null" : "buttons";
|
||||
}
|
||||
|
||||
@@ -13,6 +13,8 @@ import static ru.vtosters.lite.utils.Preferences.friendsrecomm;
|
||||
import static ru.vtosters.lite.utils.Preferences.getBoolValue;
|
||||
import static ru.vtosters.lite.utils.Preferences.newfeed;
|
||||
import static ru.vtosters.lite.utils.Preferences.postsrecomm;
|
||||
import static ru.vtosters.lite.utils.Preferences.useNewSettings;
|
||||
import static ru.vtosters.lite.utils.Preferences.vkme;
|
||||
|
||||
import com.vk.apps.AppsFragment;
|
||||
import com.vk.core.preference.Preference;
|
||||
@@ -27,7 +29,6 @@ import com.vk.notifications.NotificationsContainerFragment;
|
||||
import com.vtosters.lite.fragments.GamesFragment;
|
||||
import com.vtosters.lite.fragments.PhotosFragment;
|
||||
import com.vtosters.lite.fragments.ProfileFragment;
|
||||
import com.vtosters.lite.fragments.SettingsListFragment;
|
||||
import com.vtosters.lite.fragments.d.DocumentsViewFragment;
|
||||
import com.vtosters.lite.fragments.f.FriendsFragment;
|
||||
import com.vtosters.lite.fragments.g.BirthdaysFragment;
|
||||
@@ -175,6 +176,9 @@ public class Newsfeed {
|
||||
}
|
||||
|
||||
public static long getUpdateNewsfeed(boolean refresh_timeout) {
|
||||
if (vkme()) {
|
||||
return MAX_VALUE;
|
||||
}
|
||||
switch (getPrefsValue("newsupdate")) {
|
||||
case "no_update":
|
||||
return MAX_VALUE;
|
||||
@@ -186,6 +190,9 @@ public class Newsfeed {
|
||||
}
|
||||
|
||||
public static Class getStartFragment() {
|
||||
if (vkme()) {
|
||||
return DialogsFragment.class;
|
||||
}
|
||||
switch (getPrefsValue("start_values")) {
|
||||
case "newsfeed":
|
||||
return newfeed() ? HomeFragment.class : NewsfeedFragment.class;
|
||||
@@ -202,7 +209,7 @@ public class Newsfeed {
|
||||
case "videos":
|
||||
return VideosFragment.class;
|
||||
case "settings":
|
||||
return SettingsListFragment.class;
|
||||
return useNewSettings();
|
||||
case "apps":
|
||||
return AppsFragment.class;
|
||||
case "discover":
|
||||
|
||||
@@ -1,11 +1,16 @@
|
||||
package ru.vtosters.lite.utils;
|
||||
|
||||
import static android.os.Build.VERSION;
|
||||
import static ru.vtosters.lite.f0x1d.VTVerifications.hasPrometheus;
|
||||
import static ru.vtosters.lite.f0x1d.VTVerifications.isVerified;
|
||||
import static ru.vtosters.lite.ui.fragments.multiaccount.MultiAccountManager.migrate;
|
||||
import static ru.vtosters.lite.utils.DeletedMessagesHandler.reloadMessagesList;
|
||||
import static ru.vtosters.lite.utils.Globals.fixGapps;
|
||||
import static ru.vtosters.lite.utils.Globals.getContext;
|
||||
import static ru.vtosters.lite.utils.Globals.getIdentifier;
|
||||
import static ru.vtosters.lite.utils.Globals.getPrefsValue;
|
||||
import static ru.vtosters.lite.utils.Globals.getString;
|
||||
import static ru.vtosters.lite.utils.Globals.getStringDate;
|
||||
import static ru.vtosters.lite.utils.Globals.getUserId;
|
||||
import static ru.vtosters.lite.utils.Globals.registerActivities;
|
||||
import static ru.vtosters.lite.utils.Newsfeed.setupFilters;
|
||||
@@ -13,17 +18,24 @@ import static ru.vtosters.lite.utils.OpusLoader.LoadLibrary;
|
||||
import static ru.vtosters.lite.utils.Proxy.setProxy;
|
||||
import static ru.vtosters.lite.utils.Themes.systemThemeChanger;
|
||||
|
||||
import android.annotation.SuppressLint;
|
||||
import android.app.Application;
|
||||
import android.content.Context;
|
||||
import android.content.SharedPreferences;
|
||||
import android.os.Build;
|
||||
import android.preference.PreferenceManager;
|
||||
import android.util.Log;
|
||||
|
||||
import com.vk.core.util.Screen;
|
||||
import com.vk.im.engine.models.users.UserSex;
|
||||
import com.vtosters.lite.data.Users;
|
||||
import com.vtosters.lite.fragments.SettingsListFragment;
|
||||
|
||||
import java.text.SimpleDateFormat;
|
||||
import java.util.Date;
|
||||
import java.util.Locale;
|
||||
|
||||
import ru.vtosters.lite.ui.fragments.VTSettings;
|
||||
|
||||
public class Preferences {
|
||||
public static SharedPreferences preferences = getContext().getSharedPreferences("com.vtosters.lite_preferences", Context.MODE_PRIVATE);
|
||||
|
||||
@@ -39,10 +51,19 @@ public class Preferences {
|
||||
migrate();
|
||||
reloadMessagesList();
|
||||
registerActivities(application);
|
||||
LoadLibrary("vkopustest");
|
||||
if(dev()){
|
||||
LoadLibrary("vkopustest");
|
||||
}
|
||||
systemThemeChanger();
|
||||
} // VK Init
|
||||
|
||||
public static void forceOffline() {
|
||||
if (setoffline() && !offline()) {
|
||||
Users.b();
|
||||
}
|
||||
setupFilters();
|
||||
}
|
||||
|
||||
public static boolean getBoolValue(String key, Boolean value) {
|
||||
if (preferences == null) {
|
||||
preferences = PreferenceManager.getDefaultSharedPreferences(getContext());
|
||||
@@ -50,12 +71,16 @@ public class Preferences {
|
||||
return preferences.getBoolean(key, value);
|
||||
} // Set bool by default and get value
|
||||
|
||||
public static SharedPreferences getPrefsFromFile(String filename) {
|
||||
return getContext().getSharedPreferences(filename, Context.MODE_PRIVATE);
|
||||
}
|
||||
|
||||
public static boolean opusmodule() {
|
||||
return getBoolValue("opusmodule", true);
|
||||
}
|
||||
|
||||
public static boolean systemtheme() {
|
||||
return getBoolValue("systemtheme", true);
|
||||
return getBoolValue("systemtheme", true) && VERSION.SDK_INT >= 28;
|
||||
}
|
||||
|
||||
public static boolean authorsrecomm() {
|
||||
@@ -94,8 +119,12 @@ public class Preferences {
|
||||
return getBoolValue("adsgroup", false);
|
||||
}
|
||||
|
||||
public static boolean olddock() {
|
||||
return getBoolValue("olddock", false);
|
||||
public static boolean oldicons() {
|
||||
return getBoolValue("oldicons", false);
|
||||
}
|
||||
|
||||
public static boolean vkme() {
|
||||
return getBoolValue("vkme", false);
|
||||
}
|
||||
|
||||
public static boolean adsslider() {
|
||||
@@ -118,6 +147,11 @@ public class Preferences {
|
||||
return getBoolValue("awayphp", true);
|
||||
}
|
||||
|
||||
public static Class useNewSettings() {
|
||||
boolean bool = getBoolValue("useNewSettings", true);
|
||||
return bool? VTSettings.class : SettingsListFragment.class;
|
||||
}
|
||||
|
||||
public static boolean VKUI_INJ() {
|
||||
return getBoolValue("VKUI_INJ", true);
|
||||
}
|
||||
@@ -163,7 +197,7 @@ public class Preferences {
|
||||
}
|
||||
|
||||
public static boolean dockcounter() {
|
||||
return getBoolValue("dockcounter", true);
|
||||
return getBoolValue("dockcounter", true) && !vkme();
|
||||
}
|
||||
|
||||
public static boolean feedcache() {
|
||||
@@ -174,17 +208,6 @@ public class Preferences {
|
||||
return getBoolValue("commentssorting", false);
|
||||
}
|
||||
|
||||
public static void forceOffline() {
|
||||
if (setoffline() && !offline()) {
|
||||
Users.b();
|
||||
}
|
||||
setupFilters();
|
||||
}
|
||||
|
||||
public static boolean fulltime() {
|
||||
return getBoolValue("fulltime", true);
|
||||
}
|
||||
|
||||
public static boolean gcmfix() {
|
||||
return getBoolValue("gcmfix", true);
|
||||
}
|
||||
@@ -311,15 +334,15 @@ public class Preferences {
|
||||
}
|
||||
|
||||
public static String MediacontentFix() {
|
||||
return Build.VERSION.SDK_INT >= 29 ? "date_modified DESC" : "datetaken DESC";
|
||||
return VERSION.SDK_INT >= 29 ? "date_modified DESC" : "datetaken DESC";
|
||||
} // Fix photo picker for sdk 29+
|
||||
|
||||
public static String MediacontentFix2() {
|
||||
return Build.VERSION.SDK_INT >= 29 ? "date_modified" : "datetaken";
|
||||
return VERSION.SDK_INT >= 29 ? "date_modified" : "datetaken";
|
||||
} // Fix photo picker for sdk 29+
|
||||
|
||||
public static String MediacontentFix3() {
|
||||
return Build.VERSION.SDK_INT >= 29 ? ", date_modified=" : ", dateTaken=";
|
||||
return VERSION.SDK_INT >= 29 ? ", date_modified=" : ", dateTaken=";
|
||||
} // Fix photo picker for sdk 29+
|
||||
|
||||
public static boolean color_grishka() {
|
||||
@@ -330,6 +353,10 @@ public class Preferences {
|
||||
return getBoolValue("vkme_msg", false);
|
||||
}
|
||||
|
||||
public static boolean vkme_notifs() {
|
||||
return getBoolValue("vkme_notifs", false);
|
||||
}
|
||||
|
||||
public static boolean roundedmsgs() {
|
||||
return getBoolValue("roundedmsgs", false);
|
||||
}
|
||||
@@ -338,6 +365,10 @@ public class Preferences {
|
||||
return getBoolValue("disableanimstickers", true);
|
||||
}
|
||||
|
||||
public static boolean disableSettingsSumms() {
|
||||
return getBoolValue("disableSettingsSumms", false);
|
||||
}
|
||||
|
||||
public static boolean donaterecomm() {
|
||||
return getBoolValue("donaterecomm", false);
|
||||
}
|
||||
@@ -358,6 +389,11 @@ public class Preferences {
|
||||
return isVerified(getUserId());
|
||||
}
|
||||
|
||||
public static boolean hasSpecialVerif() {
|
||||
return hasPrometheus(getUserId());
|
||||
}
|
||||
|
||||
|
||||
public static String getLocale() {
|
||||
String string = getPrefsValue("lang_value");
|
||||
|
||||
@@ -367,4 +403,38 @@ public class Preferences {
|
||||
|
||||
return string.isEmpty() ? Locale.getDefault().getLanguage() : string;
|
||||
}
|
||||
|
||||
public static boolean fulltime() {
|
||||
return getPrefsValue("dateformat").equals("noyear") || getPrefsValue("dateformat").equals("full") || getPrefsValue("dateformat").equals("noseconds");
|
||||
}
|
||||
|
||||
public static String getDateFormat() {
|
||||
switch (getPrefsValue("dateformat")) {
|
||||
case "noyear":
|
||||
return getString("fulltime2");
|
||||
case "full":
|
||||
return getString("fulltime");
|
||||
default:
|
||||
return getString("fulltime3");
|
||||
}
|
||||
}
|
||||
|
||||
@SuppressLint("SimpleDateFormat")
|
||||
public static SimpleDateFormat setDateFormat() {
|
||||
return new SimpleDateFormat(getDateFormat());
|
||||
}
|
||||
|
||||
public static String getFormattedDate(UserSex type, long time){
|
||||
SimpleDateFormat date = new SimpleDateFormat(getDateFormat(), Locale.getDefault());
|
||||
|
||||
if(!fulltime()) return null;
|
||||
|
||||
try {
|
||||
return getStringDate(type == UserSex.FEMALE ? getIdentifier("last_seen_profile_f", "string") : getIdentifier("last_seen_profile_m", "string"), date.format(new Date(time)));
|
||||
} catch (Throwable th) {
|
||||
Log.d("VTLite", "Format data error, type " + type + " , time " + time);
|
||||
th.printStackTrace();
|
||||
return null;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -200,7 +200,6 @@ public class Proxy {
|
||||
return getPrefsValue("proxy").equals("apiproxy");
|
||||
}
|
||||
|
||||
|
||||
public static boolean proxyvk() {
|
||||
return getBoolValue("proxyvk", false);
|
||||
} // Official vk proxy enforcer
|
||||
|
||||
@@ -1,17 +1,20 @@
|
||||
package ru.vtosters.lite.utils;
|
||||
|
||||
import static android.view.View.SYSTEM_UI_FLAG_LIGHT_NAVIGATION_BAR;
|
||||
import static java.util.Arrays.asList;
|
||||
import static com.vk.im.ui.themes.ImTheme.*;
|
||||
import static ru.vtosters.lite.utils.Globals.edit;
|
||||
import static ru.vtosters.lite.utils.Globals.getIdentifier;
|
||||
import static ru.vtosters.lite.utils.Globals.getPrefsValue;
|
||||
import static ru.vtosters.lite.utils.Globals.getResources;
|
||||
import static ru.vtosters.lite.utils.Preferences.color_grishka;
|
||||
import static ru.vtosters.lite.utils.Preferences.isBGStickersEnabled;
|
||||
import static ru.vtosters.lite.utils.Preferences.navbar;
|
||||
import static ru.vtosters.lite.utils.Preferences.systemtheme;
|
||||
import static ru.vtosters.lite.utils.Preferences.roundedmsgs;
|
||||
import static ru.vtosters.lite.utils.Preferences.systemtheme;
|
||||
import static ru.vtosters.lite.utils.Preferences.vkme;
|
||||
import static ru.vtosters.lite.utils.Preferences.vksans;
|
||||
|
||||
import android.app.Activity;
|
||||
import android.content.Context;
|
||||
import android.content.res.ColorStateList;
|
||||
import android.content.res.Configuration;
|
||||
@@ -32,11 +35,12 @@ import com.vk.im.ui.themes.ImTheme;
|
||||
import com.vk.im.ui.themes.ImThemeHelper;
|
||||
import com.vtosters.lite.R;
|
||||
|
||||
import java.util.Arrays;
|
||||
import java.util.List;
|
||||
|
||||
public class Themes {
|
||||
public static List<String> accentColors = asList(
|
||||
"71AAEB", "3F8AE0", "528BCC", "4986CC", "5181B8", "74A2D6", "518BCC"
|
||||
public static List<String> accentColors = Arrays.asList(
|
||||
"5692d7", "528bcc", "7aa0cc", "518bcc", "6296d0", "2f68aa", "638ebf", "5181b8", "71aaeb", "4774a8", "5baaf4", "4186c8", "add3ff", "4774a8", "718198", "5a9eff", "99a2ad", "74a2d6", "e9eef3", "dfe3e7", "eff1f3", "5c9ce6", "4986cc", "4680c2"
|
||||
);
|
||||
|
||||
public static void applyTheme(VKTheme theme, ImTheme imtheme) {
|
||||
@@ -44,6 +48,9 @@ public class Themes {
|
||||
ImThemeHelper.b.a(imtheme); // ImThemeHelper.b.a(ImTheme value) VK Theme Msg apply
|
||||
} // Apply VKTheme and ImTheme (hard applying without dynamic theme changing)
|
||||
|
||||
public static void setTheme(Activity activity) {
|
||||
VKThemeHelper.a(activity); // apply changed theme
|
||||
}
|
||||
public static boolean isDarkTheme() {
|
||||
return !VKThemeHelper.d();
|
||||
}
|
||||
@@ -126,9 +133,9 @@ public class Themes {
|
||||
public static ImTheme getImDarkTheme() {
|
||||
switch (getPrefsValue("darktheme")) {
|
||||
case "amoled":
|
||||
return roundedmsgs() ? ImTheme.VKME_AMOLED : ImTheme.VKAPP_AMOLED;
|
||||
return roundedmsgs() ? VKME_AMOLED : VKAPP_AMOLED;
|
||||
default:
|
||||
return roundedmsgs() ? ImTheme.VKME_DARK : ImTheme.VKAPP_DARK;
|
||||
return roundedmsgs() ? VKME_DARK : VKAPP_DARK;
|
||||
}
|
||||
} // Return needed theme for theme changer
|
||||
|
||||
@@ -142,7 +149,7 @@ public class Themes {
|
||||
public static ImTheme getImLightTheme() {
|
||||
switch (getPrefsValue("lighttheme")) {
|
||||
default:
|
||||
return roundedmsgs() ? ImTheme.VKME_LIGHT : ImTheme.VKAPP_LIGHT;
|
||||
return roundedmsgs() ? VKME_LIGHT : VKAPP_LIGHT;
|
||||
}
|
||||
} // Return needed theme for theme changer
|
||||
|
||||
@@ -186,8 +193,12 @@ public class Themes {
|
||||
return ColorStateList.valueOf(getAccentColor());
|
||||
} // Recolor ColorStateList to accent color
|
||||
|
||||
public static ColorStateList themeCSL(ColorStateList csl) {
|
||||
int color = csl.getDefaultColor();
|
||||
public static ColorStateList themeCSL(Context context, int color) {
|
||||
if (isColorRefAccented(color) && isAndroidMonet()) {
|
||||
return ColorStateList.valueOf(getAccentColor());
|
||||
}
|
||||
|
||||
ColorStateList csl = context.getColorStateList(color);
|
||||
try {
|
||||
int unsel = csl.getColorForState(new int[]{-android.R.attr.state_selected}, Color.BLACK);
|
||||
int sel = csl.getColorForState(new int[]{android.R.attr.state_selected}, Color.BLACK);
|
||||
@@ -225,6 +236,13 @@ public class Themes {
|
||||
return Color.argb(Color.alpha(color), red, green, blue);
|
||||
}
|
||||
|
||||
public static int fixTextColor(int resid) {
|
||||
if (resid == R.color.music_action_button_gray || resid == R.color.cool_grey || resid == R.color.accent_blue){
|
||||
return isDarkTheme()? R.color.white : R.color.cool_grey;
|
||||
}
|
||||
return resid;
|
||||
}
|
||||
|
||||
public static int halfAlpha(int src) {
|
||||
return ColorUtils.setAlphaComponent(src, 169);
|
||||
}
|
||||
@@ -234,7 +252,7 @@ public class Themes {
|
||||
}
|
||||
|
||||
public static boolean isAccentedColor(int target) {
|
||||
return accentColors.contains(hex(target).toUpperCase());
|
||||
return accentColors.contains(hex(target).toLowerCase());
|
||||
}
|
||||
|
||||
public static int getColor(Context context, int i) {
|
||||
@@ -300,24 +318,41 @@ public class Themes {
|
||||
return "images";
|
||||
}
|
||||
|
||||
public static int getNavigationHeight(int Default) {
|
||||
int VKME = R.dimen.design_bottom_sheet_peek_height_min;
|
||||
|
||||
return vkme()? VKME : Default;
|
||||
}
|
||||
|
||||
public static int getNavigationWidth(int Default) {
|
||||
int VKME = R.dimen.app_minimumsize_h;
|
||||
|
||||
return vkme()? VKME : Default;
|
||||
}
|
||||
|
||||
public static void systemThemeChanger() {
|
||||
if (isDarkTheme()){
|
||||
boolean isDarkTheme = isDarkTheme();
|
||||
|
||||
if (isDarkTheme){
|
||||
applyTheme(getDarkTheme(), getImDarkTheme());
|
||||
} else {
|
||||
applyTheme(getLightTheme(), getImLightTheme());
|
||||
}
|
||||
|
||||
if (!systemtheme()) return;
|
||||
if (!systemtheme()){
|
||||
edit().putBoolean("isdark", isDarkTheme).commit();
|
||||
return;
|
||||
}
|
||||
|
||||
int currentNightMode = getResources().getConfiguration().uiMode & Configuration.UI_MODE_NIGHT_MASK;
|
||||
switch (currentNightMode) {
|
||||
case Configuration.UI_MODE_NIGHT_UNDEFINED:
|
||||
applyTheme(getLightTheme(), getImLightTheme());
|
||||
break;
|
||||
case Configuration.UI_MODE_NIGHT_NO:
|
||||
edit().putBoolean("isdark", false).commit();
|
||||
applyTheme(getLightTheme(), getImLightTheme());
|
||||
break;
|
||||
case Configuration.UI_MODE_NIGHT_YES:
|
||||
edit().putBoolean("isdark", true).commit();
|
||||
applyTheme(getDarkTheme(), getImDarkTheme());
|
||||
break;
|
||||
}
|
||||
|
||||
@@ -58,15 +58,15 @@ body[scheme=space_gray] {
|
||||
--counter_secondary_text: #000000 !important;
|
||||
--loader_background: #000000 !important;
|
||||
--overlay_status_background: #000000 !important;
|
||||
--header_background: #19191a !important;
|
||||
--header_alternate_background: #19191a !important;
|
||||
--header_background: #000000 !important;
|
||||
--header_alternate_background: #000000 !important;
|
||||
--separator_alternate: #000000 !important;
|
||||
--segmented_control_bar_background: #000000 !important;
|
||||
--search_bar_background: #000000 !important;
|
||||
/* background */
|
||||
--background_page: #000000 !important;
|
||||
--header_background_before_blur: #19191a !important;
|
||||
--header_background_before_blur_alternate: #19191a !important;
|
||||
--header_background_before_blur: #000000 !important;
|
||||
--header_background_before_blur_alternate: #000000 !important;
|
||||
/* lighter BG (text fields) */
|
||||
--attach_picker_tab_inactive_background: #121212 !important;
|
||||
--background_keyboard: #121212 !important;
|
||||
|
||||
@@ -1,18 +1,18 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<set android:shareInterpolator="false"
|
||||
xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
<set xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:shareInterpolator="false">
|
||||
<scale
|
||||
android:interpolator="@android:anim/decelerate_interpolator"
|
||||
android:duration="@integer/abc_config_activityDefaultDur"
|
||||
android:fromXScale="0.9"
|
||||
android:fromYScale="0.9"
|
||||
android:interpolator="@android:anim/decelerate_interpolator"
|
||||
android:pivotX="50.0%"
|
||||
android:pivotY="100.0%"
|
||||
android:fromXScale="0.9"
|
||||
android:toXScale="1.0"
|
||||
android:fromYScale="0.9"
|
||||
android:toYScale="1.0" />
|
||||
<alpha
|
||||
android:interpolator="@android:anim/decelerate_interpolator"
|
||||
android:duration="@integer/abc_config_activityShortDur"
|
||||
android:fromAlpha="0.0"
|
||||
android:interpolator="@android:anim/decelerate_interpolator"
|
||||
android:toAlpha="1.0" />
|
||||
</set>
|
||||
@@ -1,9 +1,9 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<set android:shareInterpolator="false"
|
||||
xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
<set xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:shareInterpolator="false">
|
||||
<alpha
|
||||
android:interpolator="@android:anim/decelerate_interpolator"
|
||||
android:duration="@integer/abc_config_activityShortDur"
|
||||
android:fromAlpha="0.0"
|
||||
android:interpolator="@android:anim/decelerate_interpolator"
|
||||
android:toAlpha="1.0" />
|
||||
</set>
|
||||
@@ -1,9 +1,9 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<set android:shareInterpolator="false"
|
||||
xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
<set xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:shareInterpolator="false">
|
||||
<alpha
|
||||
android:interpolator="@android:anim/decelerate_interpolator"
|
||||
android:duration="@integer/abc_config_activityShortDur"
|
||||
android:fromAlpha="1.0"
|
||||
android:interpolator="@android:anim/decelerate_interpolator"
|
||||
android:toAlpha="0.0" />
|
||||
</set>
|
||||
@@ -1,18 +1,18 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<set android:shareInterpolator="false"
|
||||
xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
<set xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:shareInterpolator="false">
|
||||
<scale
|
||||
android:interpolator="@android:anim/decelerate_interpolator"
|
||||
android:duration="@integer/abc_config_activityDefaultDur"
|
||||
android:fromXScale="1.0"
|
||||
android:fromYScale="1.0"
|
||||
android:interpolator="@android:anim/decelerate_interpolator"
|
||||
android:pivotX="50.0%"
|
||||
android:pivotY="100.0%"
|
||||
android:fromXScale="1.0"
|
||||
android:toXScale="0.9"
|
||||
android:fromYScale="1.0"
|
||||
android:toYScale="0.9" />
|
||||
<alpha
|
||||
android:interpolator="@android:anim/decelerate_interpolator"
|
||||
android:duration="@integer/abc_config_activityShortDur"
|
||||
android:fromAlpha="1.0"
|
||||
android:interpolator="@android:anim/decelerate_interpolator"
|
||||
android:toAlpha="0.0" />
|
||||
</set>
|
||||
@@ -1,6 +1,6 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<alpha android:interpolator="@android:interpolator/decelerate_quad"
|
||||
<alpha xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:duration="@integer/config_tooltipAnimTime"
|
||||
android:fromAlpha="0.0"
|
||||
android:toAlpha="1.0"
|
||||
xmlns:android="http://schemas.android.com/apk/res/android" />
|
||||
android:interpolator="@android:interpolator/decelerate_quad"
|
||||
android:toAlpha="1.0" />
|
||||
@@ -1,6 +1,6 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<alpha android:interpolator="@android:interpolator/accelerate_quad"
|
||||
<alpha xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:duration="@integer/config_tooltipAnimTime"
|
||||
android:fromAlpha="1.0"
|
||||
android:toAlpha="0.0"
|
||||
xmlns:android="http://schemas.android.com/apk/res/android" />
|
||||
android:interpolator="@android:interpolator/accelerate_quad"
|
||||
android:toAlpha="0.0" />
|
||||
@@ -1,11 +1,11 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<set android:zAdjustment="normal"
|
||||
xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
<set xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:zAdjustment="normal">
|
||||
<alpha
|
||||
android:duration="300"
|
||||
android:fillBefore="true"
|
||||
android:fillAfter="true"
|
||||
android:fillBefore="true"
|
||||
android:fillEnabled="true"
|
||||
android:fromAlpha="1.0"
|
||||
android:toAlpha="1.0"
|
||||
android:fillEnabled="true" />
|
||||
android:toAlpha="1.0" />
|
||||
</set>
|
||||
@@ -1,25 +1,25 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<set android:shareInterpolator="false"
|
||||
android:zAdjustment="top"
|
||||
xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
<set xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:shareInterpolator="false"
|
||||
android:zAdjustment="top">
|
||||
<alpha
|
||||
android:interpolator="@android:interpolator/decelerate_cubic"
|
||||
android:duration="300"
|
||||
android:fillBefore="true"
|
||||
android:fillAfter="true"
|
||||
android:fillBefore="true"
|
||||
android:fillEnabled="true"
|
||||
android:fromAlpha="1.0"
|
||||
android:toAlpha="0.0"
|
||||
android:fillEnabled="true" />
|
||||
<scale
|
||||
android:interpolator="@android:interpolator/decelerate_cubic"
|
||||
android:toAlpha="0.0" />
|
||||
<scale
|
||||
android:duration="300"
|
||||
android:fillAfter="true"
|
||||
android:fillBefore="true"
|
||||
android:fillEnabled="true"
|
||||
android:fromXScale="1.0"
|
||||
android:fromYScale="1.0"
|
||||
android:interpolator="@android:interpolator/decelerate_cubic"
|
||||
android:pivotX="50.0%p"
|
||||
android:pivotY="50.0%p"
|
||||
android:fillBefore="true"
|
||||
android:fillAfter="true"
|
||||
android:fromXScale="1.0"
|
||||
android:toXScale="0.8"
|
||||
android:fromYScale="1.0"
|
||||
android:toYScale="0.8"
|
||||
android:fillEnabled="true" />
|
||||
android:toYScale="0.8" />
|
||||
</set>
|
||||
@@ -1,6 +1,6 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<set android:interpolator="@android:anim/decelerate_interpolator"
|
||||
xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
<set xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:interpolator="@android:anim/decelerate_interpolator">
|
||||
<translate
|
||||
android:duration="300"
|
||||
android:fromYDelta="100.0%p"
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<set android:interpolator="@android:anim/accelerate_interpolator"
|
||||
xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
<set xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:interpolator="@android:anim/accelerate_interpolator">
|
||||
<translate
|
||||
android:duration="300"
|
||||
android:fromYDelta="0.0%p"
|
||||
|
||||
@@ -0,0 +1,8 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<set xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:duration="225"
|
||||
android:interpolator="@android:interpolator/linear_out_slow_in">
|
||||
<translate
|
||||
android:fromYDelta="100.0%p"
|
||||
android:toYDelta="0.0" />
|
||||
</set>
|
||||
@@ -0,0 +1,8 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<set xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:duration="195"
|
||||
android:interpolator="@android:interpolator/fast_out_linear_in">
|
||||
<translate
|
||||
android:fromYDelta="0.0%p"
|
||||
android:toYDelta="100.0%p" />
|
||||
</set>
|
||||
@@ -5,15 +5,15 @@
|
||||
android:state_pressed="true">
|
||||
<objectAnimator
|
||||
android:duration="200"
|
||||
android:propertyName="translationZ"
|
||||
android:valueTo="2.0dip"
|
||||
android:valueType="floatType"
|
||||
android:propertyName="translationZ" />
|
||||
android:valueType="floatType" />
|
||||
</item>
|
||||
<item>
|
||||
<objectAnimator
|
||||
android:duration="200"
|
||||
android:propertyName="translationZ"
|
||||
android:valueTo="1.0dip"
|
||||
android:valueType="floatType"
|
||||
android:propertyName="translationZ" />
|
||||
android:valueType="floatType" />
|
||||
</item>
|
||||
</selector>
|
||||
@@ -5,15 +5,15 @@
|
||||
android:state_pressed="true">
|
||||
<objectAnimator
|
||||
android:duration="200"
|
||||
android:propertyName="translationZ"
|
||||
android:valueTo="4.0dip"
|
||||
android:valueType="floatType"
|
||||
android:propertyName="translationZ" />
|
||||
android:valueType="floatType" />
|
||||
</item>
|
||||
<item>
|
||||
<objectAnimator
|
||||
android:duration="200"
|
||||
android:propertyName="translationZ"
|
||||
android:valueTo="2.0dip"
|
||||
android:valueType="floatType"
|
||||
android:propertyName="translationZ" />
|
||||
android:valueType="floatType" />
|
||||
</item>
|
||||
</selector>
|
||||
@@ -1,7 +1,7 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<set android:interpolator="@android:anim/accelerate_decelerate_interpolator"
|
||||
<set xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:duration="@integer/bottom_sheet_slide_duration"
|
||||
xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
android:interpolator="@android:interpolator/fast_out_linear_in">
|
||||
<translate
|
||||
android:fromYDelta="20.000004%p"
|
||||
android:toYDelta="0.0" />
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<set android:interpolator="@android:anim/accelerate_interpolator"
|
||||
<set xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:duration="@integer/bottom_sheet_slide_duration"
|
||||
xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
android:interpolator="@android:interpolator/fast_out_slow_in">
|
||||
<translate
|
||||
android:fromYDelta="0.0"
|
||||
android:toYDelta="20.000004%p" />
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<translate android:fromYDelta="100.0%"
|
||||
android:toYDelta="0.0"
|
||||
xmlns:android="http://schemas.android.com/apk/res/android" />
|
||||
<translate xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:fromYDelta="100.0%"
|
||||
android:toYDelta="0.0" />
|
||||
@@ -1,4 +1,4 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<translate android:fromYDelta="0.0"
|
||||
android:toYDelta="100.0%"
|
||||
xmlns:android="http://schemas.android.com/apk/res/android" />
|
||||
<translate xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:fromYDelta="0.0"
|
||||
android:toYDelta="100.0%" />
|
||||
@@ -1,6 +1,6 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<alpha android:interpolator="@android:anim/accelerate_interpolator"
|
||||
<alpha xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:duration="200"
|
||||
android:fromAlpha="1.0"
|
||||
android:toAlpha="0.0"
|
||||
xmlns:android="http://schemas.android.com/apk/res/android" />
|
||||
android:interpolator="@android:anim/accelerate_interpolator"
|
||||
android:toAlpha="0.0" />
|
||||
@@ -0,0 +1,3 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<pathInterpolator xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:pathData="M 0,0 C 0.05, 0, 0.133333, 0.06, 0.166666, 0.4 C 0.208333, 0.82, 0.25, 1, 1, 1" />
|
||||
@@ -0,0 +1,6 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<pathInterpolator xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:controlX1="0.4"
|
||||
android:controlX2="1.0"
|
||||
android:controlY1="0.0"
|
||||
android:controlY2="1.0" />
|
||||
@@ -0,0 +1,16 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<set xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:shareInterpolator="false">
|
||||
<scale
|
||||
android:duration="@android:integer/config_shortAnimTime"
|
||||
android:fromXScale="0.9"
|
||||
android:fromYScale="0.9"
|
||||
android:pivotX="50.0%"
|
||||
android:pivotY="0.0%"
|
||||
android:toXScale="1.0"
|
||||
android:toYScale="1.0" />
|
||||
<alpha
|
||||
android:duration="@android:integer/config_shortAnimTime"
|
||||
android:fromAlpha="0.0"
|
||||
android:toAlpha="1.0" />
|
||||
</set>
|
||||
@@ -0,0 +1,12 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<set xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:duration="100">
|
||||
<translate
|
||||
android:fromYDelta="-20.000004%"
|
||||
android:interpolator="@android:anim/decelerate_interpolator"
|
||||
android:toYDelta="0.0" />
|
||||
<alpha
|
||||
android:fromAlpha="0.0"
|
||||
android:interpolator="@android:anim/decelerate_interpolator"
|
||||
android:toAlpha="1.0" />
|
||||
</set>
|
||||
@@ -0,0 +1,12 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<set xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:duration="100">
|
||||
<translate
|
||||
android:fromYDelta="20.000004%"
|
||||
android:interpolator="@android:anim/decelerate_interpolator"
|
||||
android:toYDelta="0.0" />
|
||||
<alpha
|
||||
android:fromAlpha="0.0"
|
||||
android:interpolator="@android:anim/decelerate_interpolator"
|
||||
android:toAlpha="1.0" />
|
||||
</set>
|
||||
@@ -0,0 +1,5 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<layoutAnimation xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:animation="@anim/item_animation_fall_down"
|
||||
android:animationOrder="normal"
|
||||
android:delay="14.999998%" />
|
||||
@@ -0,0 +1,5 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<layoutAnimation xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:animation="@anim/item_animation_fall_up"
|
||||
android:animationOrder="reverse"
|
||||
android:delay="14.999998%" />
|
||||
@@ -0,0 +1,10 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<set xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:shareInterpolator="false">
|
||||
<translate
|
||||
android:duration="250"
|
||||
android:fromXDelta="100.0%"
|
||||
android:fromYDelta="0.0%"
|
||||
android:toXDelta="0.0%"
|
||||
android:toYDelta="0.0%" />
|
||||
</set>
|
||||
@@ -0,0 +1,10 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<set xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:shareInterpolator="false">
|
||||
<translate
|
||||
android:duration="250"
|
||||
android:fromXDelta="0.0%"
|
||||
android:fromYDelta="0.0%"
|
||||
android:toXDelta="-100.0%"
|
||||
android:toYDelta="0.0%" />
|
||||
</set>
|
||||
@@ -0,0 +1,10 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<set xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:shareInterpolator="false">
|
||||
<translate
|
||||
android:duration="250"
|
||||
android:fromXDelta="-100.0%"
|
||||
android:fromYDelta="0.0%"
|
||||
android:toXDelta="0.0%"
|
||||
android:toYDelta="0.0%" />
|
||||
</set>
|
||||
@@ -0,0 +1,10 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<set xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:shareInterpolator="false">
|
||||
<translate
|
||||
android:duration="250"
|
||||
android:fromXDelta="0.0%"
|
||||
android:fromYDelta="0.0%"
|
||||
android:toXDelta="100.0%"
|
||||
android:toYDelta="0.0%" />
|
||||
</set>
|
||||
@@ -0,0 +1,2 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<linearInterpolator />
|
||||
@@ -0,0 +1,6 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<pathInterpolator xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:controlX1="0.0"
|
||||
android:controlX2="0.2"
|
||||
android:controlY1="0.0"
|
||||
android:controlY2="1.0" />
|
||||
@@ -1,16 +1,16 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<set android:interpolator="@android:anim/decelerate_interpolator"
|
||||
xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
<set xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:interpolator="@android:anim/decelerate_interpolator">
|
||||
<scale
|
||||
android:interpolator="@android:anim/bounce_interpolator"
|
||||
android:duration="200"
|
||||
android:fillAfter="false"
|
||||
android:fromXScale="1.0"
|
||||
android:fromYScale="1.0"
|
||||
android:interpolator="@android:anim/bounce_interpolator"
|
||||
android:pivotX="50.0%"
|
||||
android:pivotY="50.0%"
|
||||
android:fillAfter="false"
|
||||
android:repeatCount="1"
|
||||
android:repeatMode="reverse"
|
||||
android:fromXScale="1.0"
|
||||
android:toXScale="1.2"
|
||||
android:fromYScale="1.0"
|
||||
android:toYScale="1.2" />
|
||||
</set>
|
||||
@@ -1,16 +1,16 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<set android:interpolator="@android:anim/decelerate_interpolator"
|
||||
xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
<set xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:interpolator="@android:anim/decelerate_interpolator">
|
||||
<scale
|
||||
android:interpolator="@android:anim/decelerate_interpolator"
|
||||
android:duration="100"
|
||||
android:fillAfter="false"
|
||||
android:fromXScale="1.0"
|
||||
android:fromYScale="1.0"
|
||||
android:interpolator="@android:anim/decelerate_interpolator"
|
||||
android:pivotX="50.0%"
|
||||
android:pivotY="50.0%"
|
||||
android:fillAfter="false"
|
||||
android:repeatCount="1"
|
||||
android:repeatMode="reverse"
|
||||
android:fromXScale="1.0"
|
||||
android:toXScale="0.7"
|
||||
android:fromYScale="1.0"
|
||||
android:toYScale="0.7" />
|
||||
</set>
|
||||
@@ -1,7 +1,7 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<set android:interpolator="@android:anim/decelerate_interpolator"
|
||||
<set xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:duration="300"
|
||||
xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
android:interpolator="@android:anim/decelerate_interpolator">
|
||||
<translate
|
||||
android:fromYDelta="0.0"
|
||||
android:toYDelta="0.0" />
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<alpha android:interpolator="@android:anim/accelerate_interpolator"
|
||||
<alpha xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:duration="200"
|
||||
android:fromAlpha="0.0"
|
||||
android:toAlpha="1.0"
|
||||
xmlns:android="http://schemas.android.com/apk/res/android" />
|
||||
android:interpolator="@android:anim/accelerate_interpolator"
|
||||
android:toAlpha="1.0" />
|
||||
@@ -1,7 +1,7 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<alpha android:interpolator="@android:anim/accelerate_interpolator"
|
||||
<alpha xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:duration="200"
|
||||
android:fillAfter="true"
|
||||
android:fromAlpha="1.0"
|
||||
android:toAlpha="0.0"
|
||||
xmlns:android="http://schemas.android.com/apk/res/android" />
|
||||
android:interpolator="@android:anim/accelerate_interpolator"
|
||||
android:toAlpha="0.0" />
|
||||
@@ -1,3 +1,3 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<translate android:duration="50"
|
||||
xmlns:android="http://schemas.android.com/apk/res/android" />
|
||||
<translate xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:duration="50" />
|
||||
@@ -0,0 +1,11 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<set xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
<translate
|
||||
android:duration="@android:integer/config_longAnimTime"
|
||||
android:fromYDelta="0.0"
|
||||
android:toYDelta="100.0%p" />
|
||||
<alpha
|
||||
android:duration="300"
|
||||
android:fromAlpha="1.0"
|
||||
android:toAlpha="0.0" />
|
||||
</set>
|
||||
@@ -1,18 +1,18 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<set android:shareInterpolator="false"
|
||||
xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
<set xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:shareInterpolator="false">
|
||||
<scale
|
||||
android:interpolator="@android:anim/overshoot_interpolator"
|
||||
fromXScale="0.1"
|
||||
android:duration="400"
|
||||
android:fromYScale="0.1"
|
||||
android:interpolator="@android:anim/overshoot_interpolator"
|
||||
android:pivotX="20.000004%"
|
||||
android:pivotY="0.0"
|
||||
android:toXScale="1.0"
|
||||
android:fromYScale="0.1"
|
||||
android:toYScale="1.0"
|
||||
fromXScale="0.1" />
|
||||
android:toYScale="1.0" />
|
||||
<alpha
|
||||
android:interpolator="@android:anim/decelerate_interpolator"
|
||||
android:duration="400"
|
||||
android:fromAlpha="0.0"
|
||||
android:interpolator="@android:anim/decelerate_interpolator"
|
||||
android:toAlpha="1.0" />
|
||||
</set>
|
||||
@@ -1,5 +1,7 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<set xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
<set xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:interpolator="@anim/linear_out_slow_in"
|
||||
android:shareInterpolator="true">
|
||||
<translate
|
||||
android:duration="300"
|
||||
android:fromYDelta="-100.0%p"
|
||||
|
||||
@@ -1,6 +1,8 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<set android:ordering="together"
|
||||
xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
<set xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:interpolator="@anim/fast_out_linear_in"
|
||||
android:ordering="together"
|
||||
android:shareInterpolator="true">
|
||||
<translate
|
||||
android:duration="300"
|
||||
android:fromYDelta="0.0"
|
||||
|
||||
@@ -0,0 +1,25 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<set xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:shareInterpolator="false">
|
||||
<alpha
|
||||
android:duration="50"
|
||||
android:fillAfter="true"
|
||||
android:fillBefore="true"
|
||||
android:fillEnabled="true"
|
||||
android:fromAlpha="0.0"
|
||||
android:interpolator="@anim/linear"
|
||||
android:startOffset="50"
|
||||
android:toAlpha="1.0" />
|
||||
<scale
|
||||
android:duration="400"
|
||||
android:fillAfter="true"
|
||||
android:fillBefore="true"
|
||||
android:fillEnabled="true"
|
||||
android:fromXScale="0.85"
|
||||
android:fromYScale="0.85"
|
||||
android:interpolator="@anim/fast_out_extra_slow_in"
|
||||
android:pivotX="50.0%"
|
||||
android:pivotY="50.0%"
|
||||
android:toXScale="1.0"
|
||||
android:toYScale="1.0" />
|
||||
</set>
|
||||
@@ -0,0 +1,25 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<set xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:shareInterpolator="false">
|
||||
<alpha
|
||||
android:duration="87"
|
||||
android:fillAfter="true"
|
||||
android:fillBefore="true"
|
||||
android:fillEnabled="true"
|
||||
android:fromAlpha="1.0"
|
||||
android:interpolator="@anim/linear"
|
||||
android:startOffset="83"
|
||||
android:toAlpha="0.4" />
|
||||
<scale
|
||||
android:duration="400"
|
||||
android:fillAfter="true"
|
||||
android:fillBefore="true"
|
||||
android:fillEnabled="true"
|
||||
android:fromXScale="1.0"
|
||||
android:fromYScale="1.0"
|
||||
android:interpolator="@anim/fast_out_extra_slow_in"
|
||||
android:pivotX="50.0%"
|
||||
android:pivotY="50.0%"
|
||||
android:toXScale="1.05"
|
||||
android:toYScale="1.05" />
|
||||
</set>
|
||||
@@ -0,0 +1,16 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<set xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:shareInterpolator="false">
|
||||
<scale
|
||||
android:duration="400"
|
||||
android:fillAfter="true"
|
||||
android:fillBefore="true"
|
||||
android:fillEnabled="true"
|
||||
android:fromXScale="1.1"
|
||||
android:fromYScale="1.1"
|
||||
android:interpolator="@anim/fast_out_extra_slow_in"
|
||||
android:pivotX="50.0%"
|
||||
android:pivotY="50.0%"
|
||||
android:toXScale="1.0"
|
||||
android:toYScale="1.0" />
|
||||
</set>
|
||||
@@ -0,0 +1,26 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<set xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:shareInterpolator="false"
|
||||
android:zAdjustment="top">
|
||||
<alpha
|
||||
android:duration="167"
|
||||
android:fillAfter="true"
|
||||
android:fillBefore="true"
|
||||
android:fillEnabled="true"
|
||||
android:fromAlpha="1.0"
|
||||
android:interpolator="@anim/linear"
|
||||
android:startOffset="33"
|
||||
android:toAlpha="0.0" />
|
||||
<scale
|
||||
android:duration="400"
|
||||
android:fillAfter="true"
|
||||
android:fillBefore="true"
|
||||
android:fillEnabled="true"
|
||||
android:fromXScale="1.0"
|
||||
android:fromYScale="1.0"
|
||||
android:interpolator="@anim/fast_out_extra_slow_in"
|
||||
android:pivotX="50.0%"
|
||||
android:pivotY="50.0%"
|
||||
android:toXScale="0.9"
|
||||
android:toYScale="0.9" />
|
||||
</set>
|
||||
@@ -0,0 +1,16 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<set xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:shareInterpolator="false">
|
||||
<scale
|
||||
android:duration="@android:integer/config_shortAnimTime"
|
||||
android:fromXScale="1.0"
|
||||
android:fromYScale="1.0"
|
||||
android:pivotX="50.0%"
|
||||
android:pivotY="0.0%"
|
||||
android:toXScale="0.9"
|
||||
android:toYScale="0.9" />
|
||||
<alpha
|
||||
android:duration="@android:integer/config_shortAnimTime"
|
||||
android:fromAlpha="1.0"
|
||||
android:toAlpha="0.0" />
|
||||
</set>
|
||||
@@ -1,7 +1,7 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<set android:interpolator="@android:anim/decelerate_interpolator"
|
||||
<set xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:duration="200"
|
||||
xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
android:interpolator="@android:anim/decelerate_interpolator">
|
||||
<translate
|
||||
android:fromYDelta="-4.999995%"
|
||||
android:toYDelta="0.0" />
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<set android:interpolator="@android:anim/decelerate_interpolator"
|
||||
<set xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:duration="200"
|
||||
xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
android:interpolator="@android:anim/decelerate_interpolator">
|
||||
<translate
|
||||
android:fromYDelta="50.0%"
|
||||
android:toYDelta="0.0" />
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<set android:interpolator="@android:anim/decelerate_interpolator"
|
||||
<set xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:duration="200"
|
||||
xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
android:interpolator="@android:anim/decelerate_interpolator">
|
||||
<translate
|
||||
android:fromYDelta="-50.0%"
|
||||
android:toYDelta="0.0" />
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<set android:interpolator="@android:anim/decelerate_interpolator"
|
||||
<set xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:duration="200"
|
||||
xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
android:interpolator="@android:anim/decelerate_interpolator">
|
||||
<translate
|
||||
android:fromYDelta="0.0"
|
||||
android:toYDelta="50.0%" />
|
||||
|
||||
@@ -1,12 +1,12 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<set android:interpolator="@android:anim/decelerate_interpolator"
|
||||
<set xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:duration="300"
|
||||
xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
android:interpolator="@android:anim/decelerate_interpolator">
|
||||
<rotate
|
||||
android:fromDegrees="-15.0"
|
||||
android:toDegrees="0.0"
|
||||
android:pivotX="50.0%"
|
||||
android:pivotY="50.0%" />
|
||||
android:pivotY="50.0%"
|
||||
android:toDegrees="0.0" />
|
||||
<translate
|
||||
android:fromYDelta="-100.0%p"
|
||||
android:toYDelta="0.0" />
|
||||
|
||||
@@ -1,12 +1,12 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<set android:interpolator="@android:anim/accelerate_interpolator"
|
||||
<set xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:duration="300"
|
||||
xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
android:interpolator="@android:anim/accelerate_interpolator">
|
||||
<rotate
|
||||
android:fromDegrees="0.0"
|
||||
android:toDegrees="15.0"
|
||||
android:pivotX="50.0%"
|
||||
android:pivotY="50.0%" />
|
||||
android:pivotY="50.0%"
|
||||
android:toDegrees="15.0" />
|
||||
<translate
|
||||
android:fromYDelta="0.0"
|
||||
android:toYDelta="100.0%p" />
|
||||
|
||||
@@ -0,0 +1,13 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<set xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
<scale
|
||||
android:fromXScale="0.0%"
|
||||
android:fromYScale="0.0%"
|
||||
android:pivotX="50.0%"
|
||||
android:pivotY="50.0%"
|
||||
android:toXScale="100.0%"
|
||||
android:toYScale="100.0%" />
|
||||
<alpha
|
||||
android:fromAlpha="0.0"
|
||||
android:toAlpha="1.0" />
|
||||
</set>
|
||||
@@ -0,0 +1,13 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<set xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
<scale
|
||||
android:fromXScale="100.0%"
|
||||
android:fromYScale="100.0%"
|
||||
android:pivotX="50.0%"
|
||||
android:pivotY="50.0%"
|
||||
android:toXScale="0.0%"
|
||||
android:toYScale="0.0%" />
|
||||
<alpha
|
||||
android:fromAlpha="1.0"
|
||||
android:toAlpha="0.0" />
|
||||
</set>
|
||||
@@ -1,7 +1,7 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<set android:interpolator="@android:anim/decelerate_interpolator"
|
||||
<set xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:duration="400"
|
||||
xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
android:interpolator="@android:anim/decelerate_interpolator">
|
||||
<translate
|
||||
android:fromYDelta="100.0%"
|
||||
android:toYDelta="0.0" />
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<set android:interpolator="@android:interpolator/accelerate_decelerate"
|
||||
<set xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:duration="300"
|
||||
xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
android:interpolator="@android:interpolator/fast_out_slow_in">
|
||||
<translate
|
||||
android:fromYDelta="0.0"
|
||||
android:toYDelta="14.999998%" />
|
||||
|
||||
@@ -1,11 +1,11 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<set android:zAdjustment="normal"
|
||||
xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
<set xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:zAdjustment="normal">
|
||||
<translate
|
||||
android:duration="200"
|
||||
android:fillBefore="true"
|
||||
android:fillAfter="true"
|
||||
android:fillBefore="true"
|
||||
android:fillEnabled="true"
|
||||
android:fromXDelta="100.0%"
|
||||
android:toXDelta="0.0"
|
||||
android:fillEnabled="true" />
|
||||
android:toXDelta="0.0" />
|
||||
</set>
|
||||
@@ -1,6 +1,6 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<set android:duration="300"
|
||||
xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
<set xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:duration="300">
|
||||
<alpha
|
||||
android:fromAlpha="0.0"
|
||||
android:toAlpha="1.0" />
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<set android:duration="300"
|
||||
xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
<set xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:duration="300">
|
||||
<alpha
|
||||
android:fromAlpha="1.0"
|
||||
android:toAlpha="0.0" />
|
||||
|
||||
@@ -1,3 +1,6 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<accelerateInterpolator android:factor="2.0"
|
||||
xmlns:android="http://schemas.android.com/apk/res/android" />
|
||||
<pathInterpolator xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:controlX1="0.4"
|
||||
android:controlX2="0.2"
|
||||
android:controlY1="0.0"
|
||||
android:controlY2="1.0" />
|
||||
@@ -1,19 +1,19 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<set android:interpolator="@anim/vkme_enter_interpolator"
|
||||
<set xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:duration="180"
|
||||
android:shareInterpolator="true"
|
||||
android:fillBefore="true"
|
||||
android:fillAfter="true"
|
||||
android:fillBefore="true"
|
||||
android:fillEnabled="true"
|
||||
xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
android:interpolator="@anim/vkme_enter_interpolator"
|
||||
android:shareInterpolator="true">
|
||||
<translate
|
||||
android:fromYDelta="0.0%"
|
||||
android:toYDelta="3.9999962%" />
|
||||
<scale
|
||||
android:pivotX="50.0%"
|
||||
android:fromXScale="100.0%"
|
||||
android:toXScale="96.0%"
|
||||
android:fromYScale="100.0%"
|
||||
android:pivotX="50.0%"
|
||||
android:toXScale="96.0%"
|
||||
android:toYScale="96.0%" />
|
||||
<alpha
|
||||
android:fromAlpha="1.0"
|
||||
|
||||
@@ -1,19 +1,19 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<set android:interpolator="@anim/vkme_enter_interpolator"
|
||||
<set xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:duration="200"
|
||||
android:shareInterpolator="true"
|
||||
android:fillBefore="true"
|
||||
android:fillAfter="true"
|
||||
android:fillBefore="true"
|
||||
android:fillEnabled="true"
|
||||
xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
android:interpolator="@anim/vkme_enter_interpolator"
|
||||
android:shareInterpolator="true">
|
||||
<translate
|
||||
android:fromYDelta="3.9999962%"
|
||||
android:toYDelta="0.0%" />
|
||||
<scale
|
||||
android:pivotX="50.0%"
|
||||
android:fromXScale="96.0%"
|
||||
android:toXScale="100.0%"
|
||||
android:fromYScale="96.0%"
|
||||
android:pivotX="50.0%"
|
||||
android:toXScale="100.0%"
|
||||
android:toYScale="100.0%" />
|
||||
<alpha
|
||||
android:fromAlpha="0.0"
|
||||
|
||||
@@ -1,9 +1,9 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<set android:duration="200"
|
||||
android:fillBefore="true"
|
||||
<set xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:duration="200"
|
||||
android:fillAfter="false"
|
||||
android:fillEnabled="false"
|
||||
xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
android:fillBefore="true"
|
||||
android:fillEnabled="false">
|
||||
<alpha
|
||||
android:fromAlpha="1.0"
|
||||
android:toAlpha="1.0" />
|
||||
|
||||
|
Before Width: | Height: | Size: 975 B After Width: | Height: | Size: 664 B |
|
Before Width: | Height: | Size: 1.9 KiB After Width: | Height: | Size: 790 B |
|
Before Width: | Height: | Size: 758 B After Width: | Height: | Size: 462 B |
|
Before Width: | Height: | Size: 882 B After Width: | Height: | Size: 651 B |
|
Before Width: | Height: | Size: 1.8 KiB After Width: | Height: | Size: 1.5 KiB |
|
Before Width: | Height: | Size: 758 B After Width: | Height: | Size: 439 B |
|
Before Width: | Height: | Size: 1.3 KiB After Width: | Height: | Size: 552 B |
|
Before Width: | Height: | Size: 521 B After Width: | Height: | Size: 372 B |
|
Before Width: | Height: | Size: 596 B After Width: | Height: | Size: 402 B |
|
Before Width: | Height: | Size: 1.8 KiB After Width: | Height: | Size: 1.5 KiB |
|
Before Width: | Height: | Size: 1.2 KiB After Width: | Height: | Size: 874 B |
|
Before Width: | Height: | Size: 2.8 KiB After Width: | Height: | Size: 1.1 KiB |
|
Before Width: | Height: | Size: 876 B After Width: | Height: | Size: 629 B |
|
Before Width: | Height: | Size: 1.1 KiB After Width: | Height: | Size: 773 B |
|
Before Width: | Height: | Size: 2.2 KiB After Width: | Height: | Size: 2.0 KiB |
|
Before Width: | Height: | Size: 1.6 KiB After Width: | Height: | Size: 1.7 KiB |
|
Before Width: | Height: | Size: 3.6 KiB After Width: | Height: | Size: 1.6 KiB |
|
Before Width: | Height: | Size: 1.2 KiB After Width: | Height: | Size: 895 B |
|
Before Width: | Height: | Size: 1.5 KiB After Width: | Height: | Size: 1.1 KiB |
|
Before Width: | Height: | Size: 3.1 KiB After Width: | Height: | Size: 2.9 KiB |
|
Before Width: | Height: | Size: 2.0 KiB After Width: | Height: | Size: 2.5 KiB |