Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -143,6 +143,7 @@ public void onDetachedFromEngine(@NonNull FlutterPluginBinding binding) {
@Override
public void onAttachedToActivity(@NonNull ActivityPluginBinding binding) {
mActivity = binding.getActivity();
binding.addActivityResultListener(this);
if (FlutterEngineCache.getInstance().get(OverlayConstants.CACHED_TAG) == null) {
FlutterEngineGroup enn = new FlutterEngineGroup(context);
DartExecutor.DartEntrypoint dEntry = new DartExecutor.DartEntrypoint(
Expand All @@ -155,6 +156,7 @@ public void onAttachedToActivity(@NonNull ActivityPluginBinding binding) {

@Override
public void onDetachedFromActivityForConfigChanges() {
this.mActivity = null;
}

@Override
Expand All @@ -164,6 +166,7 @@ public void onReattachedToActivityForConfigChanges(@NonNull ActivityPluginBindin

@Override
public void onDetachedFromActivity() {
this.mActivity = null;
}

@Override
Expand Down

Large diffs are not rendered by default.

25 changes: 0 additions & 25 deletions example/analysis_options.yaml
Original file line number Diff line number Diff line change
@@ -1,32 +1,7 @@
# This file configures the analyzer, which statically analyzes Dart code to
# check for errors, warnings, and lints.
#
# The issues identified by the analyzer are surfaced in the UI of Dart-enabled
# IDEs (https://dart.dev/tools#ides-and-editors). The analyzer can also be
# invoked from the command line by running `flutter analyze`.

# The following line activates a set of recommended lints for Flutter apps,
# packages, and plugins designed to encourage good coding practices.
analyzer:
errors:
use_build_context_synchronously: ignore
include: package:flutter_lints/flutter.yaml

linter:
# The lint rules applied to this project can be customized in the
# section below to disable rules from the `package:flutter_lints/flutter.yaml`
# included above or to enable additional rules. A list of all available lints
# and their documentation is published at
# https://dart-lang.github.io/linter/lints/index.html.
#
# Instead of disabling a lint rule for the entire project in the
# section below, it can also be suppressed for a single line of code
# or a specific dart file by using the `// ignore: name_of_lint` and
# `// ignore_for_file: name_of_lint` syntax on the line or in the file
# producing the lint.
rules:
# avoid_print: false # Uncomment to disable the `avoid_print` rule
# prefer_single_quotes: true # Uncomment to enable the `prefer_single_quotes` rule

# Additional information about this file can be found at
# https://dart.dev/guides/language/analysis-options
4 changes: 2 additions & 2 deletions example/lib/home_page.dart
Original file line number Diff line number Diff line change
Expand Up @@ -72,8 +72,8 @@ class _HomePageState extends State<HomePage> {
flag: OverlayFlag.defaultFlag,
visibility: NotificationVisibility.visibilityPublic,
positionGravity: PositionGravity.auto,
height: (MediaQuery.of(context).size.height * 0.6).toInt(),
width: WindowSize.matchParent,
height: 250,
width: 250,
startPosition: const OverlayPosition(0, -259),
);
},
Expand Down
4 changes: 2 additions & 2 deletions example/lib/main.dart
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import 'package:flutter/material.dart';
import 'package:flutter_overlay_window_example/home_page.dart';
import 'package:flutter_overlay_window_example/overlays/true_caller_overlay.dart';
import 'package:flutter_overlay_window_example/overlays/messanger_chathead.dart';

void main() {
WidgetsFlutterBinding.ensureInitialized();
Expand All @@ -13,7 +13,7 @@ void overlayMain() {
runApp(
const MaterialApp(
debugShowCheckedModeBanner: false,
home: TrueCallerOverlay(),
home: MessangerChatHead(),
),
);
}
Expand Down
18 changes: 9 additions & 9 deletions example/pubspec.lock
Original file line number Diff line number Diff line change
Expand Up @@ -13,10 +13,10 @@ packages:
dependency: transitive
description:
name: async
sha256: d2872f9c19731c2e5f10444b14686eb7cc85c76274bd6c16e1816bff9a3bab63
sha256: "758e6d74e971c3e5aceb4110bfd6698efc7f501675bcfe0c775459a8140750eb"
url: "https://pub.dev"
source: hosted
version: "2.12.0"
version: "2.13.0"
boolean_selector:
dependency: transitive
description:
Expand Down Expand Up @@ -69,10 +69,10 @@ packages:
dependency: transitive
description:
name: fake_async
sha256: "6a95e56b2449df2273fd8c45a662d6947ce1ebb7aafe80e550a3f68297f3cacc"
sha256: "5368f224a74523e8d2e7399ea1638b37aecfca824a3cc4dfdf77bf1fa905ac44"
url: "https://pub.dev"
source: hosted
version: "1.3.2"
version: "1.3.3"
flutter:
dependency: "direct main"
description: flutter
Expand Down Expand Up @@ -100,7 +100,7 @@ packages:
path: ".."
relative: true
source: path
version: "0.4.5"
version: "0.5.0"
flutter_test:
dependency: "direct dev"
description: flutter
Expand All @@ -110,10 +110,10 @@ packages:
dependency: transitive
description:
name: leak_tracker
sha256: c35baad643ba394b40aac41080300150a4f08fd0fd6a10378f8f7c6bc161acec
sha256: "6bb818ecbdffe216e81182c2f0714a2e62b593f4a4f13098713ff1685dfb6ab0"
url: "https://pub.dev"
source: hosted
version: "10.0.8"
version: "10.0.9"
leak_tracker_flutter_testing:
dependency: transitive
description:
Expand Down Expand Up @@ -315,10 +315,10 @@ packages:
dependency: transitive
description:
name: vm_service
sha256: "0968250880a6c5fe7edc067ed0a13d4bae1577fe2771dcf3010d52c4a9d3ca14"
sha256: ddfa8d30d89985b96407efce8acbdd124701f96741f2d981ca860662f1c0dc02
url: "https://pub.dev"
source: hosted
version: "14.3.1"
version: "15.0.0"
sdks:
dart: ">=3.7.0-0 <4.0.0"
flutter: ">=3.18.0-18.0.pre.54"
2 changes: 1 addition & 1 deletion pubspec.yaml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
name: flutter_overlay_window
description: Flutter plugin for displaying your flutter app over other apps on the screen
version: 0.5.0
version: 0.5.1
homepage: https://github.com/X-SLAYER/flutter_overlay_window

environment:
Expand Down