Skip to content

Commit 3292eda

Browse files
migrated to null safety
1 parent 3111b64 commit 3292eda

File tree

8 files changed

+69
-73
lines changed

8 files changed

+69
-73
lines changed

CHANGELOG.md

Lines changed: 14 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,27 +1,31 @@
1+
## 1.0.0-nullsafety.0
2+
3+
- Migrated to null safety.
4+
15
## 0.0.6
26

3-
* Added multi-page support.
7+
- Added multi-page support.
48

59
## 0.0.5
610

7-
* Fixed an issue with android action.
8-
* IOS apps wont crash using this plugin from now.
9-
* Improved README and Example app.
11+
- Fixed an issue with android action.
12+
- IOS apps wont crash using this plugin from now.
13+
- Improved README and Example app.
1014

1115
## 0.0.4
1216

13-
* Updated README.md
17+
- Updated README.md
1418

1519
## 0.0.3
1620

17-
* Modified some docs.
21+
- Modified some docs.
1822

1923
## 0.0.2
2024

21-
* Added support for android.
22-
* Improved plugin description.
23-
* Changed comments to dartdoc comments.
25+
- Added support for android.
26+
- Improved plugin description.
27+
- Changed comments to dartdoc comments.
2428

2529
## 0.0.1
2630

27-
* Initial release
31+
- Initial release

README.md

Lines changed: 8 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -6,14 +6,15 @@ A flutter plugin for ACTION_PROCESS_TEXT implementation in android.
66

77
It can be used when you want your users to use a shortcut for opening your app when selecting text anywhere in the android environment.
88

