Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Removed hardcoded strings in DeleteHelper #3047

Merged
merged 2 commits into from
Jul 2, 2019
Merged

Removed hardcoded strings in DeleteHelper #3047

merged 2 commits into from
Jul 2, 2019

Conversation

PavelAplevich
Copy link
Contributor

@PavelAplevich PavelAplevich commented Jul 1, 2019

Fixes #3050
Welcome from Belarus!) I'm beginner in programming for Android. And this is my first open-source project.
I hope I can be helpful in this project.

Fixes hardcoded strings in delete/DeleteHelper.java

A small change in the class for the possibility of localization of strings. Adding these strings with localization in Russian.

Tested on Xiaomi Redmi4x and Nexus One(emulator) with API level 25 and 22.
Снимок экрана от 2019-07-01 17-55-28

photo_2019-07-01_17-58-57

Copy link

@pullrequest pullrequest bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

✅ A review job has been created and sent to the PullRequest network.


@PavelAplevich you can click here to see the review status or cancel the code review job.

Copy link

@tests-checker tests-checker bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Could you please add tests to make sure this change works as expected?

@codecov-io
Copy link

codecov-io commented Jul 1, 2019

Codecov Report

Merging #3047 into master will not change coverage.
The diff coverage is 0%.

Impacted file tree graph

@@          Coverage Diff           @@
##           master   #3047   +/-   ##
======================================
  Coverage    4.41%   4.41%           
======================================
  Files         259     259           
  Lines       12309   12309           
  Branches     1056    1056           
======================================
  Hits          544     544           
  Misses      11726   11726           
  Partials       39      39
Impacted Files Coverage Δ
.../java/fr/free/nrw/commons/delete/DeleteHelper.java 52.27% <0%> (ø) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update cc92773...4176646. Read the comment docs.

Copy link
Collaborator

@neslihanturan neslihanturan left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hi @PavelAplevich , welcome to team! Please see my minor review. Everything else seems fine to me:)

@@ -547,4 +547,12 @@
<string name="dialog_box_text_nomination">Почему %1$s должно быть удалено?</string>
<string name="review_is_uploaded_by">%1$s загружено с помощью: %2$s</string>
<string name="default_description_language">Язык описаний по умолчанию</string>
<string name="delete_reason_spam_selfie">Селфи</string>
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Removing hard coded strings and inserting them into strings.xml is perfectly fine. But we don't edit language specific strings.xml files manually. We just edit the default one ( app/src/main/res/values/strings.xml) as you also did. For outher languages we have translator updates. Please revert changes in this file.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Done

@neslihanturan
Copy link
Collaborator

Thanks @PavelAplevich and congrats for your first contribution! 🎉

@neslihanturan neslihanturan merged commit 6fb3331 into commons-app:master Jul 2, 2019
@PavelAplevich
Copy link
Contributor Author

@neslihanturan
I will be glad to help you) Thank you

VitalyVPinchuk pushed a commit to VitalyVPinchuk/apps-android-commons that referenced this pull request Jul 12, 2019
* Removed hardcoded strings in DeleteHelper

* Revert "Removed hardcoded strings in DeleteHelper"

This reverts commit 4bc55fc.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Remove hard coded strngs in delete helper
4 participants