mirror of
https://github.com/commons-app/apps-android-commons.git
synced 2025-10-26 20:33:53 +01:00
parent
1d80cbaac9
commit
db38174eb4
6 changed files with 12 additions and 8 deletions
|
|
@ -252,13 +252,14 @@ public class UploadActivity extends AuthenticatedActivity implements UploadView,
|
|||
|
||||
@SuppressLint("StringFormatInvalid")
|
||||
@Override
|
||||
public void updateLicenseSummary(String selectedLicense) {
|
||||
public void updateLicenseSummary(String selectedLicense, int imageCount) {
|
||||
String licenseHyperLink = "<a href='" + Utils.licenseUrlFor(selectedLicense)+"'>" +
|
||||
getString(Utils.licenseNameFor(selectedLicense)) + "</a><br>";
|
||||
licenseSummary.setMovementMethod(LinkMovementMethod.getInstance());
|
||||
licenseSummary.setText(
|
||||
Html.fromHtml(
|
||||
getString(R.string.share_license_summary, licenseHyperLink)));
|
||||
getResources().getQuantityString(R.plurals.share_license_summary,
|
||||
imageCount, licenseHyperLink)));
|
||||
}
|
||||
|
||||
@Override
|
||||
|
|
|
|||
|
|
@ -112,7 +112,7 @@ public class UploadPresenter {
|
|||
*/
|
||||
void selectLicense(String licenseName) {
|
||||
uploadModel.setSelectedLicense(licenseName);
|
||||
view.updateLicenseSummary(uploadModel.getSelectedLicense());
|
||||
view.updateLicenseSummary(uploadModel.getSelectedLicense(), uploadModel.getCount());
|
||||
}
|
||||
|
||||
//region Wizard step management
|
||||
|
|
@ -357,7 +357,7 @@ public class UploadPresenter {
|
|||
private void updateLicenses() {
|
||||
String selectedLicense = uploadModel.getSelectedLicense();
|
||||
view.updateLicenses(uploadModel.getLicenses(), selectedLicense);
|
||||
view.updateLicenseSummary(selectedLicense);
|
||||
view.updateLicenseSummary(selectedLicense, uploadModel.getCount());
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
|
|||
|
|
@ -60,7 +60,7 @@ public interface UploadView {
|
|||
|
||||
void updateLicenses(List<String> licenses, String selectedLicense);
|
||||
|
||||
void updateLicenseSummary(String selectedLicense);
|
||||
void updateLicenseSummary(String selectedLicense, int imageCount);
|
||||
|
||||
void updateTopCardContent();
|
||||
|
||||
|
|
|
|||
|
|
@ -62,7 +62,7 @@
|
|||
android:layout_marginEnd="@dimen/standard_gap"
|
||||
android:layout_marginRight="@dimen/standard_gap"
|
||||
android:layout_below="@id/license_list"
|
||||
android:text="@string/share_license_summary" />
|
||||
android:text="@plurals/share_license_summary" />
|
||||
|
||||
<fr.free.nrw.commons.ui.widget.HtmlTextView
|
||||
android:id="@+id/media_upload_policy"
|
||||
|
|
|
|||
|
|
@ -87,7 +87,7 @@
|
|||
android:layout_marginTop="@dimen/standard_gap"
|
||||
android:clickable="true"
|
||||
android:gravity="center"
|
||||
android:text="@string/share_license_summary"
|
||||
android:text="@plurals/share_license_summary"
|
||||
android:textColorLink="@color/button_blue" />
|
||||
|
||||
<fr.free.nrw.commons.ui.widget.HtmlTextView
|
||||
|
|
|
|||
|
|
@ -101,7 +101,10 @@
|
|||
<string name="no_uploads_yet">You have not yet uploaded any photos.</string>
|
||||
<string name="menu_retry_upload">Retry</string>
|
||||
<string name="menu_cancel_upload">Cancel</string>
|
||||
<string name="share_license_summary">This image will be licensed under %1$s</string>
|
||||
<plurals name="share_license_summary">
|
||||
<item quantity="one">This image will be licensed under %1$s</item>
|
||||
<item quantity="other">These images will be licensed under %1$s</item>
|
||||
</plurals>
|
||||
<string name="media_upload_policy">By submitting this picture, I declare that this is my own work, that it does not contain copyrighted material or selfies, and otherwise adheres to <a href=\"https://commons.wikimedia.org/wiki/Commons:Policies_and_guidelines\">Wikimedia Commons policies</a>.</string>
|
||||
<string name="menu_download">Download</string>
|
||||
<string name="preference_license">Default License</string>
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue