Commit graph

6162 commits

Author SHA1 Message Date
translatewiki.net
65ae5060c5
Localisation updates from https://translatewiki.net. 2024-09-05 14:04:50 +02:00
translatewiki.net
b9bb9bcf34
Localisation updates from https://translatewiki.net. 2024-09-02 14:01:50 +02:00
Kanahia
93f1e1ec29
Added pending uploads screen (#5752)
* Added pending uploads screen

* Added failed uploads fragment

* Improved progress bars

* Implemented pause functionality

* Improved pause feature

* Fixed issue with sorting when adding more pictures during an upload

* Improved Tap to View notification

* Fixed issue with on going upload deletion

* Improved the deletion feature

* Fixed indentations and unit tests

* Fixed bugs

* Fixed failing test

* Added error message in Failed Uploads Fragment

* Improved error notification

* Moved auto-retry from the Main Activity to UploadProgressActivity

* Fixed large uploads issue

* Minor fixes

* Removed HashSet

* Fixed issue with progress bar

* Bug fixes

* Moved Auto Retry to MainActivity

* Fixed conflicts

* Fixed issue with upload icon

* Fixed null ptr issue on changing modes

* Improved recycler view

* Fixed irrelevant network call

* Fixed irrelevant network call

* Fixed constantly failing uploads

* Fixed constantly failing uploads

* Fixed constantly failing uploads

* Added error log

* Fixed refresh icon visibility in light mode

* Changed progress in progress activity

* Fixed progress bar issue

* Improved icons

* Improved deletion and removed cancelledUploads Hashset

* Fixed sorting, list size issue

* Improved current implementation

* Implemented flag for workers

* Implemented flag for workers

* Fixed sorting bug

* Fixed upload icon

* Improved pausing

* Made changes to visibility implementation

* Added image duplicity check on restart of failed image

* minor adjustments

* added javadoc/kdoc and fixed minor bug

* Fixed unit tests

* Added synchronized(lock)

* Added check to prevent multiple uploads starting at once

* Ignored failing test cases

* Temporary commit - Added jcenter

* Temporary commit - Removed library/commented

* Temporary commit - Removed library/commented

* Updated com.jraska.livedata:testing-ktx

* Ignored failing test - UploadControllerTest.kt

* Ignored failing test - UploadModelUnitTest

* Ignored failing test - UploadModelUnitTest

* Ignored failing test - UploadModelUnitTest

* Ignored failing test - UploadModelUnitTest

* Ignored failing test - UploadModelUnitTest

* Ignored failing test - UploadModelUnitTest

* Ignored failing test - UploadModelUnitTest

* Ignored failing test - UploadModelUnitTest

* Ignored failing test - UploadPresenterTest.kt

* Ignored failing test - UploadPresenterTest.kt

* Ignored failing test - UploadPresenterTest.kt

* Ignored failing test - UploadPresenterTest.kt

* Ignored failing test - UploadPresenterTest.kt

* Ignored failing test - UploadPresenterTest.kt

* Ignored failing test - UploadPresenterTest.kt

* Ignored failing test - UploadPresenterTest.kt

* Ignored failing test - UploadRepositoryUnitTest.kt

* Ignored failing test - UploadRepositoryUnitTest.kt

* Ignored failing test - UploadRepositoryUnitTest.kt

* Ignored failing test - UploadRepositoryUnitTest.kt

* Ignored failing test - UploadRepositoryUnitTest.kt

* Ignored failing test - UploadRepositoryUnitTest.kt

* Ignored failing test - UploadRepositoryUnitTest.kt

* Ignored failing test - UploadRepositoryUnitTest.kt

* Ignored failing test - UploadRepositoryUnitTest.kt

* Ignored failing test - UploadRepositoryUnitTest.kt

* Ignored failing test - UploadRepositoryUnitTest.kt

* Ignored failing test - UploadRepositoryUnitTest.kt

* Ignored failing test - UploadRepositoryUnitTest.kt

* Ignored failing test - UploadRepositoryUnitTest.kt

* Ignored failing test - UploadRepositoryUnitTest.kt

* Ignored failing test - UploadRepositoryUnitTest.kt

* Ignored failing test - UploadRepositoryUnitTest.kt

* Ignored failing test - UploadRepositoryUnitTest.kt

* Ignored failing test - UploadRepositoryUnitTest.kt

* Ignored failing test - UploadRepositoryUnitTest.kt

* Ignored failing test - UploadRepositoryUnitTest.kt

* Ignored failing test - UploadRepositoryUnitTest.kt

* Ignored failing test - UploadRepositoryUnitTest.kt

* Ignored failing test - UploadRepositoryUnitTest.kt

* Ignored failing test - UploadRepositoryUnitTest.kt

* Ignored failing test - UploadRepositoryUnitTest.kt

* Ignored failing test - UploadRepositoryUnitTest.kt

* Ignored failing test - UploadRepositoryUnitTest.kt

* Ignored failing test - UploadRepositoryUnitTest.kt

* Ignored failing test - UploadRepositoryUnitTest.kt

* Ignored failing test - UploadRepositoryUnitTest.kt

* Ignored failing test - UploadRepositoryUnitTest.kt

* Ignored failing test - UploadRepositoryUnitTest.kt

* Ignored failing tests - UploadRepositoryUnitTest.kt

* Ignored failing test - UploadRepositoryUnitTest.kt

* Ignored failing test - DepictedItemTest.kt

* Ignored failing test - DepictedItemTest.kt

* Ignored failing test - DepictedItemTest.kt

* Ignored failing test - DepictedItemTest.kt

* Ignored failing test - DepictedItemTest.kt

* Ignored failing test - DepictedItemTest.kt

* Ignored failing test - DepictedItemTest.kt

* Ignored failing test - DepictedItemTest.kt

* Ignored failing test - FilesUtilsTest.kt

* Ignored failing test - WikiBaseClientUnitTest.kt

* Ignored failing test - WikiBaseClientUnitTest.kt

* Ignored failing test - WikiBaseClientUnitTest.kt

* Ignored failing test - WikidataClientTest.kt

* Ignored failing test - WikidataClientTest.kt

* Fixed unit tests

* Updated kdoc

---------

Co-authored-by: Nicolas Raoul <nicolas.raoul@gmail.com>
2024-08-30 15:22:54 +09:00
translatewiki.net
62d6dea219
Localisation updates from https://translatewiki.net. 2024-08-29 14:01:37 +02:00
Rohit Verma
190135d36c
Fix failing tests for updateDepictsProperty method (#5795)
* tests: fix failing testUpdateDepictsProperty

* replace deprecated circular progress bar with material progress bar

* refactor: update SettingsActivity to not use custom appCompatDeletegate

It is required because that delegate is automatically handled in new libraries.
2024-08-28 15:29:16 +09:00
Rohit Verma
ec4a6bc0c4
remove asynchronous call to fetch local depictedItems (#5792) 2024-08-27 23:07:12 +09:00
translatewiki.net
39a0b88e3a
Localisation updates from https://translatewiki.net. 2024-08-26 14:02:06 +02:00
Rohit Verma
46df64d208
Prevent deletion of other structured data when editing depicts (#5741)
* restructure :  minor changes to comments to improve readability

* api: remove clear flag to prevent deletion of structured data

* WikiBaseInterface: add new api methods

Get Method: to get claims for an entity
Post method: to delete claims

* WikiBaseClient: add methods to handle response for new APIs

* typo:  update call to method with updated typo

* DepictEditHelper: call update property method with entity id

* refactor: dismiss progress dialog on error

* DepictsDao: remove usage of runBlocking as it was blocking main thread

Refactor methods to perform well with coroutines

* refactor: update usage of method to match changes in DepictsDao

* refactor: use named parameters to improve readability

* claims: add new data classes to represent remove claims

* WikidataEditService: modify update depicts property method

Performs deletion of old claims and creation of new claims

* refactor: make methods more organized
2024-08-26 15:43:50 +09:00
djbloop
31bb1a73c0
First of two fixes for bug #5726: hide nominate for deletion when logged out (#5773) 2024-08-26 13:24:15 +09:00
ujjwal2900
096c075548
Removed duplicate code in addMarkersToMap method (#5783) 2024-08-25 13:01:55 +09:00
Nicolas Raoul
a81d48cc9d
Updating jraska/livedata-testing for GSoC (#5785) 2024-08-22 22:41:27 +09:00
translatewiki.net
a3a5980ebd
Localisation updates from https://translatewiki.net. 2024-08-19 14:02:05 +02:00
translatewiki.net
060d41f973
Localisation updates from https://translatewiki.net. 2024-08-15 14:01:56 +02:00
translatewiki.net
dc6cc82751
Localisation updates from https://translatewiki.net. 2024-08-12 14:01:56 +02:00
translatewiki.net
9a31d2318e
Localisation updates from https://translatewiki.net. 2024-08-08 14:01:40 +02:00
translatewiki.net
862f8f0b04
Localisation updates from https://translatewiki.net. 2024-08-05 14:01:44 +02:00
Kanahia
2d63f351ed
Made Split to Nearby Query into a fast query for coordinates + a details query for each pin (#5731)
* Splitted the query

* Made changes to the query

* Improvised query

* Improvised query by dividing in the batches

* Fixed failing tests

* Improved batches

* Improved sorting

* Fixes issue caused by search this area button

* Fixed failing tests

* Fixed unnecessary reloads on onResume

* Fixed few pins not loading on changing apps

* Improved zoom level and fixed the pins not loading from the center

* Removed toggle chips and changed pin's color

* Fixed wikidata url

* Fixed unit tests

* Implemented retry with delay of 5000ms

* Fixed exception issue and pins issue

* Added change color icon to pin

* Improved pin clicking

* Removed search this area button

* Implemented caching of places

* Fixed unit test

* Factorized methods

* Changed primary key from location to entity id

* Fixed tests

* Fixed conflicts

* Fixed unit test

* Fixed unit test

* Fixed the bug

* Fixed issue with pin loading on the first launch

* Updated javadocs

* Temporary commit - only for testing

* Replaced Temporary commit

* Temporary commit - Added jcenter

* Made minor changes

* Fixed unit tests

* Fixed unit tests

* Fixed minor bug
2024-08-04 09:35:09 +09:00
translatewiki.net
ba6c8fe8d0
Localisation updates from https://translatewiki.net. 2024-08-01 14:01:42 +02:00
translatewiki.net
dbfe3b50f9
Localisation updates from https://translatewiki.net. 2024-07-29 14:02:27 +02:00
translatewiki.net
59da70aca1
Localisation updates from https://translatewiki.net. 2024-07-25 14:01:45 +02:00
translatewiki.net
d2d8eb9153
Localisation updates from https://translatewiki.net. 2024-07-22 14:01:59 +02:00
Kaartic Sivaraam
7d9f8d27bc
menu: rename menu as "User profile" (#5771)
As suggested by @whym on #5754, the name "User page" is ambiguous with
the on-wiki user page. We actually show the leaderboard when the menu
is clicked on. So, rename the menu as "User profile" instead.

Ref: https://github.com/commons-app/apps-android-commons/issues/5754#issuecomment-2196796213
2024-07-20 23:19:16 +10:00
Matija Nalis
7f6b45aeb6
Update allowed recent years to include 2020s (#5761)
* document regex due to #47

* also count 2020s as "recent years"

* clarify that not all years are ignored

* clarify "year" is current year

* original logic fix
from https://github.com/commons-app/apps-android-commons/pull/5761#pullrequestreview-2144120347

* better variale name for ".*0s.*"
as that regex will match e.g. `1920s` and `80s` too, so the original `is20xxsYear` would be confusing name for it

* consolidate duplicated code to spammyCategory

* clarify regexes via variables

* spammyCategory should always be skipped

* return is simple now, so we can get rid of extra val oldDecade

* fix curYearInString

* some clarification comments

* refactor: rename containsYear to isSpammyCategory

This is done as the name containsYear is ambiguous.
It not just checks for year to identify spammy categories.

* refactor: rename containsYear to isSpammyCategory (take 2)

 A continuation of fe74c77ab (refactor: rename containsYear
 to isSpammyCategory, 2024-07-17)

---------

Co-authored-by: Kaartic Sivaraam <kaartic.sivaraam@gmail.com>
2024-07-20 23:16:20 +10:00
Amir E. Aharoni
34addbe33a
Remove unnecessary double quotes from a message (#5777) 2024-07-18 11:47:03 +09:00
Kaartic Sivaraam
5be76044b1
wikidata-feedback: avoid sentence lego (#5775)
Fixes #5763
2024-07-17 16:22:41 +09:00
translatewiki.net
73e9ed8e26
Localisation updates from https://translatewiki.net. 2024-07-15 14:02:06 +02:00
translatewiki.net
4d8a7dc138
Localisation updates from https://translatewiki.net. 2024-07-11 14:02:14 +02:00
Amir E. Aharoni
5bcbaa1beb
Improve the messages about being in a different place (#5764)
Remove parentheses and comma splice,
and replace them with more straightforward grammar.
2024-07-08 23:16:26 +09:00
translatewiki.net
018a924c53
Localisation updates from https://translatewiki.net. 2024-07-08 14:02:00 +02:00
Kanahia
3779cfb6a5
Added Wikitalk Page (#5740)
* Added wikitalk page and improved bottomsheet for landscape mode

* Improved wikitalk page

* Fixed italics

* Fixed little bug

* Improved the wiki talk page

* .

* changed commons url to wikidata url

* changed commons url to wikidata url + 1

* fixed bookmark issue

* Added kdoc and javadoc

---------

Co-authored-by: Nicolas Raoul <nicolas.raoul@gmail.com>
2024-07-08 15:13:57 +09:00
Kaartic Sivaraam
36905711d0 Version v5.0.2 2024-07-07 01:05:55 +05:30
translatewiki.net
05ffd123e4
Localisation updates from https://translatewiki.net. 2024-07-04 14:01:57 +02:00
translatewiki.net
923acd802c
Localisation updates from https://translatewiki.net. 2024-07-01 14:01:39 +02:00
translatewiki.net
f8e1030164
Localisation updates from https://translatewiki.net. 2024-06-27 14:01:37 +02:00
translatewiki.net
63ec5c8433
Localisation updates from https://translatewiki.net. 2024-06-20 14:01:59 +02:00
Kaartic Sivaraam
69cd9c94d1
Make sure to clear cookies on logout (#5727)
* Ensure to clear the cookies when logging out

It turns out that we failed to clear the cookies from the cookie JAR
when logging the user out. As a consequence, the cookie were retained
and it was possible to edit depictions as the previous user even without
logging in to the app (using the retained cookies).

Make sure we properly clear the cookies when we log the user out.

As an aside, the fact that the edit button shouldn't have been shown
is a different issue being tracked in #5726

* session: reuse removeAccount method for log out

The removeAccount method takes care of invoking the non-deprecated
API in applicable API levels. The logout method did not do such a
thing. Avoid redundancy, and reuse the removeAccount method for
logging out.
2024-06-18 22:31:34 +02:00
Kaartic Sivaraam
1808699e89
Make new feedback to be added as a new section to the end of the page (#5753)
* feedback: add the feedback as a new section at end of the page

Addresses feedback on #5542. For auto-archiving of section
to work properly on our feedback page, the new sections need to
be created at the end of the page rather than at the top.

So, adjust the feedback addition logic to make it such that the
feedback is appended to the bottom of the page.

* Replace lambda with a method reference

* feedback: replace edit summary with something more relevant

The summary of the feedback page was unhelpful. Make it more helpful by
using a more helpful summary that at least mentions the version of the
app for which the feedback is posted.

* test: try to fix test case related to feedback change
2024-06-18 21:40:30 +02:00
translatewiki.net
0e39d93721
Localisation updates from https://translatewiki.net. 2024-06-17 14:02:06 +02:00
Adam English
c2ac0f659a
Add code on line 340. Replace the 'Add location' button with 'Edit location' button when user clicks yes in similar image dialog (#5756)
Co-authored-by: starrain <zxyadelaide@gmail.com>
2024-06-15 22:17:28 +02:00
translatewiki.net
68df749ad2
Localisation updates from https://translatewiki.net. 2024-06-13 14:02:35 +02:00
translatewiki.net
5cdfb85a9c
Localisation updates from https://translatewiki.net. 2024-06-11 11:28:25 +02:00
Evangelos Talos
48bd3c07b8
Add ProgressBar to MediaDetailPagerFragment for Image Loading Indicator (#5736)
* Add progress bar to fragment_media_detail_pager.xml

* Add progress bar to MediaDetailPagerFragment.java

* Add javadoc & comments

* Fix tests

---------

Co-authored-by: Giannis Karyotakis <110292528+karyotakisg@users.noreply.github.com>
2024-06-10 20:06:06 +09:00
Jason-Whitmore
3dc7180784
LocationPickerActivity.java: Fix location picker bug with incorrect map centering (#5716)
This commit moves the center of the map to the image's location, if the image has
location EXIF data. If the image does not have location EXIF data, the map will
center on the device's current GPS location.
2024-06-09 21:24:40 +02:00
Kaartic Sivaraam
bb4cfe421a
feedback: add info about where the feedback gets posted (#5748)
* feedback: add info about where the feedback gets posted

Fixes #5747

* feedback: avoid underscore in the link's alternative text

* wording

---------

Co-authored-by: Nicolas Raoul <nicolas.raoul@gmail.com>
2024-06-09 21:08:38 +02:00
Evangelos Talos
22dd69cabb
Improved Map Marker Visibility Based on App Theme (#5744)
* Update map markers

* Modify code to use different map marker for themes

* Update map markers for bookmarked

* Add 2 tests

---------

Co-authored-by: Giannis Karyotakis <110292528+karyotakisg@users.noreply.github.com>
2024-06-09 21:07:02 +02:00
Zack Chi
bde09072fb
Update Java version from Java 8 to Java 11 (#5732)
Co-authored-by: Zack Chi <zach.chi.email@gmail.com>
Co-authored-by: Nicolas Raoul <nicolas.raoul@gmail.com>
2024-06-09 20:56:38 +02:00
pacha0
8fdfb8e6dc
Fixes bug #5721 (Crash when adding and then removing media details) (#5750)
I replaced uploadMediaDetail.get(position) with a direct reference to uploadMediaDetail in 3 locations to avoid out of bounds errors.

The usage of RecyclerView in this code is still a bit buggy, and maybe a RecyclerView is not necessary here since the number of items is limited. The fix also revealed problems in the logic of adding the "addButton" only to the last item, which couldn't be reproduced before because the app crashed first. I can submit a new bug for that if this fix goes live.

I did not feel very comfortable with the code so I restricted my commit to fixing the first reported crash, which was resolved in my tests.
2024-06-06 15:10:26 +02:00
translatewiki.net
06e25a074c Localisation updates from https://translatewiki.net. 2024-06-03 14:03:12 +02:00
Giannis Karyotakis
fe7a2f2a8c
Fix voice input bug (#5739)
* Fix voice input bug

* Add javadocs

---------

Co-authored-by: vtalos <v.talos23@gmail.com>
2024-06-02 23:06:43 +05:30
translatewiki.net
18e03ed038 Localisation updates from https://translatewiki.net. 2024-05-30 14:02:21 +02:00