[screen_state] iOS support and renewal of the native example apps
I introduced iOS support to the 'screen_state' package by leveraging the 'isProtectedDataAvailable' and 'brightness' parameters for screen state analysis. Additionally, I refined the base plugin to facilitate its utilization in iOS applications, and optimized code readability and data handling with enhanced enums.
Moreover, I updated the native example apps using Flutter 3.16.9 as the foundation, addressing their outdated status and ensuring compatibility with iOS.
Despite these advancements, I encountered limitations inherent to the iOS platform. Notably, the 'isProtectedDataAvailable' parameter only provides data if the user has any form of password protection enabled, rendering it ineffective for detecting unlocks on devices without a password. Furthermore, the iOS simulator's inability to replicate device locking behavior and its distinct brightness controls hampered event detection within the simulator environment.
Throughout development, I conducted testing on an iPhone 6+ running iOS 12.5.7, successfully capturing all relevant events.
#169
This looks indeed interesting. I will take a look later.