Skip to content

Commit

Permalink
Wrap translator name in parentheses
Browse files Browse the repository at this point in the history
  • Loading branch information
ahmedre committed May 23, 2017
1 parent 2bbfa7c commit d64bbe9
Showing 1 changed file with 3 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -53,8 +53,9 @@ public static String getShareText(Context context,

for (int i = 0, size = ayahInfo.texts.size(); i < size; i++) {
if (i < translationNames.length) {
sb.append(translationNames[i])
.append('\n');
sb.append('(')
.append(translationNames[i])
.append(")\n");

This comment has been minimized.

Copy link
@naveed-ahmad

naveed-ahmad May 23, 2017

Collaborator

this was one of many reason why I stopped writing Android app and shifted to Ruby :D
"(#{translationNames[i]})"

This comment has been minimized.

Copy link
@ahmedre

ahmedre May 23, 2017

Author Contributor

so we can have you back insha'Allah once we switch the codebase to use Kotlin :) it's much nicer and supports that!

This comment has been minimized.

Copy link
@ozbek

ozbek May 23, 2017

Contributor

Yeap, bad habits (i.e., lazyness) die last :P

@ahmedre could actually add a string literal

<string name="translator_name_wrapped_in_parantheses" translatable="false">[%s]</string>

and use

getString(R.string.translator_name_wrapped_in_parantheses, translationNames[i]);

This comment has been minimized.

Copy link
@ahmedre

ahmedre May 23, 2017

Author Contributor

touche :D

}
sb.append(ayahInfo.texts.get(i))
.append("\n\n");
Expand Down

0 comments on commit d64bbe9

Please sign in to comment.