Fixing the sk references. Readding them for easier translation

This commit is contained in:
LucasGGamerM
2022-12-09 19:58:33 -03:00
parent 290b7db7e4
commit 83f12b0840
6 changed files with 76 additions and 76 deletions

View File

@@ -110,7 +110,7 @@ public class SettingsFragment extends MastodonToolbarFragment{
GlobalUserPreferences.useCustomTabs=i.checked; GlobalUserPreferences.useCustomTabs=i.checked;
GlobalUserPreferences.save(); GlobalUserPreferences.save();
})); }));
items.add(new SwitchItem(R.string.settings_show_interaction_counts, R.drawable.ic_fluent_number_row_24_regular, GlobalUserPreferences.showInteractionCounts, i->{ items.add(new SwitchItem(R.string.sk_settings_show_interaction_counts, R.drawable.ic_fluent_number_row_24_regular, GlobalUserPreferences.showInteractionCounts, i->{
GlobalUserPreferences.showInteractionCounts=i.checked; GlobalUserPreferences.showInteractionCounts=i.checked;
GlobalUserPreferences.save(); GlobalUserPreferences.save();
})); }));
@@ -120,15 +120,15 @@ public class SettingsFragment extends MastodonToolbarFragment{
})); }));
items.add(new HeaderItem(R.string.home_timeline)); items.add(new HeaderItem(R.string.home_timeline));
items.add(new SwitchItem(R.string.settings_show_replies, R.drawable.ic_fluent_chat_multiple_24_regular, GlobalUserPreferences.showReplies, i->{ items.add(new SwitchItem(R.string.sk_settings_show_replies, R.drawable.ic_fluent_chat_multiple_24_regular, GlobalUserPreferences.showReplies, i->{
GlobalUserPreferences.showReplies=i.checked; GlobalUserPreferences.showReplies=i.checked;
GlobalUserPreferences.save(); GlobalUserPreferences.save();
})); }));
items.add(new SwitchItem(R.string.settings_show_boosts, R.drawable.ic_fluent_arrow_repeat_all_24_regular, GlobalUserPreferences.showBoosts, i->{ items.add(new SwitchItem(R.string.sk_settings_show_boosts, R.drawable.ic_fluent_arrow_repeat_all_24_regular, GlobalUserPreferences.showBoosts, i->{
GlobalUserPreferences.showBoosts=i.checked; GlobalUserPreferences.showBoosts=i.checked;
GlobalUserPreferences.save(); GlobalUserPreferences.save();
})); }));
items.add(new SwitchItem(R.string.settings_load_new_posts, R.drawable.ic_fluent_arrow_up_24_regular, GlobalUserPreferences.loadNewPosts, i->{ items.add(new SwitchItem(R.string.sk_settings_load_new_posts, R.drawable.ic_fluent_arrow_up_24_regular, GlobalUserPreferences.loadNewPosts, i->{
GlobalUserPreferences.loadNewPosts=i.checked; GlobalUserPreferences.loadNewPosts=i.checked;
GlobalUserPreferences.save(); GlobalUserPreferences.save();
})); }));
@@ -154,7 +154,7 @@ public class SettingsFragment extends MastodonToolbarFragment{
items.add(new RedHeaderItem(R.string.settings_spicy)); items.add(new RedHeaderItem(R.string.settings_spicy));
if (GithubSelfUpdater.needSelfUpdating()) { if (GithubSelfUpdater.needSelfUpdating()) {
checkForUpdateItem = new TextItem(R.string.check_for_update, GithubSelfUpdater.getInstance()::checkForUpdates); checkForUpdateItem = new TextItem(R.string.sk_check_for_update, GithubSelfUpdater.getInstance()::checkForUpdates);
items.add(checkForUpdateItem); items.add(checkForUpdateItem);
} }
items.add(new TextItem(R.string.settings_contribute_fork, ()->UiUtils.launchWebBrowser(getActivity(), "https://github.com/sk22/megalodon"))); items.add(new TextItem(R.string.settings_contribute_fork, ()->UiUtils.launchWebBrowser(getActivity(), "https://github.com/sk22/megalodon")));
@@ -396,7 +396,7 @@ public class SettingsFragment extends MastodonToolbarFragment{
} }
if (ev.state == GithubSelfUpdater.UpdateState.NO_UPDATE) { if (ev.state == GithubSelfUpdater.UpdateState.NO_UPDATE) {
Toast.makeText(getActivity(), R.string.no_update_available, Toast.LENGTH_SHORT).show(); Toast.makeText(getActivity(), R.string.sk_no_update_available, Toast.LENGTH_SHORT).show();
} }
} }
@@ -717,12 +717,12 @@ public class SettingsFragment extends MastodonToolbarFragment{
public void onBind(ColorPicker item){ public void onBind(ColorPicker item){
icon.setImageResource(R.drawable.ic_color_theme_preference); icon.setImageResource(R.drawable.ic_color_theme_preference);
button.setText(switch(GlobalUserPreferences.color){ button.setText(switch(GlobalUserPreferences.color){
case PINK -> R.string.pink_color; case PINK -> R.string.sk_color_theme_pink;
case PURPLE -> R.string.purple_color; case PURPLE -> R.string.sk_color_theme_purple;
case GREEN -> R.string.green_color; case GREEN -> R.string.sk_color_theme_green;
case BLUE -> R.string.blue_color; case BLUE -> R.string.sk_color_theme_blue;
case ORANGE -> R.string.orange_color; case ORANGE -> R.string.sk_color_theme_brown;
case YELLOW -> R.string.yellow_color; case YELLOW -> R.string.sk_color_theme_yellow;
}); });
} }
} }

