FLUTTER ECOSYSTEM

flutter-moum/flutter_screenshot_callback

iOS および Android でモバイルスクリーンショットを検出し、コールバック関数を実行できる Flutter プラグイン。🚀

flutter_screenshot_callback のプロジェクト画像
Stars
110
Forks
173
最終プッシュ(UTC)
2024/06/13
プロジェクト状態
公開中
Flutter Moum GitHub avatar
GITHUB Organization

Flutter Moum ↗

言語KotlinDartJavaRubySwiftObjective-C

このリポジトリが公開するパッケージ

使用している依存関係

依存関係一覧 2 件
  • flutter{"sdk":"flutter"}
  • flutter_test開発用{"sdk":"flutter"}

元の README

以下は英語原文のスナップショットです。最新版は GitHub をご覧ください。

README を開く / 閉じる

Screenshot Callback

Flutter plugin that allows you to detect mobile screenshot and execute callback functions on iOS and Android. 🚀

https://img.shields.io/pub/v/screenshot_callback.svg https://img.shields.io/github/license/flutter-moum/flutter_screenshot_callback

UsageIssues and FeedbackAuthorLicense

Feedback welcome and Pull Requests are most welcome!

Usage

Import the package

To use this plugin, follow the plugin installation instructions.

Use the plugin

Add the following import to your Dart code:

import 'package:screenshot_callback/screenshot_callback.dart';

Initialize ScreenshotCallback with the scopes you want:

ScreenshotCallback screenshotCallback = ScreenshotCallback();
addListener

Then invoke addListener method of ScreenshotCallback. Add custom functions that you want to excute after detect screenshot. e.g:

screenshotCallback.addListener(() {
  //Void funtions are implemented
  print('detect screenshot');
});
dispose

You need to call dispose method to terminate ScreenshotCallback before you exit the app e.g:

screenshotCallback.dispose();

Issues and Feedback

Please file issues to send feedback or report a bug. Thank you !

Author

License

MIT