9-
109
![](https://imgur.com/2sikhjG.gif)
1110

1211
## Constraints
1312

14-
### 1. It works only for android.
15-
### 2. It can only be used inside a Stateful widget.
16-
### 3. Use setState() after updating the value from the action.
13+
### 1. It works only for android.
14+
15+
### 2. It can only be used inside a Stateful widget.
16+
17+
### 3. Use setState() after updating the value from the action.
1718

1819
## Include in your project
1920

@@ -25,6 +26,7 @@ dependencies:
2526
Run pub get and get packages.
2627
2728
Add this to `AndroidManifest.xml` in the `android\app\src\main\` folder.
29+
2830
```xml
2931
<activity android:name="com.example.action_process_text.ActionProcessTextPlugin"
3032
android:label="Action_Text" android:theme="@style/LaunchTheme">
@@ -35,6 +37,7 @@ Add this to `AndroidManifest.xml` in the `android\app\src\main\` folder.
3537
</intent-filter>
3638
</activity>
3739
```
40+
3841
Change the `android:label` from `Action_Text` to the action text that you want to display.
3942
![](https://imgur.com/FFpUhWF.png)
4043

@@ -43,6 +46,7 @@ Then import the package to use it.
4346
```dart
4447
import 'package:action_process_text/action_process_text.dart';
4548
```
49+
4650
## Usage
4751

4852
Use the constructor of the widget to initialize the action_process_text.

example/pubspec.lock

Lines changed: 21 additions & 28 deletions
Original file line numberDiff line numberDiff line change
@@ -7,63 +7,56 @@ packages:
77
path: ".."
88
relative: true
99
source: path
10-
version: "0.0.6"
10+
version: "1.0.0-nullsafety.0"
1111
async:
1212
dependency: transitive
1313
description:
1414
name: async
1515
url: "https://pub.dartlang.org"
1616
source: hosted
17-
version: "2.5.0-nullsafety.1"
17+
version: "2.5.0"
1818
boolean_selector:
1919
dependency: transitive
2020
description:
2121
name: boolean_selector
2222
url: "https://pub.dartlang.org"
2323
source: hosted
24-
version: "2.1.0-nullsafety.1"
24+
version: "2.1.0"
2525
characters:
2626
dependency: transitive
2727
description:
2828
name: characters
2929
url: "https://pub.dartlang.org"
3030
source: hosted
31-
version: "1.1.0-nullsafety.3"
31+
version: "1.1.0"
3232
charcode:
3333
dependency: transitive
3434
description:
3535
name: charcode
3636
url: "https://pub.dartlang.org"
3737
source: hosted
38-
version: "1.2.0-nullsafety.1"
38+
version: "1.2.0"
3939
clock:
4040
dependency: transitive
4141
description:
4242
name: clock
4343
url: "https://pub.dartlang.org"
4444
source: hosted
45-
version: "1.1.0-nullsafety.1"
45+
version: "1.1.0"
4646
collection:
4747
dependency: transitive
4848
description:
4949
name: collection
5050
url: "https://pub.dartlang.org"
5151
source: hosted
52-
version: "1.15.0-nullsafety.3"
53-
cupertino_icons:
54-
dependency: "direct main"
55-
description:
56-
name: cupertino_icons
57-
url: "https://pub.dartlang.org"
58-
source: hosted
59-
version: "0.1.3"
52+
version: "1.15.0"
6053
fake_async:
6154
dependency: transitive
6255
description:
6356
name: fake_async
6457
url: "https://pub.dartlang.org"
6558
source: hosted
66-
version: "1.2.0-nullsafety.1"
59+
version: "1.2.0"
6760
flutter:
6861
dependency: "direct main"
6962
description: flutter
@@ -80,21 +73,21 @@ packages:
8073
name: matcher
8174
url: "https://pub.dartlang.org"
8275
source: hosted
83-
version: "0.12.10-nullsafety.1"
76+
version: "0.12.10"
8477
meta:
8578
dependency: transitive
8679
description:
8780
name: meta
8881
url: "https://pub.dartlang.org"
8982
source: hosted
90-
version: "1.3.0-nullsafety.3"
83+
version: "1.3.0"
9184
path:
9285
dependency: transitive
9386
description:
9487
name: path
9588
url: "https://pub.dartlang.org"
9689
source: hosted
97-
version: "1.8.0-nullsafety.1"
90+
version: "1.8.0"
9891
sky_engine:
9992
dependency: transitive
10093
description: flutter
@@ -106,56 +99,56 @@ packages:
10699
name: source_span
107100
url: "https://pub.dartlang.org"
108101
source: hosted
109-
version: "1.8.0-nullsafety.2"
102+
version: "1.8.0"
110103
stack_trace:
111104
dependency: transitive
112105
description:
113106
name: stack_trace
114107
url: "https://pub.dartlang.org"
115108
source: hosted
116-
version: "1.10.0-nullsafety.1"
109+
version: "1.10.0"
117110
stream_channel:
118111
dependency: transitive
119112
description:
120113
name: stream_channel
121114
url: "https://pub.dartlang.org"
122115
source: hosted
123-
version: "2.1.0-nullsafety.1"
116+
version: "2.1.0"
124117
string_scanner:
125118
dependency: transitive
126119
description:
127120
name: string_scanner
128121
url: "https://pub.dartlang.org"
129122
source: hosted
130-
version: "1.1.0-nullsafety.1"
123+
version: "1.1.0"
131124
term_glyph:
132125
dependency: transitive
133126
description:
134127
name: term_glyph
135128
url: "https://pub.dartlang.org"
136129
source: hosted
137-
version: "1.2.0-nullsafety.1"
130+
version: "1.2.0"
138131
test_api:
139132
dependency: transitive
140133
description:
141134
name: test_api
142135
url: "https://pub.dartlang.org"
143136
source: hosted
144-
version: "0.2.19-nullsafety.2"
137+
version: "0.2.19"
145138
typed_data:
146139
dependency: transitive
147140
description:
148141
name: typed_data
149142
url: "https://pub.dartlang.org"
150143
source: hosted
151-
version: "1.3.0-nullsafety.3"
144+
version: "1.3.0"
152145
vector_math:
153146
dependency: transitive
154147
description:
155148
name: vector_math
156149
url: "https://pub.dartlang.org"
157150
source: hosted
158-
version: "2.1.0-nullsafety.3"
151+
version: "2.1.0"
159152
sdks:
160-
dart: ">=2.10.0-110 <2.11.0"
161-
flutter: ">=1.20.0 <2.0.0"
153+
dart: ">=2.12.0 <3.0.0"
154+
flutter: ">=1.20.0"

example/pubspec.yaml

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -3,10 +3,10 @@ description: Demonstrates how to use the action_process_text plugin.
33

44
# The following line prevents the package from being accidentally published to
55
# pub.dev using `pub publish`. This is preferred for private packages.
6-
publish_to: 'none' # Remove this line if you wish to publish to pub.dev
6+
publish_to: "none" # Remove this line if you wish to publish to pub.dev
77

88
environment:
9-
sdk: ">=2.7.0 <3.0.0"
9+
sdk: '>=2.12.0 <3.0.0'
1010

1111
dependencies:
1212
flutter:
@@ -22,7 +22,6 @@ dependencies:
2222

2323
# The following adds the Cupertino Icons font to your application.
2424
# Use with the CupertinoIcons class for iOS style icons.
25-
cupertino_icons: ^0.1.3
2625

2726
dev_dependencies:
2827
flutter_test:
@@ -33,7 +32,6 @@ dev_dependencies:
3332

3433
# The following section is specific to Flutter.
3534
flutter:
36-
3735
# The following line ensures that the Material Icons font is
3836
# included with your application, so that you can use the icons in
3937
# the material Icons class.

example/test/widget_test.dart

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ void main() {
1919
expect(
2020
find.byWidgetPredicate(
2121
(Widget widget) => widget is Text &&
22-
widget.data.startsWith('Running on:'),
22+
widget.data!.startsWith('Running on:'),
2323
),
2424
findsOneWidget,
2525
);

0 commit comments

Comments
 (0)