View File

@@ -411,7 +411,7 @@ public class UiUtils{
} }
public static void confirmDeletePost(Activity activity, String accountID, Status status, Consumer<Status> resultCallback, boolean forRedraft){ public static void confirmDeletePost(Activity activity, String accountID, Status status, Consumer<Status> resultCallback, boolean forRedraft){
showConfirmationAlert(activity, forRedraft ? R.string.confirm_delete_and_redraft_title : R.string.confirm_delete_title, forRedraft ? R.string.confirm_delete_and_redraft : R.string.confirm_delete, forRedraft ? R.string.delete_and_redraft : R.string.delete, ()->{ showConfirmationAlert(activity, forRedraft ? R.string.sk_confirm_delete_and_redraft_title : R.string.confirm_delete_title, forRedraft ? R.string.sk_confirm_delete_and_redraft : R.string.confirm_delete, forRedraft ? R.string.sk_delete_and_redraft : R.string.delete, ()->{
new DeleteStatus(status.id) new DeleteStatus(status.id)
.setCallback(new Callback<>(){ .setCallback(new Callback<>(){
@Override @Override
@@ -433,9 +433,9 @@ public class UiUtils{
public static void confirmPinPost(Activity activity, String accountID, Status status, boolean pinned, Consumer<Status> resultCallback){ public static void confirmPinPost(Activity activity, String accountID, Status status, boolean pinned, Consumer<Status> resultCallback){
showConfirmationAlert(activity, showConfirmationAlert(activity,
pinned ? R.string.confirm_pin_post_title : R.string.confirm_unpin_post_title, pinned ? R.string.sk_confirm_pin_post_title : R.string.sk_confirm_unpin_post_title,
pinned ? R.string.confirm_pin_post : R.string.confirm_unpin_post, pinned ? R.string.sk_confirm_pin_post : R.string.sk_confirm_unpin_post,
pinned ? R.string.pin_post : R.string.unpin_post, pinned ? R.string.sk_pin_post : R.string.sk_unpin_post,
()->{ ()->{
new SetStatusPinned(status.id, pinned) new SetStatusPinned(status.id, pinned)
.setCallback(new Callback<>() { .setCallback(new Callback<>() {
@@ -452,7 +452,7 @@ public class UiUtils{
error.showToast(activity); error.showToast(activity);
} }
}) })
.wrapProgress(activity, pinned ? R.string.pinning : R.string.unpinning, false) .wrapProgress(activity, pinned ? R.string.sk_pinning : R.string.sk_unpinning, false)
.exec(accountID); .exec(accountID);
} }
); );
@@ -508,7 +508,7 @@ public class UiUtils{
public void onSuccess(Relationship result) { public void onSuccess(Relationship result) {
resultCallback.accept(result); resultCallback.accept(result);
progressCallback.accept(false); progressCallback.accept(false);
Toast.makeText(activity, activity.getString(result.notifying ? R.string.user_post_notifications_on : R.string.user_post_notifications_off, '@'+account.username), Toast.LENGTH_SHORT).show(); Toast.makeText(activity, activity.getString(result.notifying ? R.string.sk_user_post_notifications_on : R.string.sk_user_post_notifications_off, '@'+account.username), Toast.LENGTH_SHORT).show();
} }
@Override @Override

View File

@@ -27,7 +27,7 @@
android:textSize="16sp" android:textSize="16sp"
android:singleLine="true" android:singleLine="true"
android:ellipsize="end" android:ellipsize="end"
android:text="@string/settings_color_picker"/> android:text="@string/sk_settings_color_picker"/>
<Button <Button
android:id="@+id/color_picker_button" android:id="@+id/color_picker_button"
@@ -41,6 +41,6 @@
android:stateListAnimator="@null" android:stateListAnimator="@null"
android:textColor="?android:textColorPrimary" android:textColor="?android:textColorPrimary"
android:textSize="16sp" android:textSize="16sp"
tools:text="@string/pink_color" /> tools:text="@string/sk_color_theme_pink" />
</org.joinmastodon.android.ui.views.AutoOrientationLinearLayout> </org.joinmastodon.android.ui.views.AutoOrientationLinearLayout>

View File

@@ -1,9 +1,9 @@
<?xml version="1.0" encoding="utf-8"?> <?xml version="1.0" encoding="utf-8"?>
<menu xmlns:android="http://schemas.android.com/apk/res/android"> <menu xmlns:android="http://schemas.android.com/apk/res/android">
<item android:id="@+id/purple_color" android:title="@string/purple_color"/> <item android:id="@+id/purple_color" android:title="@string/sk_color_theme_purple"/>
<item android:id="@+id/pink_color" android:title="@string/pink_color"/> <item android:id="@+id/pink_color" android:title="@string/sk_color_theme_pink"/>
<item android:id="@+id/green_color" android:title="@string/green_color"/> <item android:id="@+id/green_color" android:title="@string/sk_color_theme_green"/>
<item android:id="@+id/blue_color" android:title="@string/blue_color"/> <item android:id="@+id/blue_color" android:title="@string/sk_color_theme_blue"/>
<item android:id="@+id/orange_color" android:title="@string/orange_color"/> <item android:id="@+id/orange_color" android:title="@string/sk_color_theme_brown"/>
<item android:id="@+id/yellow_color" android:title="@string/yellow_color"/> <item android:id="@+id/yellow_color" android:title="@string/sk_color_theme_yellow"/>
</menu> </menu>

View File

@@ -397,13 +397,13 @@
<string name="settings_always_reveal_content_warnings">Always reveal content warnings</string> <string name="settings_always_reveal_content_warnings">Always reveal content warnings</string>
<string name="disable_marquee">Disable scrolling text in title bars</string> <string name="disable_marquee">Disable scrolling text in title bars</string>
<string name="settings_contribute_fork">Contribute to Moshidon</string> <string name="settings_contribute_fork">Contribute to Moshidon</string>
<string name="settings_color_picker">Color theme:</string> <!-- <string name="settings_color_picker">Color theme:</string>-->
<string name="pink_color">Pink</string> <!-- <string name="pink_color">Pink</string>-->
<string name="purple_color">Purple</string> <!-- <string name="purple_color">Purple</string>-->
<string name="green_color">Green</string> <!-- <string name="green_color">Green</string>-->
<string name="blue_color">Blue</string> <!-- <string name="blue_color">Blue</string>-->
<string name="orange_color">Orange</string> <!-- <string name="orange_color">Orange</string>-->
<string name="yellow_color">Yellow</string> <!-- <string name="yellow_color">Yellow</string>-->
<string name="translate">Translate</string> <string name="translate">Translate</string>
<string name="login_title">Welcome Back</string> <string name="login_title">Welcome Back</string>
<string name="login_subtitle">Log in with the server where you created your account.</string> <string name="login_subtitle">Log in with the server where you created your account.</string>
@@ -411,44 +411,44 @@
<!-- <string name="app_name">Megalodon</string>--> <!-- <string name="app_name">Megalodon</string>-->
<string name="pinned_posts">Pinned</string> <!-- <string name="pinned_posts">Pinned</string>-->
<string name="delete_and_redraft">Delete and re-draft</string> <!-- <string name="delete_and_redraft">Delete and re-draft</string>-->
<string name="confirm_delete_and_redraft_title">Delete and re-draft Post</string> <!-- <string name="confirm_delete_and_redraft_title">Delete and re-draft Post</string>-->
<string name="confirm_delete_and_redraft">Are you sure you want to delete and re-draft this post?</string> <!-- <string name="confirm_delete_and_redraft">Are you sure you want to delete and re-draft this post?</string>-->
<string name="pin_post">Pin to profile</string> <!-- <string name="pin_post">Pin to profile</string>-->
<string name="confirm_pin_post_title">Pin post to profile</string> <!-- <string name="confirm_pin_post_title">Pin post to profile</string>-->
<string name="confirm_pin_post">Do you want to pin this post to your profile?</string> <!-- <string name="confirm_pin_post">Do you want to pin this post to your profile?</string>-->
<string name="pinning">Pinning post…</string> <!-- <string name="pinning">Pinning post…</string>-->
<string name="unpin_post">Unpin from profile</string> <!-- <string name="unpin_post">Unpin from profile</string>-->
<string name="confirm_unpin_post_title">Unpin post from profile</string> <!-- <string name="confirm_unpin_post_title">Unpin post from profile</string>-->
<string name="confirm_unpin_post">Are you sure you want to unpin this post?</string> <!-- <string name="confirm_unpin_post">Are you sure you want to unpin this post?</string>-->
<string name="unpinning">Unpinning post…</string> <!-- <string name="unpinning">Unpinning post…</string>-->
<string name="image_description">Image description</string> <!-- <string name="image_description">Image description</string>-->
<string name="visibility_unlisted">Unlisted</string> <!-- <string name="visibility_unlisted">Unlisted</string>-->
<string name="settings_show_replies">Show replies</string> <!-- <string name="settings_show_replies">Show replies</string>-->
<string name="settings_show_boosts">Show boosts</string> <!-- <string name="settings_show_boosts">Show boosts</string>-->
<string name="settings_load_new_posts">Automatically load new posts</string> <!-- <string name="settings_load_new_posts">Automatically load new posts</string>-->
<string name="settings_show_interaction_counts">Show interaction counts</string> <!-- <string name="settings_show_interaction_counts">Show interaction counts</string>-->
<!-- <string name="settings_app_version">Megalodon v%1$s (%2$d)</string>--> <!--&lt;!&ndash; <string name="settings_app_version">Megalodon v%1$s (%2$d)</string>&ndash;&gt;-->
<string name="mark_media_as_sensitive">Mark media as sensitive</string> <!-- <string name="mark_media_as_sensitive">Mark media as sensitive</string>-->
<string name="user_post_notifications_on">Turned on post notifications for %s</string> <!-- <string name="user_post_notifications_on">Turned on post notifications for %s</string>-->
<string name="user_post_notifications_off">Turned off post notifications for %s</string> <!-- <string name="user_post_notifications_off">Turned off post notifications for %s</string>-->
<string name="federated_timeline">Federation</string> <!-- <string name="federated_timeline">Federation</string>-->
<string name="federated_timeline_info_banner">These are the most recent posts by the people in your federation.</string> <!-- <string name="federated_timeline_info_banner">These are the most recent posts by the people in your federation.</string>-->
<!-- <string name="update_available">Megalodon %s is ready to download.</string>--> <!--&lt;!&ndash; <string name="update_available">Megalodon %s is ready to download.</string>&ndash;&gt;-->
<!-- <string name="update_ready">Megalodon %s is downloaded and ready to install.</string>--> <!--&lt;!&ndash; <string name="update_ready">Megalodon %s is downloaded and ready to install.</string>&ndash;&gt;-->
<string name="check_for_update">Check for update</string> <!-- <string name="check_for_update">Check for update</string>-->
<string name="no_update_available">No update available</string> <!-- <string name="no_update_available">No update available</string>-->
<string name="list_timelines">Lists</string> <!-- <string name="list_timelines">Lists</string>-->
<string name="follow_requests">Follow requests</string> <!-- <string name="follow_requests">Follow requests</string>-->
<string name="accept_follow_request">Accept follow request</string> <!-- <string name="accept_follow_request">Accept follow request</string>-->
<string name="reject_follow_request">Reject follow request</string> <!-- <string name="reject_follow_request">Reject follow request</string>-->
<string name="lists_with_user">Lists with %s</string> <!-- <string name="lists_with_user">Lists with %s</string>-->
<!-- <string name="settings_always_reveal_content_warnings">Always reveal content warnings</string>--> <!--&lt;!&ndash; <string name="settings_always_reveal_content_warnings">Always reveal content warnings</string>&ndash;&gt;-->
<!-- <string name="disable_marquee">Disable scrolling text in title bars</string>--> <!--&lt;!&ndash; <string name="disable_marquee">Disable scrolling text in title bars</string>&ndash;&gt;-->
<!-- <string name="settings_contribute">Contribute to Megalodon</string>--> <!--&lt;!&ndash; <string name="settings_contribute">Contribute to Megalodon</string>&ndash;&gt;-->
<string name="settings_show_federated_timeline">Show federated timeline</string> <!-- <string name="settings_show_federated_timeline">Show federated timeline</string>-->
<string name="notification_type_status">Posts</string> <!-- <string name="notification_type_status">Posts</string>-->
<string name="notify_posts">Post notifications</string> <!-- <string name="notify_posts">Post notifications</string>-->
</resources> </resources>

View File

@@ -1,6 +1,6 @@
<?xml version="1.0" encoding="utf-8"?> <?xml version="1.0" encoding="utf-8"?>
<resources> <resources>
<string name="sk_app_name">Megalodon</string> <string name="sk_app_name" translatable="false">Moshidon</string>
<string name="sk_pinned_posts">Pinned</string> <string name="sk_pinned_posts">Pinned</string>
<string name="sk_delete_and_redraft">Delete and re-draft</string> <string name="sk_delete_and_redraft">Delete and re-draft</string>
<string name="sk_confirm_delete_and_redraft_title">Delete and re-draft Post</string> <string name="sk_confirm_delete_and_redraft_title">Delete and re-draft Post</string>
@@ -25,8 +25,8 @@
<string name="sk_user_post_notifications_off">Turned off post notifications for %s</string> <string name="sk_user_post_notifications_off">Turned off post notifications for %s</string>
<string name="sk_federated_timeline">Federation</string> <string name="sk_federated_timeline">Federation</string>
<string name="sk_federated_timeline_info_banner">These are the most recent posts by the people in your federation.</string> <string name="sk_federated_timeline_info_banner">These are the most recent posts by the people in your federation.</string>
<string name="sk_update_available">Megalodon %s is ready to download.</string> <string name="sk_update_available">Moshidon %s is ready to download.</string>
<string name="sk_update_ready">Megalodon %s is downloaded and ready to install.</string> <string name="sk_update_ready">Moshidon %s is downloaded and ready to install.</string>
<string name="sk_check_for_update">Check for update</string> <string name="sk_check_for_update">Check for update</string>
<string name="sk_no_update_available">No update available</string> <string name="sk_no_update_available">No update available</string>
<string name="sk_list_timelines">Lists</string> <string name="sk_list_timelines">Lists</string>
@@ -45,6 +45,6 @@
<string name="sk_color_theme_purple">Purple</string> <string name="sk_color_theme_purple">Purple</string>
<string name="sk_color_theme_green">Green</string> <string name="sk_color_theme_green">Green</string>
<string name="sk_color_theme_blue">Blue</string> <string name="sk_color_theme_blue">Blue</string>
<string name="sk_color_theme_brown">Brown</string> <string name="sk_color_theme_brown">Orange</string>
<string name="sk_color_theme_yellow">Yellow</string> <string name="sk_color_theme_yellow">Yellow</string>
</resources> </resources>