Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/abians/app_install_events
A Flutter package that enables detection of application installation and uninstallation events on Android devices. It simplifies monitoring changes in the list of installed applications.
https://github.com/abians/app_install_events
android dart dartlanguage flutter flutter-package flutterpackage kotlin
Last synced: about 1 month ago
JSON representation
A Flutter package that enables detection of application installation and uninstallation events on Android devices. It simplifies monitoring changes in the list of installed applications.
- Host: GitHub
- URL: https://github.com/abians/app_install_events
- Owner: AbianS
- License: mit
- Created: 2023-09-16T09:43:36.000Z (about 1 year ago)
- Default Branch: main
- Last Pushed: 2023-09-16T12:36:35.000Z (about 1 year ago)
- Last Synced: 2023-10-18T05:05:06.808Z (about 1 year ago)
- Topics: android, dart, dartlanguage, flutter, flutter-package, flutterpackage, kotlin
- Language: Kotlin
- Homepage: https://pub.dev/packages/app_install_events
- Size: 20.5 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- Changelog: CHANGELOG.md
- License: LICENSE
Awesome Lists containing this project
README
# App Install Events
[![pub package](https://img.shields.io/pub/v/android_intent_plus.svg)](https://pub.dev/packages/app_install_events)
[![pub points](https://img.shields.io/pub/points/android_intent_plus?color=2E8B57&label=pub%20points)](https://pub.dev/packages/app_install_events/score)A Flutter package that enables detection of application installation and uninstallation events on Android devices. It simplifies monitoring changes in the list of installed applications.
This package is perfect if you're developing an Android launcher with Flutter, as it allows you to detect when applications are installed or uninstalled, enabling you to reflect these changes in your launcher.
## Getting Started
To use this app install events, you need to add the dependencies in `pubspec.yaml` file.
```yaml
dependencies:
app_install_events: ^0.0.1
```## Usage
To use this package, import `package:app_install_events/app_install_events.dart`.
```dart
import 'package:app_install_events/app_install_events.dart';late AppIUEvents _appIUEvents;
@override
void initState(){
super.initState();
// Initialize the AppIUEvents class
_appIUEvents = AppIUEvents();
// Listen to app install and uninstall events
_appIUEvents.appEvents.listen((event){
// Check if the event is an install event
if(event.type == AppIUEventType.INSTALL){
print("App installed: ${event.packageName}");
}// Check if the event is an uninstall event
if(event.type == AppIUEventType.UNINSTALL){
print("App uninstalled: ${event.packageName}");
}});
}@override
void dispose(){
_appIUEvents.dispose(); // Dispose the stream
super.dispose();
}
```