[Bookmarks] Add areAllCategoriesEmpty method to the bookmarks manager #8100

Merged
root merged 2 commits from bookmarks/add-isempty-method-to-the-bookmarks-manager into master 2024-05-08 21:54:54 +00:00
Member

This method is needed to implement the following features:

Also, I've made a small refactoring of the isCategoryNotEmpty method to use the already IsCategoryEmpty which checks the empty (rather than the cont).

This method is needed to implement the following features: - hide the `export all` button (https://git.omaps.dev/organicmaps/organicmaps/issues/8055) - disable the `backup` button into the icloud sync enabling alert Also, I've made a small refactoring of the `isCategoryNotEmpty` method to use the already `IsCategoryEmpty` which checks the `empty` (rather than the `cont`).
biodranik (Migrated from github.com) reviewed 2024-05-06 10:52:45 +00:00
biodranik (Migrated from github.com) commented 2024-05-06 10:52:05 +00:00

areAllCategoriesEmpty

areAllCategoriesEmpty
biodranik (Migrated from github.com) commented 2024-05-06 10:52:41 +00:00

isCategoryEmpty

using Not complicates the understanding.

isCategoryEmpty using Not complicates the understanding.
biodranik (Migrated from github.com) approved these changes 2024-05-06 11:24:52 +00:00
@ -200,0 +197,4 @@
- (BOOL)areAllCategoriesEmpty
{
return self.bm.AreAllCategoriesEmpty();
}
biodranik (Migrated from github.com) commented 2024-05-06 11:24:48 +00:00

Would it be better/faster/more reusable on Android if implemented in C++?

Would it be better/faster/more reusable on Android if implemented in C++?
kirylkaveryn reviewed 2024-05-06 11:52:20 +00:00
@ -200,0 +197,4 @@
- (BOOL)areAllCategoriesEmpty
{
return self.bm.AreAllCategoriesEmpty();
}
Author
Member

I think yes! I can try to move this logic into the core.

I think yes! I can try to move this logic into the core.
kirylkaveryn reviewed 2024-05-06 13:05:59 +00:00
@ -200,0 +197,4 @@
- (BOOL)areAllCategoriesEmpty
{
return self.bm.AreAllCategoriesEmpty();
}
Author
Member

I've moved this logic into the cpp.

I've moved this logic into the cpp.
biodranik (Migrated from github.com) approved these changes 2024-05-06 13:13:08 +00:00
biodranik (Migrated from github.com) left a comment

Cool, thanks!

Cool, thanks!
This repo is archived. You cannot comment on pull requests.
No reviewers
No labels
Accessibility
Accessibility
Address
Address
Android
Android
Android Auto
Android Auto
Android Automotive (AAOS)
Android Automotive (AAOS)
API
API
AppGallery
AppGallery
AppStore
AppStore
Battery and Performance
Battery and Performance
Blocker
Blocker
Bookmarks and Tracks
Bookmarks and Tracks
Borders
Borders
Bug
Bug
Build
Build
CarPlay
CarPlay
Classificator
Classificator
Community
Community
Core
Core
CrashReports
CrashReports
Cycling
Cycling
Desktop
Desktop
DevEx
DevEx
DevOps
DevOps
dev_sandbox
dev_sandbox
Directions
Directions
Documentation
Documentation
Downloader
Downloader
Drape
Drape
Driving
Driving
Duplicate
Duplicate
Editor
Editor
Elevation
Elevation
Enhancement
Enhancement
Epic
Epic
External Map Datasets
External Map Datasets
F-Droid
F-Droid
Fonts
Fonts
Frequently User Reported
Frequently User Reported
Fund
Fund
Generator
Generator
Good first issue
Good first issue
Google Play
Google Play
GPS
GPS
GSoC
GSoC
iCloud
iCloud
Icons
Icons
iOS
iOS
Legal
Legal
Linux Desktop
Linux Desktop
Linux packaging
Linux packaging
Linux Phone
Linux Phone
Mac OS
Mac OS
Map Data
Map Data
Metro
Metro
Navigation
Navigation
Need Feedback
Need Feedback
Night Mode
Night Mode
NLnet 2024-06-281
NLnet 2024-06-281
No Feature Parity
No Feature Parity
Opening Hours
Opening Hours
Outdoors
Outdoors
POI Info
POI Info
Privacy
Privacy
Public Transport
Public Transport
Raw Idea
Raw Idea
Refactoring
Refactoring
Regional
Regional
Regression
Regression
Releases
Releases
RoboTest
RoboTest
Route Planning
Route Planning
Routing
Routing
Ruler
Ruler
Search
Search
Security
Security
Styles
Styles
Tests
Tests
Track Recording
Track Recording
Translations
Translations
TTS
TTS
UI
UI
UX
UX
Walk Navigation
Walk Navigation
Watches
Watches
Web
Web
Wikipedia
Wikipedia
Windows
Windows
Won't fix
Won't fix
World Map
World Map
No milestone
No project
No assignees
2 participants
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference: organicmaps/organicmaps-tmp#8100
No description provided.