diff --git a/app/src/main/AndroidManifest.xml b/app/src/main/AndroidManifest.xml index b2222c8d..dea98fc2 100644 --- a/app/src/main/AndroidManifest.xml +++ b/app/src/main/AndroidManifest.xml @@ -20,9 +20,9 @@ android:name=".MainApplication" android:allowBackup="false" android:configChanges="orientation|screenSize" - android:icon="@mipmap/ic_launcher" + android:icon="@mipmap/ic_launcher_bubbles" android:label="@string/app_name" - android:roundIcon="@mipmap/ic_launcher_round" + android:roundIcon="@mipmap/ic_launcher_bubbles_round" android:supportsRtl="true" android:theme="@style/AppThemeDark" android:usesCleartextTraffic="true" @@ -56,6 +56,103 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + mastodonLists = (List) b.getSerializable(Helper.RECEIVE_MASTODON_LIST); - redrawPinned(mastodonLists); - } - if (b.getBoolean(Helper.RECEIVE_REDRAW_BOTTOM, false)) { - bottomMenu = new BottomMenu(BaseMainActivity.this).hydrate(currentAccount, binding.bottomNavView); - if (bottomMenu != null) { - //ManageClick on bottom menu items - if (binding.bottomNavView.findViewById(R.id.nav_home) != null) { - binding.bottomNavView.findViewById(R.id.nav_home).setOnLongClickListener(view -> { - int position = BottomMenu.getPosition(bottomMenu, R.id.nav_home); - if (position >= 0) { - manageFilters(position); - } - return false; - }); - } - if (binding.bottomNavView.findViewById(R.id.nav_local) != null) { - binding.bottomNavView.findViewById(R.id.nav_local).setOnLongClickListener(view -> { - int position = BottomMenu.getPosition(bottomMenu, R.id.nav_local); - if (position >= 0) { - manageFilters(position); - } - return false; - }); - } - if (binding.bottomNavView.findViewById(R.id.nav_public) != null) { - binding.bottomNavView.findViewById(R.id.nav_public).setOnLongClickListener(view -> { - int position = BottomMenu.getPosition(bottomMenu, R.id.nav_public); - if (position >= 0) { - manageFilters(position); - } - return false; - }); - } - binding.bottomNavView.setOnItemSelectedListener(item -> { - int itemId = item.getItemId(); - int position = BottomMenu.getPosition(bottomMenu, itemId); - if (position >= 0) { - if (binding.viewPager.getCurrentItem() == position) { - scrollToTop(); - } else { - binding.viewPager.setCurrentItem(position, false); - } - } - return true; - }); - } - } else if (b.getBoolean(Helper.RECEIVE_RECREATE_ACTIVITY, false)) { - Cyanea.getInstance().edit().apply().recreate(BaseMainActivity.this); - } else if (b.getBoolean(Helper.RECEIVE_NEW_MESSAGE, false)) { - Status statusSent = (Status) b.getSerializable(Helper.RECEIVE_STATUS_ACTION); - Snackbar.make(binding.displaySnackBar, getString(R.string.message_has_been_sent), Snackbar.LENGTH_LONG) - .setAction(getString(R.string.display), view -> { - Intent intentContext = new Intent(BaseMainActivity.this, ContextActivity.class); - intentContext.putExtra(Helper.ARG_STATUS, statusSent); - intentContext.addFlags(Intent.FLAG_ACTIVITY_NEW_TASK); - startActivity(intentContext); - }) - .setTextColor(ThemeHelper.getAttColor(BaseMainActivity.this, R.attr.mTextColor)) - .setActionTextColor(ContextCompat.getColor(BaseMainActivity.this, R.color.cyanea_accent_reference)) - .setBackgroundTint(ContextCompat.getColor(BaseMainActivity.this, R.color.cyanea_primary_dark_reference)) - .show(); - } - } - } - }; - private NetworkStateReceiver networkStateReceiver; - private boolean headerMenuOpen; - protected abstract void rateThisApp(); - - @Override - protected void onNewIntent(Intent intent) { - super.onNewIntent(intent); - mamageNewIntent(intent); - } - - /** - * Open notifications tab when coming from a notification device - * - * @param intent - Intent intent that will be cancelled - */ - private void openNotifications(Intent intent) { - final Handler handler = new Handler(); - handler.postDelayed(() -> { - SharedPreferences sharedpreferences = PreferenceManager.getDefaultSharedPreferences(BaseMainActivity.this); - boolean singleBar = sharedpreferences.getBoolean(getString(R.string.SET_USE_SINGLE_TOPBAR), false); - if (!singleBar) { - binding.bottomNavView.setSelectedItemId(R.id.nav_notifications); - } else { - int position = 0; - for (int i = 0; i < binding.tabLayout.getTabCount(); i++) { - TabLayout.Tab tab = binding.tabLayout.getTabAt(i); - if (tab != null && tab.getTag() != null && tab.getTag().equals(Timeline.TimeLineEnum.NOTIFICATION.getValue())) { - break; - } - position++; - } - binding.viewPager.setCurrentItem(position); - } - }, 1000); - intent.removeExtra(Helper.INTENT_ACTION); - } - - - @SuppressLint("ApplySharedPref") - private void mamageNewIntent(Intent intent) { - if (intent == null) - return; - String action = intent.getAction(); - String type = intent.getType(); - Bundle extras = intent.getExtras(); - String userIdIntent, instanceIntent; - if (extras != null && extras.containsKey(Helper.INTENT_ACTION)) { - userIdIntent = extras.getString(Helper.PREF_KEY_ID); //Id of the account in the intent - instanceIntent = extras.getString(Helper.PREF_INSTANCE); - if (extras.getInt(Helper.INTENT_ACTION) == Helper.NOTIFICATION_INTENT) { - if (userIdIntent != null && instanceIntent != null && userIdIntent.equals(currentUserID) && instanceIntent.equals(currentInstance)) { - openNotifications(intent); - } else { - try { - BaseAccount account = new Account(BaseMainActivity.this).getUniqAccount(userIdIntent, instanceIntent); - SharedPreferences sharedpreferences = PreferenceManager.getDefaultSharedPreferences(BaseMainActivity.this); - headerMenuOpen = false; - Toasty.info(BaseMainActivity.this, getString(R.string.toast_account_changed, "@" + account.mastodon_account.acct + "@" + account.instance), Toasty.LENGTH_LONG).show(); - BaseMainActivity.currentToken = account.token; - BaseMainActivity.currentUserID = account.user_id; - api = account.api; - SharedPreferences.Editor editor = sharedpreferences.edit(); - editor.putString(PREF_USER_TOKEN, account.token); - editor.commit(); - Intent mainActivity = new Intent(this, MainActivity.class); - mainActivity.putExtra(Helper.INTENT_ACTION, Helper.OPEN_NOTIFICATION); - startActivity(mainActivity); - finish(); - } catch (DBException e) { - e.printStackTrace(); - } - } - } else if (extras.getInt(Helper.INTENT_ACTION) == Helper.OPEN_NOTIFICATION) { - openNotifications(intent); - } - } else if (Intent.ACTION_SEND.equals(action) && type != null) { - if ("text/plain".equals(type)) { - final String[] url = {null}; - String sharedSubject = intent.getStringExtra(Intent.EXTRA_SUBJECT); - String sharedText = intent.getStringExtra(Intent.EXTRA_TEXT); - //SharedPreferences sharedpreferences = PreferenceManager.getDefaultSharedPreferences(BaseMainActivity.this); - //boolean shouldRetrieveMetaData = sharedpreferences.getBoolean(getString(R.string.SET_RETRIEVE_METADATA_IF_URL_FROM_EXTERAL), true); - if (sharedText != null) { - /* Some apps don't send the URL as the first part of the EXTRA_TEXT, - the BBC News app being one such, in this case find where the URL - is and strip that out into sharedText. - */ - Matcher matcher; - matcher = Patterns.WEB_URL.matcher(sharedText); - int count = 0; - while (matcher.find()) { - int matchStart = matcher.start(1); - int matchEnd = matcher.end(); - if (matchStart < matchEnd && sharedText.length() >= matchEnd) { - url[0] = sharedText.substring(matchStart, matchEnd); - count++; - } - } - SharedPreferences sharedpreferences = PreferenceManager.getDefaultSharedPreferences(BaseMainActivity.this); - boolean fetchSharedMedia = sharedpreferences.getBoolean(getString(R.string.SET_RETRIEVE_METADATA_IF_URL_FROM_EXTERAL), true); - boolean fetchShareContent = sharedpreferences.getBoolean(getString(R.string.SET_SHARE_DETAILS), true); - if (url[0] != null && count == 1 && (fetchShareContent || fetchSharedMedia)) { - new Thread(() -> { - if (url[0].startsWith("www.")) - url[0] = "http://" + url[0]; - Matcher matcherPattern = Patterns.WEB_URL.matcher(url[0]); - String potentialUrl = null; - while (matcherPattern.find()) { - int matchStart = matcherPattern.start(1); - int matchEnd = matcherPattern.end(); - if (matchStart < matchEnd && url[0].length() >= matchEnd) - potentialUrl = url[0].substring(matchStart, matchEnd); - } - // If we actually have a URL then make use of it. - if (potentialUrl != null && potentialUrl.length() > 0) { - Pattern titlePattern = Pattern.compile("]*property=[\"']og:title[\"'] [^>]*content=[\"']([^'^\"]+?)[\"'][^>]*>"); - Pattern descriptionPattern = Pattern.compile("]*property=[\"']og:description[\"'] [^>]*content=[\"']([^'^\"]+?)[\"'][^>]*>"); - Pattern imagePattern = Pattern.compile("]*property=[\"']og:image[\"'] [^>]*content=[\"']([^'^\"]+?)[\"'][^>]*>"); - - try { - OkHttpClient client = new OkHttpClient.Builder() - .connectTimeout(10, TimeUnit.SECONDS) - .writeTimeout(10, TimeUnit.SECONDS) - .proxy(Helper.getProxy(getApplication().getApplicationContext())) - .readTimeout(10, TimeUnit.SECONDS).build(); - Request request = new Request.Builder() - .url(potentialUrl) - .build(); - client.newCall(request).enqueue(new Callback() { - @Override - public void onFailure(@NonNull Call call, @NonNull IOException e) { - e.printStackTrace(); - runOnUiThread(() -> Toasty.warning(BaseMainActivity.this, getString(R.string.toast_error), Toast.LENGTH_LONG).show()); - } - - @Override - public void onResponse(@NonNull Call call, @NonNull final Response response) { - if (response.isSuccessful()) { - try { - String data = response.body().string(); - Matcher matcherTitle; - matcherTitle = titlePattern.matcher(data); - Matcher matcherDescription = descriptionPattern.matcher(data); - Matcher matcherImage = imagePattern.matcher(data); - String titleEncoded = null; - String descriptionEncoded = null; - if (fetchShareContent) { - while (matcherTitle.find()) - titleEncoded = matcherTitle.group(1); - while (matcherDescription.find()) - descriptionEncoded = matcherDescription.group(1); - } - String image = null; - if (fetchSharedMedia) { - while (matcherImage.find()) - image = matcherImage.group(1); - } - String title = null; - String description = null; - if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.N) { - if (titleEncoded != null) - title = Html.fromHtml(titleEncoded, Html.FROM_HTML_MODE_LEGACY).toString(); - if (descriptionEncoded != null) - description = Html.fromHtml(descriptionEncoded, Html.FROM_HTML_MODE_LEGACY).toString(); - } else { - if (titleEncoded != null) - title = Html.fromHtml(titleEncoded).toString(); - if (descriptionEncoded != null) - description = Html.fromHtml(descriptionEncoded).toString(); - } - String finalImage = image; - String finalTitle = title; - String finalDescription = description; - - - runOnUiThread(() -> { - Bundle b = new Bundle(); - b.putString(Helper.ARG_SHARE_URL, url[0]); - b.putString(Helper.ARG_SHARE_URL_MEDIA, finalImage); - b.putString(Helper.ARG_SHARE_TITLE, finalTitle); - b.putString(Helper.ARG_SHARE_DESCRIPTION, finalDescription); - b.putString(Helper.ARG_SHARE_SUBJECT, sharedSubject); - b.putString(Helper.ARG_SHARE_CONTENT, sharedText); - CrossActionHelper.doCrossShare(BaseMainActivity.this, b); - }); - } catch (Exception e) { - e.printStackTrace(); - } - } else { - runOnUiThread(() -> Toasty.warning(BaseMainActivity.this, getString(R.string.toast_error), Toast.LENGTH_LONG).show()); - } - } - }); - } catch (IndexOutOfBoundsException e) { - Toasty.warning(BaseMainActivity.this, getString(R.string.toast_error), Toast.LENGTH_LONG).show(); - } - - } - }).start(); - } else { - Bundle b = new Bundle(); - b.putString(Helper.ARG_SHARE_TITLE, sharedSubject); - b.putString(Helper.ARG_SHARE_DESCRIPTION, sharedText); - CrossActionHelper.doCrossShare(BaseMainActivity.this, b); - } - - - } - } else if (type.startsWith("image/") || type.startsWith("video/")) { - Uri imageUri = intent.getParcelableExtra(Intent.EXTRA_STREAM); - if (imageUri != null) { - Bundle b = new Bundle(); - b.putParcelable(Helper.ARG_SHARE_URI, imageUri); - CrossActionHelper.doCrossShare(BaseMainActivity.this, b); - } else { - Toasty.warning(BaseMainActivity.this, getString(R.string.toast_error), Toast.LENGTH_LONG).show(); - } - } - } else if (Intent.ACTION_SEND_MULTIPLE.equals(action) && type != null) { - if (type.startsWith("image/") || type.startsWith("video/")) { - ArrayList imageList = intent.getParcelableArrayListExtra(Intent.EXTRA_STREAM); - if (imageList != null) { - Bundle b = new Bundle(); - b.putParcelableArrayList(Helper.ARG_SHARE_URI_LIST, imageList); - CrossActionHelper.doCrossShare(BaseMainActivity.this, b); - } else { - Toasty.warning(BaseMainActivity.this, getString(R.string.toast_error), Toast.LENGTH_LONG).show(); - } - } - } - - } + public static iconLauncher mLauncher = iconLauncher.BUBBLES; @Override protected void onCreate(Bundle savedInstanceState) { @@ -516,7 +213,45 @@ public abstract class BaseMainActivity extends BaseActivity implements NetworkSt } else { BaseMainActivity.currentToken = sharedpreferences.getString(Helper.PREF_USER_TOKEN, null); } - mamageNewIntent(getIntent()); + + Intent intentIni = getIntent(); + PackageManager pm = getPackageManager(); + try { + if (intentIni != null && intentIni.getComponent() != null) { + ActivityInfo ai = pm.getActivityInfo(intentIni.getComponent(), PackageManager.GET_META_DATA); + String icon; + Bundle b = ai.metaData; + if (b != null) { + icon = b.getString("icon"); + if (icon != null) { + switch (icon) { + case "fediverse": + mLauncher = iconLauncher.FEDIVERSE; + break; + case "hero": + mLauncher = iconLauncher.HERO; + break; + case "atom": + mLauncher = iconLauncher.ATOM; + break; + case "braincrash": + mLauncher = iconLauncher.BRAINCRASH; + break; + default: + mLauncher = iconLauncher.BUBBLES; + } + SharedPreferences.Editor editor = sharedpreferences.edit(); + editor.putString(getString(R.string.SET_LOGO_LAUNCHER), icon); + editor.apply(); + } + } + } + } catch (PackageManager.NameNotFoundException e) { + e.printStackTrace(); + } + + + mamageNewIntent(intentIni); ThemeHelper.initiliazeColors(BaseMainActivity.this); filterFetched = false; networkStateReceiver = new NetworkStateReceiver(); @@ -961,6 +696,323 @@ public abstract class BaseMainActivity extends BaseActivity implements NetworkSt } } + private Pinned pinned; + private BottomMenu bottomMenu; + private final BroadcastReceiver broadcast_data = new BroadcastReceiver() { + @Override + public void onReceive(Context context, Intent intent) { + Bundle b = intent.getExtras(); + if (b != null) { + if (b.getBoolean(Helper.RECEIVE_REDRAW_TOPBAR, false)) { + List mastodonLists = (List) b.getSerializable(Helper.RECEIVE_MASTODON_LIST); + redrawPinned(mastodonLists); + } + if (b.getBoolean(Helper.RECEIVE_REDRAW_BOTTOM, false)) { + bottomMenu = new BottomMenu(BaseMainActivity.this).hydrate(currentAccount, binding.bottomNavView); + if (bottomMenu != null) { + //ManageClick on bottom menu items + if (binding.bottomNavView.findViewById(R.id.nav_home) != null) { + binding.bottomNavView.findViewById(R.id.nav_home).setOnLongClickListener(view -> { + int position = BottomMenu.getPosition(bottomMenu, R.id.nav_home); + if (position >= 0) { + manageFilters(position); + } + return false; + }); + } + if (binding.bottomNavView.findViewById(R.id.nav_local) != null) { + binding.bottomNavView.findViewById(R.id.nav_local).setOnLongClickListener(view -> { + int position = BottomMenu.getPosition(bottomMenu, R.id.nav_local); + if (position >= 0) { + manageFilters(position); + } + return false; + }); + } + if (binding.bottomNavView.findViewById(R.id.nav_public) != null) { + binding.bottomNavView.findViewById(R.id.nav_public).setOnLongClickListener(view -> { + int position = BottomMenu.getPosition(bottomMenu, R.id.nav_public); + if (position >= 0) { + manageFilters(position); + } + return false; + }); + } + binding.bottomNavView.setOnItemSelectedListener(item -> { + int itemId = item.getItemId(); + int position = BottomMenu.getPosition(bottomMenu, itemId); + if (position >= 0) { + if (binding.viewPager.getCurrentItem() == position) { + scrollToTop(); + } else { + binding.viewPager.setCurrentItem(position, false); + } + } + return true; + }); + } + } else if (b.getBoolean(Helper.RECEIVE_RECREATE_ACTIVITY, false)) { + Cyanea.getInstance().edit().apply().recreate(BaseMainActivity.this); + } else if (b.getBoolean(Helper.RECEIVE_NEW_MESSAGE, false)) { + Status statusSent = (Status) b.getSerializable(Helper.RECEIVE_STATUS_ACTION); + Snackbar.make(binding.displaySnackBar, getString(R.string.message_has_been_sent), Snackbar.LENGTH_LONG) + .setAction(getString(R.string.display), view -> { + Intent intentContext = new Intent(BaseMainActivity.this, ContextActivity.class); + intentContext.putExtra(Helper.ARG_STATUS, statusSent); + intentContext.addFlags(Intent.FLAG_ACTIVITY_NEW_TASK); + startActivity(intentContext); + }) + .setTextColor(ThemeHelper.getAttColor(BaseMainActivity.this, R.attr.mTextColor)) + .setActionTextColor(ContextCompat.getColor(BaseMainActivity.this, R.color.cyanea_accent_reference)) + .setBackgroundTint(ContextCompat.getColor(BaseMainActivity.this, R.color.cyanea_primary_dark_reference)) + .show(); + } + } + } + }; + private NetworkStateReceiver networkStateReceiver; + private boolean headerMenuOpen; + + protected abstract void rateThisApp(); + + @Override + protected void onNewIntent(Intent intent) { + super.onNewIntent(intent); + mamageNewIntent(intent); + } + + /** + * Open notifications tab when coming from a notification device + * + * @param intent - Intent intent that will be cancelled + */ + private void openNotifications(Intent intent) { + final Handler handler = new Handler(); + handler.postDelayed(() -> { + SharedPreferences sharedpreferences = PreferenceManager.getDefaultSharedPreferences(BaseMainActivity.this); + boolean singleBar = sharedpreferences.getBoolean(getString(R.string.SET_USE_SINGLE_TOPBAR), false); + if (!singleBar) { + binding.bottomNavView.setSelectedItemId(R.id.nav_notifications); + } else { + int position = 0; + for (int i = 0; i < binding.tabLayout.getTabCount(); i++) { + TabLayout.Tab tab = binding.tabLayout.getTabAt(i); + if (tab != null && tab.getTag() != null && tab.getTag().equals(Timeline.TimeLineEnum.NOTIFICATION.getValue())) { + break; + } + position++; + } + binding.viewPager.setCurrentItem(position); + } + }, 1000); + intent.removeExtra(Helper.INTENT_ACTION); + } + + + @SuppressLint("ApplySharedPref") + private void mamageNewIntent(Intent intent) { + if (intent == null) + return; + String action = intent.getAction(); + String type = intent.getType(); + Bundle extras = intent.getExtras(); + String userIdIntent, instanceIntent; + if (extras != null && extras.containsKey(Helper.INTENT_ACTION)) { + userIdIntent = extras.getString(Helper.PREF_KEY_ID); //Id of the account in the intent + instanceIntent = extras.getString(Helper.PREF_INSTANCE); + if (extras.getInt(Helper.INTENT_ACTION) == Helper.NOTIFICATION_INTENT) { + if (userIdIntent != null && instanceIntent != null && userIdIntent.equals(currentUserID) && instanceIntent.equals(currentInstance)) { + openNotifications(intent); + } else { + try { + BaseAccount account = new Account(BaseMainActivity.this).getUniqAccount(userIdIntent, instanceIntent); + SharedPreferences sharedpreferences = PreferenceManager.getDefaultSharedPreferences(BaseMainActivity.this); + headerMenuOpen = false; + Toasty.info(BaseMainActivity.this, getString(R.string.toast_account_changed, "@" + account.mastodon_account.acct + "@" + account.instance), Toasty.LENGTH_LONG).show(); + BaseMainActivity.currentToken = account.token; + BaseMainActivity.currentUserID = account.user_id; + api = account.api; + SharedPreferences.Editor editor = sharedpreferences.edit(); + editor.putString(PREF_USER_TOKEN, account.token); + editor.commit(); + Intent mainActivity = new Intent(this, MainActivity.class); + mainActivity.putExtra(Helper.INTENT_ACTION, Helper.OPEN_NOTIFICATION); + startActivity(mainActivity); + finish(); + } catch (DBException e) { + e.printStackTrace(); + } + } + } else if (extras.getInt(Helper.INTENT_ACTION) == Helper.OPEN_NOTIFICATION) { + openNotifications(intent); + } + } else if (Intent.ACTION_SEND.equals(action) && type != null) { + if ("text/plain".equals(type)) { + final String[] url = {null}; + String sharedSubject = intent.getStringExtra(Intent.EXTRA_SUBJECT); + String sharedText = intent.getStringExtra(Intent.EXTRA_TEXT); + //SharedPreferences sharedpreferences = PreferenceManager.getDefaultSharedPreferences(BaseMainActivity.this); + //boolean shouldRetrieveMetaData = sharedpreferences.getBoolean(getString(R.string.SET_RETRIEVE_METADATA_IF_URL_FROM_EXTERAL), true); + if (sharedText != null) { + /* Some apps don't send the URL as the first part of the EXTRA_TEXT, + the BBC News app being one such, in this case find where the URL + is and strip that out into sharedText. + */ + Matcher matcher; + matcher = Patterns.WEB_URL.matcher(sharedText); + int count = 0; + while (matcher.find()) { + int matchStart = matcher.start(1); + int matchEnd = matcher.end(); + if (matchStart < matchEnd && sharedText.length() >= matchEnd) { + url[0] = sharedText.substring(matchStart, matchEnd); + count++; + } + } + SharedPreferences sharedpreferences = PreferenceManager.getDefaultSharedPreferences(BaseMainActivity.this); + boolean fetchSharedMedia = sharedpreferences.getBoolean(getString(R.string.SET_RETRIEVE_METADATA_IF_URL_FROM_EXTERAL), true); + boolean fetchShareContent = sharedpreferences.getBoolean(getString(R.string.SET_SHARE_DETAILS), true); + if (url[0] != null && count == 1 && (fetchShareContent || fetchSharedMedia)) { + new Thread(() -> { + if (url[0].startsWith("www.")) + url[0] = "http://" + url[0]; + Matcher matcherPattern = Patterns.WEB_URL.matcher(url[0]); + String potentialUrl = null; + while (matcherPattern.find()) { + int matchStart = matcherPattern.start(1); + int matchEnd = matcherPattern.end(); + if (matchStart < matchEnd && url[0].length() >= matchEnd) + potentialUrl = url[0].substring(matchStart, matchEnd); + } + // If we actually have a URL then make use of it. + if (potentialUrl != null && potentialUrl.length() > 0) { + Pattern titlePattern = Pattern.compile("]*property=[\"']og:title[\"'] [^>]*content=[\"']([^'^\"]+?)[\"'][^>]*>"); + Pattern descriptionPattern = Pattern.compile("]*property=[\"']og:description[\"'] [^>]*content=[\"']([^'^\"]+?)[\"'][^>]*>"); + Pattern imagePattern = Pattern.compile("]*property=[\"']og:image[\"'] [^>]*content=[\"']([^'^\"]+?)[\"'][^>]*>"); + + try { + OkHttpClient client = new OkHttpClient.Builder() + .connectTimeout(10, TimeUnit.SECONDS) + .writeTimeout(10, TimeUnit.SECONDS) + .proxy(Helper.getProxy(getApplication().getApplicationContext())) + .readTimeout(10, TimeUnit.SECONDS).build(); + Request request = new Request.Builder() + .url(potentialUrl) + .build(); + client.newCall(request).enqueue(new Callback() { + @Override + public void onFailure(@NonNull Call call, @NonNull IOException e) { + e.printStackTrace(); + runOnUiThread(() -> Toasty.warning(BaseMainActivity.this, getString(R.string.toast_error), Toast.LENGTH_LONG).show()); + } + + @Override + public void onResponse(@NonNull Call call, @NonNull final Response response) { + if (response.isSuccessful()) { + try { + String data = response.body().string(); + Matcher matcherTitle; + matcherTitle = titlePattern.matcher(data); + Matcher matcherDescription = descriptionPattern.matcher(data); + Matcher matcherImage = imagePattern.matcher(data); + String titleEncoded = null; + String descriptionEncoded = null; + if (fetchShareContent) { + while (matcherTitle.find()) + titleEncoded = matcherTitle.group(1); + while (matcherDescription.find()) + descriptionEncoded = matcherDescription.group(1); + } + String image = null; + if (fetchSharedMedia) { + while (matcherImage.find()) + image = matcherImage.group(1); + } + String title = null; + String description = null; + if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.N) { + if (titleEncoded != null) + title = Html.fromHtml(titleEncoded, Html.FROM_HTML_MODE_LEGACY).toString(); + if (descriptionEncoded != null) + description = Html.fromHtml(descriptionEncoded, Html.FROM_HTML_MODE_LEGACY).toString(); + } else { + if (titleEncoded != null) + title = Html.fromHtml(titleEncoded).toString(); + if (descriptionEncoded != null) + description = Html.fromHtml(descriptionEncoded).toString(); + } + String finalImage = image; + String finalTitle = title; + String finalDescription = description; + + + runOnUiThread(() -> { + Bundle b = new Bundle(); + b.putString(Helper.ARG_SHARE_URL, url[0]); + b.putString(Helper.ARG_SHARE_URL_MEDIA, finalImage); + b.putString(Helper.ARG_SHARE_TITLE, finalTitle); + b.putString(Helper.ARG_SHARE_DESCRIPTION, finalDescription); + b.putString(Helper.ARG_SHARE_SUBJECT, sharedSubject); + b.putString(Helper.ARG_SHARE_CONTENT, sharedText); + CrossActionHelper.doCrossShare(BaseMainActivity.this, b); + }); + } catch (Exception e) { + e.printStackTrace(); + } + } else { + runOnUiThread(() -> Toasty.warning(BaseMainActivity.this, getString(R.string.toast_error), Toast.LENGTH_LONG).show()); + } + } + }); + } catch (IndexOutOfBoundsException e) { + Toasty.warning(BaseMainActivity.this, getString(R.string.toast_error), Toast.LENGTH_LONG).show(); + } + + } + }).start(); + } else { + Bundle b = new Bundle(); + b.putString(Helper.ARG_SHARE_TITLE, sharedSubject); + b.putString(Helper.ARG_SHARE_DESCRIPTION, sharedText); + CrossActionHelper.doCrossShare(BaseMainActivity.this, b); + } + + + } + } else if (type.startsWith("image/") || type.startsWith("video/")) { + Uri imageUri = intent.getParcelableExtra(Intent.EXTRA_STREAM); + if (imageUri != null) { + Bundle b = new Bundle(); + b.putParcelable(Helper.ARG_SHARE_URI, imageUri); + CrossActionHelper.doCrossShare(BaseMainActivity.this, b); + } else { + Toasty.warning(BaseMainActivity.this, getString(R.string.toast_error), Toast.LENGTH_LONG).show(); + } + } + } else if (Intent.ACTION_SEND_MULTIPLE.equals(action) && type != null) { + if (type.startsWith("image/") || type.startsWith("video/")) { + ArrayList imageList = intent.getParcelableArrayListExtra(Intent.EXTRA_STREAM); + if (imageList != null) { + Bundle b = new Bundle(); + b.putParcelableArrayList(Helper.ARG_SHARE_URI_LIST, imageList); + CrossActionHelper.doCrossShare(BaseMainActivity.this, b); + } else { + Toasty.warning(BaseMainActivity.this, getString(R.string.toast_error), Toast.LENGTH_LONG).show(); + } + } + } + + } + + public enum iconLauncher { + BUBBLES, + FEDIVERSE, + HERO, + ATOM, + BRAINCRASH, + MASTALAB + } + private void manageFilters(int position) { View view = binding.bottomNavView.findViewById(R.id.nav_home); diff --git a/app/src/main/java/app/fedilab/android/helper/Helper.java b/app/src/main/java/app/fedilab/android/helper/Helper.java index 9948371b..8a675be5 100644 --- a/app/src/main/java/app/fedilab/android/helper/Helper.java +++ b/app/src/main/java/app/fedilab/android/helper/Helper.java @@ -16,6 +16,7 @@ package app.fedilab.android.helper; import static android.content.Context.DOWNLOAD_SERVICE; import static app.fedilab.android.BaseMainActivity.currentAccount; +import static app.fedilab.android.helper.LogoHelper.getNotificationIcon; import static app.fedilab.android.webview.ProxyHelper.setProxy; import android.annotation.SuppressLint; @@ -1475,7 +1476,7 @@ public class Helper { channelTitle = context.getString(R.string.channel_notif_boost); } NotificationCompat.Builder notificationBuilder = new NotificationCompat.Builder(context, channelId) - .setSmallIcon(R.drawable.ic_notification).setTicker(message); + .setSmallIcon(getNotificationIcon(context)).setTicker(message); /* if (notifType == NotifType.MENTION) { if (message.length() > 500) { message = message.substring(0, 499) + "…"; @@ -1547,7 +1548,7 @@ public class Helper { .setContentText(channelTitle) .setContentIntent(pIntent) .setLargeIcon(icon) - .setSmallIcon(R.drawable.ic_notification) + .setSmallIcon(getNotificationIcon(context)) .setStyle(new NotificationCompat.BigTextStyle().bigText(message)) .setGroup(account.mastodon_account != null ? account.mastodon_account.username + "@" + account.instance : "" + "@" + account.instance) .setGroupSummary(true) diff --git a/app/src/main/java/app/fedilab/android/helper/LogoHelper.java b/app/src/main/java/app/fedilab/android/helper/LogoHelper.java new file mode 100644 index 00000000..1a009e78 --- /dev/null +++ b/app/src/main/java/app/fedilab/android/helper/LogoHelper.java @@ -0,0 +1,107 @@ +package app.fedilab.android.helper; +/* Copyright 2022 Thomas Schneider + * + * This file is a part of Fedilab + * + * This program is free software; you can redistribute it and/or modify it under the terms of the + * GNU General Public License as published by the Free Software Foundation; either version 3 of the + * License, or (at your option) any later version. + * + * Fedilab is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even + * the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General + * Public License for more details. + * + * You should have received a copy of the GNU General Public License along with Fedilab; if not, + * see . */ + +import static app.fedilab.android.BaseMainActivity.mLauncher; + +import android.content.Context; +import android.content.SharedPreferences; + +import androidx.preference.PreferenceManager; + +import app.fedilab.android.BaseMainActivity; +import app.fedilab.android.R; + +public class LogoHelper { + + + public static int getNotificationIcon(Context context) { + final SharedPreferences sharedpreferences = PreferenceManager.getDefaultSharedPreferences(context); + String logo = sharedpreferences.getString(context.getString(R.string.SET_LOGO_LAUNCHER), "Bubbles"); + switch (logo) { + case "Fediverse": + return R.drawable.ic_plain_fediverse; + case "Hero": + return R.drawable.ic_plain_hero; + case "Atom": + return R.drawable.ic_plain_atom; + case "BrainCrash": + return R.drawable.ic_plain_crash; + case "Mastalab": + return R.drawable.ic_plain_mastalab; + default: + return R.drawable.ic_plain_bubbles; + } + } + + public static int getMainLogo(Context context) { + final SharedPreferences sharedpreferences = PreferenceManager.getDefaultSharedPreferences(context); + String logo = sharedpreferences.getString(context.getString(R.string.SET_LOGO_LAUNCHER), "Bubbles"); + switch (logo) { + case "Fediverse": + return R.drawable.fedilab_logo_fediverse; + case "Hero": + return R.drawable.fedilab_logo_hero; + case "Atom": + return R.drawable.fedilab_logo_atom; + case "BrainCrash": + return R.drawable.fedilab_logo_crash; + case "Mastalab": + return R.drawable.fedilab_logo_mastalab; + default: + return R.drawable.fedilab_logo_bubbles; + } + } + + + public static int getDrawable(String value) { + switch (value) { + case "Fediverse": + return R.drawable.fedilab_logo_fediverse; + case "Hero": + return R.drawable.fedilab_logo_hero; + case "Atom": + return R.drawable.fedilab_logo_atom; + case "BrainCrash": + return R.drawable.fedilab_logo_crash; + case "Mastalab": + return R.drawable.fedilab_logo_mastalab; + default: + return R.drawable.fedilab_logo_bubbles; + } + } + + public static void setDrawable(String value) { + switch (value) { + case "Fediverse": + mLauncher = BaseMainActivity.iconLauncher.FEDIVERSE; + return; + case "Hero": + mLauncher = BaseMainActivity.iconLauncher.HERO; + break; + case "Atom": + mLauncher = BaseMainActivity.iconLauncher.ATOM; + break; + case "BrainCrash": + mLauncher = BaseMainActivity.iconLauncher.BRAINCRASH; + break; + case "Mastalab": + mLauncher = BaseMainActivity.iconLauncher.MASTALAB; + break; + default: + mLauncher = BaseMainActivity.iconLauncher.BUBBLES; + } + } +} diff --git a/app/src/main/java/app/fedilab/android/helper/MediaHelper.java b/app/src/main/java/app/fedilab/android/helper/MediaHelper.java index 5265a9b3..a307739e 100644 --- a/app/src/main/java/app/fedilab/android/helper/MediaHelper.java +++ b/app/src/main/java/app/fedilab/android/helper/MediaHelper.java @@ -17,6 +17,7 @@ package app.fedilab.android.helper; import static android.content.Context.DOWNLOAD_SERVICE; import static app.fedilab.android.BaseMainActivity.currentAccount; import static app.fedilab.android.helper.Helper.notify_user; +import static app.fedilab.android.helper.LogoHelper.getMainLogo; import android.app.Activity; import android.app.DownloadManager; @@ -167,7 +168,7 @@ public class MediaHelper { intent.setDataAndType(uri, mime); if (!share) { notify_user(context, currentAccount, intent, BitmapFactory.decodeResource(context.getResources(), - R.mipmap.ic_launcher), Helper.NotifType.STORE, context.getString(R.string.save_over), context.getString(R.string.download_from, fileName)); + getMainLogo(context)), Helper.NotifType.STORE, context.getString(R.string.save_over), context.getString(R.string.download_from, fileName)); Toasty.success(context, context.getString(R.string.save_over), Toasty.LENGTH_LONG).show(); } else { Intent shareIntent = new Intent(Intent.ACTION_SEND); diff --git a/app/src/main/java/app/fedilab/android/helper/NotificationsHelper.java b/app/src/main/java/app/fedilab/android/helper/NotificationsHelper.java index 6c2f7c79..08b0be4e 100644 --- a/app/src/main/java/app/fedilab/android/helper/NotificationsHelper.java +++ b/app/src/main/java/app/fedilab/android/helper/NotificationsHelper.java @@ -16,6 +16,7 @@ package app.fedilab.android.helper; import static android.text.Html.FROM_HTML_MODE_LEGACY; import static app.fedilab.android.helper.Helper.notify_user; +import static app.fedilab.android.helper.LogoHelper.getMainLogo; import android.content.Context; import android.content.Intent; @@ -343,7 +344,7 @@ public class NotificationsHelper { editor.putString(context.getString(R.string.LAST_NOTIFICATION_ID) + account.user_id + "@" + account.instance, notifications.get(0).id); editor.apply(); notify_user(context, account, intent, BitmapFactory.decodeResource(context.getResources(), - R.mipmap.ic_launcher), finalNotifType, finalTitle, finalMessage); + getMainLogo(context)), finalNotifType, finalTitle, finalMessage); } return false; } diff --git a/app/src/main/java/app/fedilab/android/helper/SettingsStorage.java b/app/src/main/java/app/fedilab/android/helper/SettingsStorage.java index 290121cd..86a74a23 100644 --- a/app/src/main/java/app/fedilab/android/helper/SettingsStorage.java +++ b/app/src/main/java/app/fedilab/android/helper/SettingsStorage.java @@ -15,6 +15,7 @@ package app.fedilab.android.helper; * see . */ import static app.fedilab.android.BaseMainActivity.currentAccount; +import static app.fedilab.android.helper.LogoHelper.getMainLogo; import android.annotation.SuppressLint; import android.content.Context; @@ -61,7 +62,7 @@ public class SettingsStorage { intentOpen.setDataAndType(uri, "text/txt"); String title = context.getString(R.string.data_export_settings); Helper.notify_user(context, currentAccount, intentOpen, BitmapFactory.decodeResource(context.getResources(), - R.mipmap.ic_launcher), Helper.NotifType.BACKUP, title, message); + getMainLogo(context)), Helper.NotifType.BACKUP, title, message); } catch (IOException e) { e.printStackTrace(); } finally { diff --git a/app/src/main/java/app/fedilab/android/ui/fragment/settings/FragmentInterfaceSettings.java b/app/src/main/java/app/fedilab/android/ui/fragment/settings/FragmentInterfaceSettings.java index 1fc5545f..ab57cf02 100644 --- a/app/src/main/java/app/fedilab/android/ui/fragment/settings/FragmentInterfaceSettings.java +++ b/app/src/main/java/app/fedilab/android/ui/fragment/settings/FragmentInterfaceSettings.java @@ -14,9 +14,15 @@ package app.fedilab.android.ui.fragment.settings; * You should have received a copy of the GNU General Public License along with Fedilab; if not, * see . */ +import static app.fedilab.android.helper.LogoHelper.setDrawable; + +import android.content.ComponentName; +import android.content.Context; import android.content.SharedPreferences; +import android.content.pm.PackageManager; import android.os.Bundle; +import androidx.preference.ListPreference; import androidx.preference.PreferenceFragmentCompat; import androidx.preference.PreferenceManager; import androidx.preference.PreferenceScreen; @@ -24,6 +30,7 @@ import androidx.preference.SeekBarPreference; import app.fedilab.android.R; import app.fedilab.android.helper.Helper; +import app.fedilab.android.helper.LogoHelper; import es.dmoral.toasty.Toasty; public class FragmentInterfaceSettings extends PreferenceFragmentCompat implements SharedPreferences.OnSharedPreferenceChangeListener { @@ -54,6 +61,11 @@ public class FragmentInterfaceSettings extends PreferenceFragmentCompat implemen SET_FONT_SCALE_ICON.setMax(180); SET_FONT_SCALE_ICON.setMin(80); } + ListPreference SET_LOGO_LAUNCHER = findPreference(getString(R.string.SET_LOGO_LAUNCHER)); + if (SET_LOGO_LAUNCHER != null) { + SET_LOGO_LAUNCHER.getContext().setTheme(Helper.dialogStyle()); + SET_LOGO_LAUNCHER.setIcon(LogoHelper.getDrawable(SET_LOGO_LAUNCHER.getValue())); + } recreate = false; } @@ -81,9 +93,50 @@ public class FragmentInterfaceSettings extends PreferenceFragmentCompat implemen recreate = true; } editor.apply(); + if (key.compareToIgnoreCase(getString(R.string.SET_LOGO_LAUNCHER)) == 0) { + ListPreference SET_LOGO_LAUNCHER = findPreference(getString(R.string.SET_LOGO_LAUNCHER)); + if (SET_LOGO_LAUNCHER != null) { + hideAllIcons(requireActivity()); + setIcon(requireActivity(), SET_LOGO_LAUNCHER.getValue()); + SET_LOGO_LAUNCHER.setIcon(LogoHelper.getDrawable(SET_LOGO_LAUNCHER.getValue())); + setDrawable(SET_LOGO_LAUNCHER.getValue()); + } + } } } + private void hideAllIcons(Context context) { + context.getPackageManager().setComponentEnabledSetting( + new ComponentName(context.getPackageName(), "app.fedilab.android.activities.MainActivity.Bubbles"), + PackageManager.COMPONENT_ENABLED_STATE_DISABLED, PackageManager.DONT_KILL_APP); + + context.getPackageManager().setComponentEnabledSetting( + new ComponentName(context.getPackageName(), "app.fedilab.android.activities.MainActivity.Fediverse"), + PackageManager.COMPONENT_ENABLED_STATE_DISABLED, PackageManager.DONT_KILL_APP); + + context.getPackageManager().setComponentEnabledSetting( + new ComponentName(context.getPackageName(), "app.fedilab.android.activities.MainActivity.Hero"), + PackageManager.COMPONENT_ENABLED_STATE_DISABLED, PackageManager.DONT_KILL_APP); + + context.getPackageManager().setComponentEnabledSetting( + new ComponentName(context.getPackageName(), "app.fedilab.android.activities.MainActivity.Atom"), + PackageManager.COMPONENT_ENABLED_STATE_DISABLED, PackageManager.DONT_KILL_APP); + + context.getPackageManager().setComponentEnabledSetting( + new ComponentName(context.getPackageName(), "app.fedilab.android.activities.MainActivity.BrainCrash"), + PackageManager.COMPONENT_ENABLED_STATE_DISABLED, PackageManager.DONT_KILL_APP); + + context.getPackageManager().setComponentEnabledSetting( + new ComponentName(context.getPackageName(), "app.fedilab.android.activities.MainActivity.Mastalab"), + PackageManager.COMPONENT_ENABLED_STATE_DISABLED, PackageManager.DONT_KILL_APP); + } + + private void setIcon(Context context, String iconName) { + context.getPackageManager().setComponentEnabledSetting( + new ComponentName(context.getPackageName(), "app.fedilab.android.activities.MainActivity." + iconName), + PackageManager.COMPONENT_ENABLED_STATE_ENABLED, PackageManager.DONT_KILL_APP); + } + @Override public void onResume() { super.onResume(); diff --git a/app/src/main/java/app/fedilab/android/ui/fragment/settings/FragmentThemingSettings.java b/app/src/main/java/app/fedilab/android/ui/fragment/settings/FragmentThemingSettings.java index b589b36e..0cfbfca5 100644 --- a/app/src/main/java/app/fedilab/android/ui/fragment/settings/FragmentThemingSettings.java +++ b/app/src/main/java/app/fedilab/android/ui/fragment/settings/FragmentThemingSettings.java @@ -16,6 +16,7 @@ package app.fedilab.android.ui.fragment.settings; import static android.app.Activity.RESULT_OK; import static app.fedilab.android.BaseMainActivity.currentAccount; +import static app.fedilab.android.helper.LogoHelper.getMainLogo; import android.Manifest; import android.annotation.SuppressLint; @@ -572,7 +573,7 @@ public class FragmentThemingSettings extends PreferenceFragmentCompat implements intentOpen.setDataAndType(uri, "text/csv"); String title = getString(R.string.data_export_theme); Helper.notify_user(getActivity(), currentAccount, intentOpen, BitmapFactory.decodeResource(requireActivity().getResources(), - R.mipmap.ic_launcher), Helper.NotifType.BACKUP, title, message); + getMainLogo(requireActivity())), Helper.NotifType.BACKUP, title, message); } catch (Exception e) { e.printStackTrace(); Toasty.error(requireActivity(), getString(R.string.toast_error), Toast.LENGTH_LONG).show(); diff --git a/app/src/main/res/drawable-hdpi/ic_plain_atom.png b/app/src/main/res/drawable-hdpi/ic_plain_atom.png new file mode 100644 index 00000000..fd995f4b Binary files /dev/null and b/app/src/main/res/drawable-hdpi/ic_plain_atom.png differ diff --git a/app/src/main/res/drawable-hdpi/ic_plain_bubbles.png b/app/src/main/res/drawable-hdpi/ic_plain_bubbles.png new file mode 100644 index 00000000..4b957d58 Binary files /dev/null and b/app/src/main/res/drawable-hdpi/ic_plain_bubbles.png differ diff --git a/app/src/main/res/drawable-hdpi/ic_plain_crash.png b/app/src/main/res/drawable-hdpi/ic_plain_crash.png new file mode 100644 index 00000000..f5f3be18 Binary files /dev/null and b/app/src/main/res/drawable-hdpi/ic_plain_crash.png differ diff --git a/app/src/main/res/drawable-hdpi/ic_plain_fediverse.png b/app/src/main/res/drawable-hdpi/ic_plain_fediverse.png new file mode 100644 index 00000000..1f1b03e8 Binary files /dev/null and b/app/src/main/res/drawable-hdpi/ic_plain_fediverse.png differ diff --git a/app/src/main/res/drawable-hdpi/ic_plain_hero.png b/app/src/main/res/drawable-hdpi/ic_plain_hero.png new file mode 100644 index 00000000..fdbacec9 Binary files /dev/null and b/app/src/main/res/drawable-hdpi/ic_plain_hero.png differ diff --git a/app/src/main/res/drawable-hdpi/ic_plain_mastalab.png b/app/src/main/res/drawable-hdpi/ic_plain_mastalab.png new file mode 100644 index 00000000..8eb53240 Binary files /dev/null and b/app/src/main/res/drawable-hdpi/ic_plain_mastalab.png differ diff --git a/app/src/main/res/drawable-mdpi/ic_plain_atom.png b/app/src/main/res/drawable-mdpi/ic_plain_atom.png new file mode 100644 index 00000000..31834ea4 Binary files /dev/null and b/app/src/main/res/drawable-mdpi/ic_plain_atom.png differ diff --git a/app/src/main/res/drawable-mdpi/ic_plain_bubbles.png b/app/src/main/res/drawable-mdpi/ic_plain_bubbles.png new file mode 100644 index 00000000..ebaede4f Binary files /dev/null and b/app/src/main/res/drawable-mdpi/ic_plain_bubbles.png differ diff --git a/app/src/main/res/drawable-mdpi/ic_plain_crash.png b/app/src/main/res/drawable-mdpi/ic_plain_crash.png new file mode 100644 index 00000000..dfd9d7b6 Binary files /dev/null and b/app/src/main/res/drawable-mdpi/ic_plain_crash.png differ diff --git a/app/src/main/res/drawable-mdpi/ic_plain_fediverse.png b/app/src/main/res/drawable-mdpi/ic_plain_fediverse.png new file mode 100644 index 00000000..f75c1a88 Binary files /dev/null and b/app/src/main/res/drawable-mdpi/ic_plain_fediverse.png differ diff --git a/app/src/main/res/drawable-mdpi/ic_plain_hero.png b/app/src/main/res/drawable-mdpi/ic_plain_hero.png new file mode 100644 index 00000000..64819232 Binary files /dev/null and b/app/src/main/res/drawable-mdpi/ic_plain_hero.png differ diff --git a/app/src/main/res/drawable-mdpi/ic_plain_mastalab.png b/app/src/main/res/drawable-mdpi/ic_plain_mastalab.png new file mode 100644 index 00000000..bdea4957 Binary files /dev/null and b/app/src/main/res/drawable-mdpi/ic_plain_mastalab.png differ diff --git a/app/src/main/res/drawable-xhdpi/ic_plain_atom.png b/app/src/main/res/drawable-xhdpi/ic_plain_atom.png new file mode 100644 index 00000000..7e928df0 Binary files /dev/null and b/app/src/main/res/drawable-xhdpi/ic_plain_atom.png differ diff --git a/app/src/main/res/drawable-xhdpi/ic_plain_bubbles.png b/app/src/main/res/drawable-xhdpi/ic_plain_bubbles.png new file mode 100644 index 00000000..58a61865 Binary files /dev/null and b/app/src/main/res/drawable-xhdpi/ic_plain_bubbles.png differ diff --git a/app/src/main/res/drawable-xhdpi/ic_plain_crash.png b/app/src/main/res/drawable-xhdpi/ic_plain_crash.png new file mode 100644 index 00000000..594ab93c Binary files /dev/null and b/app/src/main/res/drawable-xhdpi/ic_plain_crash.png differ diff --git a/app/src/main/res/drawable-xhdpi/ic_plain_fediverse.png b/app/src/main/res/drawable-xhdpi/ic_plain_fediverse.png new file mode 100644 index 00000000..8ca463db Binary files /dev/null and b/app/src/main/res/drawable-xhdpi/ic_plain_fediverse.png differ diff --git a/app/src/main/res/drawable-xhdpi/ic_plain_hero.png b/app/src/main/res/drawable-xhdpi/ic_plain_hero.png new file mode 100644 index 00000000..691918ea Binary files /dev/null and b/app/src/main/res/drawable-xhdpi/ic_plain_hero.png differ diff --git a/app/src/main/res/drawable-xhdpi/ic_plain_mastalab.png b/app/src/main/res/drawable-xhdpi/ic_plain_mastalab.png new file mode 100644 index 00000000..ff2c22d8 Binary files /dev/null and b/app/src/main/res/drawable-xhdpi/ic_plain_mastalab.png differ diff --git a/app/src/main/res/drawable-xxhdpi/ic_plain_atom.png b/app/src/main/res/drawable-xxhdpi/ic_plain_atom.png new file mode 100644 index 00000000..d4dbd903 Binary files /dev/null and b/app/src/main/res/drawable-xxhdpi/ic_plain_atom.png differ diff --git a/app/src/main/res/drawable-xxhdpi/ic_plain_bubbles.png b/app/src/main/res/drawable-xxhdpi/ic_plain_bubbles.png new file mode 100644 index 00000000..fc2fa2e9 Binary files /dev/null and b/app/src/main/res/drawable-xxhdpi/ic_plain_bubbles.png differ diff --git a/app/src/main/res/drawable-xxhdpi/ic_plain_crash.png b/app/src/main/res/drawable-xxhdpi/ic_plain_crash.png new file mode 100644 index 00000000..d61295d0 Binary files /dev/null and b/app/src/main/res/drawable-xxhdpi/ic_plain_crash.png differ diff --git a/app/src/main/res/drawable-xxhdpi/ic_plain_fediverse.png b/app/src/main/res/drawable-xxhdpi/ic_plain_fediverse.png new file mode 100644 index 00000000..ee27257f Binary files /dev/null and b/app/src/main/res/drawable-xxhdpi/ic_plain_fediverse.png differ diff --git a/app/src/main/res/drawable-xxhdpi/ic_plain_hero.png b/app/src/main/res/drawable-xxhdpi/ic_plain_hero.png new file mode 100644 index 00000000..96752ede Binary files /dev/null and b/app/src/main/res/drawable-xxhdpi/ic_plain_hero.png differ diff --git a/app/src/main/res/drawable-xxhdpi/ic_plain_mastalab.png b/app/src/main/res/drawable-xxhdpi/ic_plain_mastalab.png new file mode 100644 index 00000000..c6ac3398 Binary files /dev/null and b/app/src/main/res/drawable-xxhdpi/ic_plain_mastalab.png differ diff --git a/app/src/main/res/drawable-xxxhdpi/ic_plain_atom.png b/app/src/main/res/drawable-xxxhdpi/ic_plain_atom.png new file mode 100644 index 00000000..a56ce5b7 Binary files /dev/null and b/app/src/main/res/drawable-xxxhdpi/ic_plain_atom.png differ diff --git a/app/src/main/res/drawable-xxxhdpi/ic_plain_bubbles.png b/app/src/main/res/drawable-xxxhdpi/ic_plain_bubbles.png new file mode 100644 index 00000000..cc174ae8 Binary files /dev/null and b/app/src/main/res/drawable-xxxhdpi/ic_plain_bubbles.png differ diff --git a/app/src/main/res/drawable-xxxhdpi/ic_plain_crash.png b/app/src/main/res/drawable-xxxhdpi/ic_plain_crash.png new file mode 100644 index 00000000..9989a0fd Binary files /dev/null and b/app/src/main/res/drawable-xxxhdpi/ic_plain_crash.png differ diff --git a/app/src/main/res/drawable-xxxhdpi/ic_plain_fediverse.png b/app/src/main/res/drawable-xxxhdpi/ic_plain_fediverse.png new file mode 100644 index 00000000..7b0bfc39 Binary files /dev/null and b/app/src/main/res/drawable-xxxhdpi/ic_plain_fediverse.png differ diff --git a/app/src/main/res/drawable-xxxhdpi/ic_plain_hero.png b/app/src/main/res/drawable-xxxhdpi/ic_plain_hero.png new file mode 100644 index 00000000..7c1a871f Binary files /dev/null and b/app/src/main/res/drawable-xxxhdpi/ic_plain_hero.png differ diff --git a/app/src/main/res/drawable-xxxhdpi/ic_plain_mastalab.png b/app/src/main/res/drawable-xxxhdpi/ic_plain_mastalab.png new file mode 100644 index 00000000..5c9afd0e Binary files /dev/null and b/app/src/main/res/drawable-xxxhdpi/ic_plain_mastalab.png differ diff --git a/app/src/main/res/drawable/fedilab_logo_atom.xml b/app/src/main/res/drawable/fedilab_logo_atom.xml new file mode 100644 index 00000000..2c9d5fa1 --- /dev/null +++ b/app/src/main/res/drawable/fedilab_logo_atom.xml @@ -0,0 +1,58 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/app/src/main/res/drawable/fedilab_logo_crash.xml b/app/src/main/res/drawable/fedilab_logo_crash.xml new file mode 100644 index 00000000..0200d132 --- /dev/null +++ b/app/src/main/res/drawable/fedilab_logo_crash.xml @@ -0,0 +1,313 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/app/src/main/res/drawable/fedilab_logo_fediverse.xml b/app/src/main/res/drawable/fedilab_logo_fediverse.xml new file mode 100644 index 00000000..7dbb1858 --- /dev/null +++ b/app/src/main/res/drawable/fedilab_logo_fediverse.xml @@ -0,0 +1,51 @@ + + + + + + + + + + + + + + + + + diff --git a/app/src/main/res/drawable/fedilab_logo_hero.xml b/app/src/main/res/drawable/fedilab_logo_hero.xml new file mode 100644 index 00000000..498da15f --- /dev/null +++ b/app/src/main/res/drawable/fedilab_logo_hero.xml @@ -0,0 +1,21 @@ + + + + + + + diff --git a/app/src/main/res/drawable/fedilab_logo_mastalab.xml b/app/src/main/res/drawable/fedilab_logo_mastalab.xml new file mode 100644 index 00000000..27fb889a --- /dev/null +++ b/app/src/main/res/drawable/fedilab_logo_mastalab.xml @@ -0,0 +1,18 @@ + + + + + + diff --git a/app/src/main/res/drawable/ic_launcher_atom_foreground.xml b/app/src/main/res/drawable/ic_launcher_atom_foreground.xml new file mode 100644 index 00000000..4422c31a --- /dev/null +++ b/app/src/main/res/drawable/ic_launcher_atom_foreground.xml @@ -0,0 +1,62 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/app/src/main/res/drawable/ic_launcher_bubbles_foreground.xml b/app/src/main/res/drawable/ic_launcher_bubbles_foreground.xml new file mode 100644 index 00000000..7543a599 --- /dev/null +++ b/app/src/main/res/drawable/ic_launcher_bubbles_foreground.xml @@ -0,0 +1,20 @@ + + + + + + diff --git a/app/src/main/res/drawable/ic_launcher_crash_foreground.xml b/app/src/main/res/drawable/ic_launcher_crash_foreground.xml new file mode 100644 index 00000000..00c86c00 --- /dev/null +++ b/app/src/main/res/drawable/ic_launcher_crash_foreground.xml @@ -0,0 +1,317 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/app/src/main/res/drawable/ic_launcher_fediverse_foreground.xml b/app/src/main/res/drawable/ic_launcher_fediverse_foreground.xml new file mode 100644 index 00000000..1c076433 --- /dev/null +++ b/app/src/main/res/drawable/ic_launcher_fediverse_foreground.xml @@ -0,0 +1,70 @@ + + + + + + + + + + + + + + + + + + + diff --git a/app/src/main/res/drawable/ic_launcher_hero_foreground.xml b/app/src/main/res/drawable/ic_launcher_hero_foreground.xml new file mode 100644 index 00000000..87033392 --- /dev/null +++ b/app/src/main/res/drawable/ic_launcher_hero_foreground.xml @@ -0,0 +1,25 @@ + + + + + + + + + diff --git a/app/src/main/res/drawable/ic_launcher_mastalab_foreground.xml b/app/src/main/res/drawable/ic_launcher_mastalab_foreground.xml new file mode 100644 index 00000000..dc1764e5 --- /dev/null +++ b/app/src/main/res/drawable/ic_launcher_mastalab_foreground.xml @@ -0,0 +1,30 @@ + + + + + + + + + + diff --git a/app/src/main/res/mipmap-anydpi-v26/ic_launcher_atom.xml b/app/src/main/res/mipmap-anydpi-v26/ic_launcher_atom.xml new file mode 100644 index 00000000..5e2b456a --- /dev/null +++ b/app/src/main/res/mipmap-anydpi-v26/ic_launcher_atom.xml @@ -0,0 +1,5 @@ + + + + + \ No newline at end of file diff --git a/app/src/main/res/mipmap-anydpi-v26/ic_launcher_atom_round.xml b/app/src/main/res/mipmap-anydpi-v26/ic_launcher_atom_round.xml new file mode 100644 index 00000000..5e2b456a --- /dev/null +++ b/app/src/main/res/mipmap-anydpi-v26/ic_launcher_atom_round.xml @@ -0,0 +1,5 @@ + + + + + \ No newline at end of file diff --git a/app/src/main/res/mipmap-anydpi-v26/ic_launcher_bubbles.xml b/app/src/main/res/mipmap-anydpi-v26/ic_launcher_bubbles.xml new file mode 100644 index 00000000..3b0f3d2b --- /dev/null +++ b/app/src/main/res/mipmap-anydpi-v26/ic_launcher_bubbles.xml @@ -0,0 +1,5 @@ + + + + + \ No newline at end of file diff --git a/app/src/main/res/mipmap-anydpi-v26/ic_launcher_bubbles_round.xml b/app/src/main/res/mipmap-anydpi-v26/ic_launcher_bubbles_round.xml new file mode 100644 index 00000000..3b0f3d2b --- /dev/null +++ b/app/src/main/res/mipmap-anydpi-v26/ic_launcher_bubbles_round.xml @@ -0,0 +1,5 @@ + + + + + \ No newline at end of file diff --git a/app/src/main/res/mipmap-anydpi-v26/ic_launcher_crash.xml b/app/src/main/res/mipmap-anydpi-v26/ic_launcher_crash.xml new file mode 100644 index 00000000..f9b24a1a --- /dev/null +++ b/app/src/main/res/mipmap-anydpi-v26/ic_launcher_crash.xml @@ -0,0 +1,5 @@ + + + + + \ No newline at end of file diff --git a/app/src/main/res/mipmap-anydpi-v26/ic_launcher_crash_round.xml b/app/src/main/res/mipmap-anydpi-v26/ic_launcher_crash_round.xml new file mode 100644 index 00000000..f9b24a1a --- /dev/null +++ b/app/src/main/res/mipmap-anydpi-v26/ic_launcher_crash_round.xml @@ -0,0 +1,5 @@ + + + + + \ No newline at end of file diff --git a/app/src/main/res/mipmap-anydpi-v26/ic_launcher_fediverse.xml b/app/src/main/res/mipmap-anydpi-v26/ic_launcher_fediverse.xml new file mode 100644 index 00000000..2b9a0f67 --- /dev/null +++ b/app/src/main/res/mipmap-anydpi-v26/ic_launcher_fediverse.xml @@ -0,0 +1,5 @@ + + + + + \ No newline at end of file diff --git a/app/src/main/res/mipmap-anydpi-v26/ic_launcher_fediverse_round.xml b/app/src/main/res/mipmap-anydpi-v26/ic_launcher_fediverse_round.xml new file mode 100644 index 00000000..2b9a0f67 --- /dev/null +++ b/app/src/main/res/mipmap-anydpi-v26/ic_launcher_fediverse_round.xml @@ -0,0 +1,5 @@ + + + + + \ No newline at end of file diff --git a/app/src/main/res/mipmap-anydpi-v26/ic_launcher_hero.xml b/app/src/main/res/mipmap-anydpi-v26/ic_launcher_hero.xml new file mode 100644 index 00000000..b0767e14 --- /dev/null +++ b/app/src/main/res/mipmap-anydpi-v26/ic_launcher_hero.xml @@ -0,0 +1,5 @@ + + + + + \ No newline at end of file diff --git a/app/src/main/res/mipmap-anydpi-v26/ic_launcher_hero_round.xml b/app/src/main/res/mipmap-anydpi-v26/ic_launcher_hero_round.xml new file mode 100644 index 00000000..b0767e14 --- /dev/null +++ b/app/src/main/res/mipmap-anydpi-v26/ic_launcher_hero_round.xml @@ -0,0 +1,5 @@ + + + + + \ No newline at end of file diff --git a/app/src/main/res/mipmap-anydpi-v26/ic_launcher_mastalab.xml b/app/src/main/res/mipmap-anydpi-v26/ic_launcher_mastalab.xml new file mode 100644 index 00000000..0c1231b9 --- /dev/null +++ b/app/src/main/res/mipmap-anydpi-v26/ic_launcher_mastalab.xml @@ -0,0 +1,5 @@ + + + + + \ No newline at end of file diff --git a/app/src/main/res/mipmap-anydpi-v26/ic_launcher_mastalab_round.xml b/app/src/main/res/mipmap-anydpi-v26/ic_launcher_mastalab_round.xml new file mode 100644 index 00000000..0c1231b9 --- /dev/null +++ b/app/src/main/res/mipmap-anydpi-v26/ic_launcher_mastalab_round.xml @@ -0,0 +1,5 @@ + + + + + \ No newline at end of file diff --git a/app/src/main/res/mipmap-hdpi/ic_launcher_atom.png b/app/src/main/res/mipmap-hdpi/ic_launcher_atom.png new file mode 100644 index 00000000..2faf7330 Binary files /dev/null and b/app/src/main/res/mipmap-hdpi/ic_launcher_atom.png differ diff --git a/app/src/main/res/mipmap-hdpi/ic_launcher_atom_round.png b/app/src/main/res/mipmap-hdpi/ic_launcher_atom_round.png new file mode 100644 index 00000000..d73a5692 Binary files /dev/null and b/app/src/main/res/mipmap-hdpi/ic_launcher_atom_round.png differ diff --git a/app/src/main/res/mipmap-hdpi/ic_launcher_bubbles.png b/app/src/main/res/mipmap-hdpi/ic_launcher_bubbles.png new file mode 100644 index 00000000..23c86e98 Binary files /dev/null and b/app/src/main/res/mipmap-hdpi/ic_launcher_bubbles.png differ diff --git a/app/src/main/res/mipmap-hdpi/ic_launcher_bubbles_round.png b/app/src/main/res/mipmap-hdpi/ic_launcher_bubbles_round.png new file mode 100644 index 00000000..a9b2f79b Binary files /dev/null and b/app/src/main/res/mipmap-hdpi/ic_launcher_bubbles_round.png differ diff --git a/app/src/main/res/mipmap-hdpi/ic_launcher_crash.png b/app/src/main/res/mipmap-hdpi/ic_launcher_crash.png new file mode 100644 index 00000000..43dd6909 Binary files /dev/null and b/app/src/main/res/mipmap-hdpi/ic_launcher_crash.png differ diff --git a/app/src/main/res/mipmap-hdpi/ic_launcher_crash_round.png b/app/src/main/res/mipmap-hdpi/ic_launcher_crash_round.png new file mode 100644 index 00000000..fe0890a6 Binary files /dev/null and b/app/src/main/res/mipmap-hdpi/ic_launcher_crash_round.png differ diff --git a/app/src/main/res/mipmap-hdpi/ic_launcher_fediverse.png b/app/src/main/res/mipmap-hdpi/ic_launcher_fediverse.png new file mode 100644 index 00000000..00a8b1f4 Binary files /dev/null and b/app/src/main/res/mipmap-hdpi/ic_launcher_fediverse.png differ diff --git a/app/src/main/res/mipmap-hdpi/ic_launcher_fediverse_round.png b/app/src/main/res/mipmap-hdpi/ic_launcher_fediverse_round.png new file mode 100644 index 00000000..8ce998ec Binary files /dev/null and b/app/src/main/res/mipmap-hdpi/ic_launcher_fediverse_round.png differ diff --git a/app/src/main/res/mipmap-hdpi/ic_launcher_hero.png b/app/src/main/res/mipmap-hdpi/ic_launcher_hero.png new file mode 100644 index 00000000..3d78a080 Binary files /dev/null and b/app/src/main/res/mipmap-hdpi/ic_launcher_hero.png differ diff --git a/app/src/main/res/mipmap-hdpi/ic_launcher_hero_round.png b/app/src/main/res/mipmap-hdpi/ic_launcher_hero_round.png new file mode 100644 index 00000000..d48aed4f Binary files /dev/null and b/app/src/main/res/mipmap-hdpi/ic_launcher_hero_round.png differ diff --git a/app/src/main/res/mipmap-hdpi/ic_launcher_mastalab.png b/app/src/main/res/mipmap-hdpi/ic_launcher_mastalab.png new file mode 100644 index 00000000..23435d51 Binary files /dev/null and b/app/src/main/res/mipmap-hdpi/ic_launcher_mastalab.png differ diff --git a/app/src/main/res/mipmap-hdpi/ic_launcher_mastalab_round.png b/app/src/main/res/mipmap-hdpi/ic_launcher_mastalab_round.png new file mode 100644 index 00000000..d105f2c8 Binary files /dev/null and b/app/src/main/res/mipmap-hdpi/ic_launcher_mastalab_round.png differ diff --git a/app/src/main/res/mipmap-mdpi/ic_launcher_atom.png b/app/src/main/res/mipmap-mdpi/ic_launcher_atom.png new file mode 100644 index 00000000..0257feee Binary files /dev/null and b/app/src/main/res/mipmap-mdpi/ic_launcher_atom.png differ diff --git a/app/src/main/res/mipmap-mdpi/ic_launcher_atom_round.png b/app/src/main/res/mipmap-mdpi/ic_launcher_atom_round.png new file mode 100644 index 00000000..b9d28595 Binary files /dev/null and b/app/src/main/res/mipmap-mdpi/ic_launcher_atom_round.png differ diff --git a/app/src/main/res/mipmap-mdpi/ic_launcher_bubbles.png b/app/src/main/res/mipmap-mdpi/ic_launcher_bubbles.png new file mode 100644 index 00000000..af570feb Binary files /dev/null and b/app/src/main/res/mipmap-mdpi/ic_launcher_bubbles.png differ diff --git a/app/src/main/res/mipmap-mdpi/ic_launcher_bubbles_round.png b/app/src/main/res/mipmap-mdpi/ic_launcher_bubbles_round.png new file mode 100644 index 00000000..76c71903 Binary files /dev/null and b/app/src/main/res/mipmap-mdpi/ic_launcher_bubbles_round.png differ diff --git a/app/src/main/res/mipmap-mdpi/ic_launcher_crash.png b/app/src/main/res/mipmap-mdpi/ic_launcher_crash.png new file mode 100644 index 00000000..d63f3e2d Binary files /dev/null and b/app/src/main/res/mipmap-mdpi/ic_launcher_crash.png differ diff --git a/app/src/main/res/mipmap-mdpi/ic_launcher_crash_round.png b/app/src/main/res/mipmap-mdpi/ic_launcher_crash_round.png new file mode 100644 index 00000000..b47aac5d Binary files /dev/null and b/app/src/main/res/mipmap-mdpi/ic_launcher_crash_round.png differ diff --git a/app/src/main/res/mipmap-mdpi/ic_launcher_fediverse.png b/app/src/main/res/mipmap-mdpi/ic_launcher_fediverse.png new file mode 100644 index 00000000..b2be2891 Binary files /dev/null and b/app/src/main/res/mipmap-mdpi/ic_launcher_fediverse.png differ diff --git a/app/src/main/res/mipmap-mdpi/ic_launcher_fediverse_round.png b/app/src/main/res/mipmap-mdpi/ic_launcher_fediverse_round.png new file mode 100644 index 00000000..f4d24b64 Binary files /dev/null and b/app/src/main/res/mipmap-mdpi/ic_launcher_fediverse_round.png differ diff --git a/app/src/main/res/mipmap-mdpi/ic_launcher_hero.png b/app/src/main/res/mipmap-mdpi/ic_launcher_hero.png new file mode 100644 index 00000000..925e907b Binary files /dev/null and b/app/src/main/res/mipmap-mdpi/ic_launcher_hero.png differ diff --git a/app/src/main/res/mipmap-mdpi/ic_launcher_hero_round.png b/app/src/main/res/mipmap-mdpi/ic_launcher_hero_round.png new file mode 100644 index 00000000..fe73853a Binary files /dev/null and b/app/src/main/res/mipmap-mdpi/ic_launcher_hero_round.png differ diff --git a/app/src/main/res/mipmap-mdpi/ic_launcher_mastalab.png b/app/src/main/res/mipmap-mdpi/ic_launcher_mastalab.png new file mode 100644 index 00000000..47eaef20 Binary files /dev/null and b/app/src/main/res/mipmap-mdpi/ic_launcher_mastalab.png differ diff --git a/app/src/main/res/mipmap-mdpi/ic_launcher_mastalab_round.png b/app/src/main/res/mipmap-mdpi/ic_launcher_mastalab_round.png new file mode 100644 index 00000000..061676e9 Binary files /dev/null and b/app/src/main/res/mipmap-mdpi/ic_launcher_mastalab_round.png differ diff --git a/app/src/main/res/mipmap-xhdpi/ic_launcher_atom.png b/app/src/main/res/mipmap-xhdpi/ic_launcher_atom.png new file mode 100644 index 00000000..fa3c0d06 Binary files /dev/null and b/app/src/main/res/mipmap-xhdpi/ic_launcher_atom.png differ diff --git a/app/src/main/res/mipmap-xhdpi/ic_launcher_atom_round.png b/app/src/main/res/mipmap-xhdpi/ic_launcher_atom_round.png new file mode 100644 index 00000000..d7f7477d Binary files /dev/null and b/app/src/main/res/mipmap-xhdpi/ic_launcher_atom_round.png differ diff --git a/app/src/main/res/mipmap-xhdpi/ic_launcher_bubbles.png b/app/src/main/res/mipmap-xhdpi/ic_launcher_bubbles.png new file mode 100644 index 00000000..e9850411 Binary files /dev/null and b/app/src/main/res/mipmap-xhdpi/ic_launcher_bubbles.png differ diff --git a/app/src/main/res/mipmap-xhdpi/ic_launcher_bubbles_round.png b/app/src/main/res/mipmap-xhdpi/ic_launcher_bubbles_round.png new file mode 100644 index 00000000..ec57d072 Binary files /dev/null and b/app/src/main/res/mipmap-xhdpi/ic_launcher_bubbles_round.png differ diff --git a/app/src/main/res/mipmap-xhdpi/ic_launcher_crash.png b/app/src/main/res/mipmap-xhdpi/ic_launcher_crash.png new file mode 100644 index 00000000..b4cc7224 Binary files /dev/null and b/app/src/main/res/mipmap-xhdpi/ic_launcher_crash.png differ diff --git a/app/src/main/res/mipmap-xhdpi/ic_launcher_crash_round.png b/app/src/main/res/mipmap-xhdpi/ic_launcher_crash_round.png new file mode 100644 index 00000000..f7b8fe12 Binary files /dev/null and b/app/src/main/res/mipmap-xhdpi/ic_launcher_crash_round.png differ diff --git a/app/src/main/res/mipmap-xhdpi/ic_launcher_fediverse.png b/app/src/main/res/mipmap-xhdpi/ic_launcher_fediverse.png new file mode 100644 index 00000000..2a3e52b1 Binary files /dev/null and b/app/src/main/res/mipmap-xhdpi/ic_launcher_fediverse.png differ diff --git a/app/src/main/res/mipmap-xhdpi/ic_launcher_fediverse_round.png b/app/src/main/res/mipmap-xhdpi/ic_launcher_fediverse_round.png new file mode 100644 index 00000000..493b0373 Binary files /dev/null and b/app/src/main/res/mipmap-xhdpi/ic_launcher_fediverse_round.png differ diff --git a/app/src/main/res/mipmap-xhdpi/ic_launcher_hero.png b/app/src/main/res/mipmap-xhdpi/ic_launcher_hero.png new file mode 100644 index 00000000..cd089da5 Binary files /dev/null and b/app/src/main/res/mipmap-xhdpi/ic_launcher_hero.png differ diff --git a/app/src/main/res/mipmap-xhdpi/ic_launcher_hero_round.png b/app/src/main/res/mipmap-xhdpi/ic_launcher_hero_round.png new file mode 100644 index 00000000..7c0e09ca Binary files /dev/null and b/app/src/main/res/mipmap-xhdpi/ic_launcher_hero_round.png differ diff --git a/app/src/main/res/mipmap-xhdpi/ic_launcher_mastalab.png b/app/src/main/res/mipmap-xhdpi/ic_launcher_mastalab.png new file mode 100644 index 00000000..684512bc Binary files /dev/null and b/app/src/main/res/mipmap-xhdpi/ic_launcher_mastalab.png differ diff --git a/app/src/main/res/mipmap-xhdpi/ic_launcher_mastalab_round.png b/app/src/main/res/mipmap-xhdpi/ic_launcher_mastalab_round.png new file mode 100644 index 00000000..d1588428 Binary files /dev/null and b/app/src/main/res/mipmap-xhdpi/ic_launcher_mastalab_round.png differ diff --git a/app/src/main/res/mipmap-xxhdpi/ic_launcher_atom.png b/app/src/main/res/mipmap-xxhdpi/ic_launcher_atom.png new file mode 100644 index 00000000..495bfc42 Binary files /dev/null and b/app/src/main/res/mipmap-xxhdpi/ic_launcher_atom.png differ diff --git a/app/src/main/res/mipmap-xxhdpi/ic_launcher_atom_round.png b/app/src/main/res/mipmap-xxhdpi/ic_launcher_atom_round.png new file mode 100644 index 00000000..786066b7 Binary files /dev/null and b/app/src/main/res/mipmap-xxhdpi/ic_launcher_atom_round.png differ diff --git a/app/src/main/res/mipmap-xxhdpi/ic_launcher_bubbles.png b/app/src/main/res/mipmap-xxhdpi/ic_launcher_bubbles.png new file mode 100644 index 00000000..3d67f311 Binary files /dev/null and b/app/src/main/res/mipmap-xxhdpi/ic_launcher_bubbles.png differ diff --git a/app/src/main/res/mipmap-xxhdpi/ic_launcher_bubbles_round.png b/app/src/main/res/mipmap-xxhdpi/ic_launcher_bubbles_round.png new file mode 100644 index 00000000..4d62dcee Binary files /dev/null and b/app/src/main/res/mipmap-xxhdpi/ic_launcher_bubbles_round.png differ diff --git a/app/src/main/res/mipmap-xxhdpi/ic_launcher_crash.png b/app/src/main/res/mipmap-xxhdpi/ic_launcher_crash.png new file mode 100644 index 00000000..d607d5f1 Binary files /dev/null and b/app/src/main/res/mipmap-xxhdpi/ic_launcher_crash.png differ diff --git a/app/src/main/res/mipmap-xxhdpi/ic_launcher_crash_round.png b/app/src/main/res/mipmap-xxhdpi/ic_launcher_crash_round.png new file mode 100644 index 00000000..7b8ded03 Binary files /dev/null and b/app/src/main/res/mipmap-xxhdpi/ic_launcher_crash_round.png differ diff --git a/app/src/main/res/mipmap-xxhdpi/ic_launcher_fediverse.png b/app/src/main/res/mipmap-xxhdpi/ic_launcher_fediverse.png new file mode 100644 index 00000000..3a2a305a Binary files /dev/null and b/app/src/main/res/mipmap-xxhdpi/ic_launcher_fediverse.png differ diff --git a/app/src/main/res/mipmap-xxhdpi/ic_launcher_fediverse_round.png b/app/src/main/res/mipmap-xxhdpi/ic_launcher_fediverse_round.png new file mode 100644 index 00000000..bf340a62 Binary files /dev/null and b/app/src/main/res/mipmap-xxhdpi/ic_launcher_fediverse_round.png differ diff --git a/app/src/main/res/mipmap-xxhdpi/ic_launcher_hero.png b/app/src/main/res/mipmap-xxhdpi/ic_launcher_hero.png new file mode 100644 index 00000000..3cdc83a5 Binary files /dev/null and b/app/src/main/res/mipmap-xxhdpi/ic_launcher_hero.png differ diff --git a/app/src/main/res/mipmap-xxhdpi/ic_launcher_hero_round.png b/app/src/main/res/mipmap-xxhdpi/ic_launcher_hero_round.png new file mode 100644 index 00000000..57a1940b Binary files /dev/null and b/app/src/main/res/mipmap-xxhdpi/ic_launcher_hero_round.png differ diff --git a/app/src/main/res/mipmap-xxhdpi/ic_launcher_mastalab.png b/app/src/main/res/mipmap-xxhdpi/ic_launcher_mastalab.png new file mode 100644 index 00000000..01fa6a96 Binary files /dev/null and b/app/src/main/res/mipmap-xxhdpi/ic_launcher_mastalab.png differ diff --git a/app/src/main/res/mipmap-xxhdpi/ic_launcher_mastalab_round.png b/app/src/main/res/mipmap-xxhdpi/ic_launcher_mastalab_round.png new file mode 100644 index 00000000..11078c7b Binary files /dev/null and b/app/src/main/res/mipmap-xxhdpi/ic_launcher_mastalab_round.png differ diff --git a/app/src/main/res/mipmap-xxxhdpi/ic_launcher_atom.png b/app/src/main/res/mipmap-xxxhdpi/ic_launcher_atom.png new file mode 100644 index 00000000..1441b442 Binary files /dev/null and b/app/src/main/res/mipmap-xxxhdpi/ic_launcher_atom.png differ diff --git a/app/src/main/res/mipmap-xxxhdpi/ic_launcher_atom_round.png b/app/src/main/res/mipmap-xxxhdpi/ic_launcher_atom_round.png new file mode 100644 index 00000000..fcbf49b3 Binary files /dev/null and b/app/src/main/res/mipmap-xxxhdpi/ic_launcher_atom_round.png differ diff --git a/app/src/main/res/mipmap-xxxhdpi/ic_launcher_bubbles.png b/app/src/main/res/mipmap-xxxhdpi/ic_launcher_bubbles.png new file mode 100644 index 00000000..fa755f8a Binary files /dev/null and b/app/src/main/res/mipmap-xxxhdpi/ic_launcher_bubbles.png differ diff --git a/app/src/main/res/mipmap-xxxhdpi/ic_launcher_bubbles_round.png b/app/src/main/res/mipmap-xxxhdpi/ic_launcher_bubbles_round.png new file mode 100644 index 00000000..d71c5c14 Binary files /dev/null and b/app/src/main/res/mipmap-xxxhdpi/ic_launcher_bubbles_round.png differ diff --git a/app/src/main/res/mipmap-xxxhdpi/ic_launcher_crash.png b/app/src/main/res/mipmap-xxxhdpi/ic_launcher_crash.png new file mode 100644 index 00000000..1697b91f Binary files /dev/null and b/app/src/main/res/mipmap-xxxhdpi/ic_launcher_crash.png differ diff --git a/app/src/main/res/mipmap-xxxhdpi/ic_launcher_crash_round.png b/app/src/main/res/mipmap-xxxhdpi/ic_launcher_crash_round.png new file mode 100644 index 00000000..92a25c59 Binary files /dev/null and b/app/src/main/res/mipmap-xxxhdpi/ic_launcher_crash_round.png differ diff --git a/app/src/main/res/mipmap-xxxhdpi/ic_launcher_fediverse.png b/app/src/main/res/mipmap-xxxhdpi/ic_launcher_fediverse.png new file mode 100644 index 00000000..4b85a292 Binary files /dev/null and b/app/src/main/res/mipmap-xxxhdpi/ic_launcher_fediverse.png differ diff --git a/app/src/main/res/mipmap-xxxhdpi/ic_launcher_fediverse_round.png b/app/src/main/res/mipmap-xxxhdpi/ic_launcher_fediverse_round.png new file mode 100644 index 00000000..95995b37 Binary files /dev/null and b/app/src/main/res/mipmap-xxxhdpi/ic_launcher_fediverse_round.png differ diff --git a/app/src/main/res/mipmap-xxxhdpi/ic_launcher_hero.png b/app/src/main/res/mipmap-xxxhdpi/ic_launcher_hero.png new file mode 100644 index 00000000..e2267265 Binary files /dev/null and b/app/src/main/res/mipmap-xxxhdpi/ic_launcher_hero.png differ diff --git a/app/src/main/res/mipmap-xxxhdpi/ic_launcher_hero_round.png b/app/src/main/res/mipmap-xxxhdpi/ic_launcher_hero_round.png new file mode 100644 index 00000000..38c0d148 Binary files /dev/null and b/app/src/main/res/mipmap-xxxhdpi/ic_launcher_hero_round.png differ diff --git a/app/src/main/res/mipmap-xxxhdpi/ic_launcher_mastalab.png b/app/src/main/res/mipmap-xxxhdpi/ic_launcher_mastalab.png new file mode 100644 index 00000000..e4359945 Binary files /dev/null and b/app/src/main/res/mipmap-xxxhdpi/ic_launcher_mastalab.png differ diff --git a/app/src/main/res/mipmap-xxxhdpi/ic_launcher_mastalab_round.png b/app/src/main/res/mipmap-xxxhdpi/ic_launcher_mastalab_round.png new file mode 100644 index 00000000..0152187c Binary files /dev/null and b/app/src/main/res/mipmap-xxxhdpi/ic_launcher_mastalab_round.png differ diff --git a/app/src/main/res/values/ic_launcher_atom_background.xml b/app/src/main/res/values/ic_launcher_atom_background.xml new file mode 100644 index 00000000..e390623c --- /dev/null +++ b/app/src/main/res/values/ic_launcher_atom_background.xml @@ -0,0 +1,4 @@ + + + #FFFFFF + \ No newline at end of file diff --git a/app/src/main/res/values/ic_launcher_bubbles_background.xml b/app/src/main/res/values/ic_launcher_bubbles_background.xml new file mode 100644 index 00000000..ec1405e1 --- /dev/null +++ b/app/src/main/res/values/ic_launcher_bubbles_background.xml @@ -0,0 +1,4 @@ + + + #FFFFFF + \ No newline at end of file diff --git a/app/src/main/res/values/ic_launcher_crash_background.xml b/app/src/main/res/values/ic_launcher_crash_background.xml new file mode 100644 index 00000000..02b6c72a --- /dev/null +++ b/app/src/main/res/values/ic_launcher_crash_background.xml @@ -0,0 +1,4 @@ + + + #282C37 + \ No newline at end of file diff --git a/app/src/main/res/values/ic_launcher_fediverse_background.xml b/app/src/main/res/values/ic_launcher_fediverse_background.xml new file mode 100644 index 00000000..9310c737 --- /dev/null +++ b/app/src/main/res/values/ic_launcher_fediverse_background.xml @@ -0,0 +1,4 @@ + + + #14161B + \ No newline at end of file diff --git a/app/src/main/res/values/ic_launcher_hero_background.xml b/app/src/main/res/values/ic_launcher_hero_background.xml new file mode 100644 index 00000000..7ced2858 --- /dev/null +++ b/app/src/main/res/values/ic_launcher_hero_background.xml @@ -0,0 +1,4 @@ + + + #282C37 + \ No newline at end of file diff --git a/app/src/main/res/values/ic_launcher_lite_background.xml b/app/src/main/res/values/ic_launcher_lite_background.xml new file mode 100644 index 00000000..0543bf8d --- /dev/null +++ b/app/src/main/res/values/ic_launcher_lite_background.xml @@ -0,0 +1,4 @@ + + + #FFFFFF + \ No newline at end of file diff --git a/app/src/main/res/values/ic_launcher_mastalab_background.xml b/app/src/main/res/values/ic_launcher_mastalab_background.xml new file mode 100644 index 00000000..6ae7a0dd --- /dev/null +++ b/app/src/main/res/values/ic_launcher_mastalab_background.xml @@ -0,0 +1,4 @@ + + + #434958 + \ No newline at end of file diff --git a/app/src/main/res/values/strings.xml b/app/src/main/res/values/strings.xml index b1fec0be..5140b1a9 100644 --- a/app/src/main/res/values/strings.xml +++ b/app/src/main/res/values/strings.xml @@ -748,6 +748,24 @@ No notifications + + Fedilab + Fediverse + SuperHero + Atom + BrainCrash + Mastalab + + + + Bubbles + Fediverse + Hero + Atom + BrainCrash + Mastalab + + Always Wifi only @@ -908,7 +926,7 @@ SET_TIME_TO SET_MED_DESC_TIMEOUT SET_COMPOSE_LANGUAGE - + SET_LOGO_LAUNCHER SET_NOTIF_FOLLOW SET_NOTIF_MENTION @@ -1492,4 +1510,7 @@ When turning on, the app will collapse related notifications Display media in notifications Media in notifications for reblogs and favourites will be displayed + Pickup a logo + Change logo + Change the logo of the app on your device diff --git a/app/src/main/res/xml/pref_interface.xml b/app/src/main/res/xml/pref_interface.xml index 3e988e11..b7538d74 100644 --- a/app/src/main/res/xml/pref_interface.xml +++ b/app/src/main/res/xml/pref_interface.xml @@ -112,4 +112,15 @@ app:key="@string/SET_MED_DESC_TIMEOUT" app:showSeekBarValue="true" app:title="@string/set_med_desc_timeout" /> + + + \ No newline at end of file