Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[pull] main from RafaelBarbosatec:main #1

Open
wants to merge 81 commits into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
81 commits
Select commit Hold shift + click to select a range
42702c1
update dependencies
rafaelbarbosadrip Dec 19, 2022
b0f6b6c
update changelog
rafaelbarbosadrip Dec 19, 2022
d00d95e
atualiza dependencias
May 17, 2023
46f3a50
adiciona camera low
May 17, 2023
7edd8a5
atualiza lib
May 18, 2023
82b008a
adds isolate_decoder
May 18, 2023
cd6da3f
increment version
May 18, 2023
3b4bd01
update changelog
May 18, 2023
f08b537
Merge pull request #6 from RafaelBarbosatec/update-dependencies
RafaelBarbosatec May 18, 2023
793b4c0
update pubspec
May 18, 2023
0ab53e5
update demo
May 18, 2023
66c0b1a
resolutionPreset
May 26, 2023
5461307
increment version
May 26, 2023
a01056f
increment version
May 26, 2023
c89f8ae
update demo
May 26, 2023
6254ad2
When decoding an image, on iOS the "camera_image" "Plane" Class does …
philseeley Aug 12, 2023
b7081ba
Merge pull request #8 from philseeley/main
RafaelBarbosatec Aug 12, 2023
5eb483a
increment version
Aug 17, 2023
f877072
format
Aug 17, 2023
45979ab
increment version
Aug 17, 2023
3ecfae4
fix issue
RafaelBarbosatec Oct 9, 2023
08d87dc
increment version
RafaelBarbosatec Oct 11, 2023
be6e05c
pubspec improvements
RafaelBarbosatec Oct 11, 2023
885c340
increment version
RafaelBarbosatec Feb 7, 2024
3a5ded7
update changelog
RafaelBarbosatec Feb 7, 2024
6ac2a31
format code
RafaelBarbosatec Feb 13, 2024
4586b8b
Merge pull request #13 from RafaelBarbosatec/develop
RafaelBarbosatec Feb 13, 2024
e072e9a
update reamde
RafaelBarbosatec Feb 13, 2024
95854d6
update android example
RafaelBarbosatec Feb 16, 2024
1f66bf1
update name
RafaelBarbosatec Feb 16, 2024
e9635a6
stop stream when dispose
RafaelBarbosatec Feb 16, 2024
7aecbb3
remove magic number
RafaelBarbosatec Feb 16, 2024
5cfd598
some improvements
RafaelBarbosatec Mar 18, 2024
3b09962
didChangeAppLifecycleState improvements
RafaelBarbosatec Mar 18, 2024
9953097
increment version
RafaelBarbosatec Mar 18, 2024
f471b21
Merge pull request #16 from RafaelBarbosatec/develop
RafaelBarbosatec Mar 18, 2024
0a6a81d
Update qr_code_dart_scan.dart
MateusLucasDaSilva Apr 12, 2024
af22261
Merge pull request #19 from MateusLucasDaSilva/main
RafaelBarbosatec Apr 12, 2024
b08ecee
increment version
RafaelBarbosatec Apr 13, 2024
44c1bd5
migrate every controll to controller
RafaelBarbosatec Apr 17, 2024
0d86179
increment version
RafaelBarbosatec Apr 18, 2024
7788819
remove print
RafaelBarbosatec Apr 18, 2024
570f865
update readme
RafaelBarbosatec Apr 18, 2024
1fd7ab6
Merge pull request #23 from RafaelBarbosatec/controller-improvements
RafaelBarbosatec Apr 18, 2024
56841fa
adds .pubignore
RafaelBarbosatec Apr 18, 2024
2f18093
Adding the ability to lock the camera orientation
Apr 18, 2024
d95457d
adding lockCaptureOrientation to controller
Apr 18, 2024
4a3330f
Merge pull request #24 from kevincraig/camera_orientation_lock
RafaelBarbosatec Apr 18, 2024
237bfca
fix app life circle issue
omralcrt Jun 12, 2024
d9c90a8
Merge pull request #26 from omralcrt/main
RafaelBarbosatec Jun 20, 2024
d3a9cb6
increment version
RafaelBarbosatec Jun 20, 2024
4261551
chore: remove print
RafaelBarbosatec Aug 5, 2024
1ff11fa
fix: corrige scale da camera
rafaelalmeidacloudwalk Aug 7, 2024
84d8b8a
melhorias na key
rafaelalmeidacloudwalk Aug 7, 2024
4266d13
chore: adds IsolatePool
rafaelalmeidacloudwalk Aug 15, 2024
cbd257a
chore: improvements
rafaelalmeidacloudwalk Aug 15, 2024
0374e08
chore: improvements
rafaelalmeidacloudwalk Aug 15, 2024
de568b1
chore: melhorias
rafaelalmeidacloudwalk Aug 16, 2024
6edfe32
chore: adds itf
rafaelalmeidacloudwalk Aug 16, 2024
c657e99
chore: remove fvm
rafaelalmeidacloudwalk Aug 16, 2024
61f821e
chore: remove exception
rafaelalmeidacloudwalk Aug 16, 2024
adcd79c
Merge pull request #27 from RafaelBarbosatec/develop
RafaelBarbosatec Aug 16, 2024
e9645de
poll improvements
RafaelBarbosatec Sep 2, 2024
c99da79
fix issues
RafaelBarbosatec Sep 2, 2024
d060915
adiciona opcao de rotacionar
RafaelBarbosatec Sep 2, 2024
1d28f5f
Merge pull request #31 from RafaelBarbosatec/develop
RafaelBarbosatec Sep 2, 2024
c56009c
chore: QRCodeDartScanController improvements
rafaelalmeidacloudwalk Oct 15, 2024
c9b2895
chore: update readme
rafaelalmeidacloudwalk Oct 15, 2024
b38fa20
chore: update .lock
rafaelalmeidacloudwalk Oct 15, 2024
be630aa
adjustments
RafaelBarbosatec Oct 15, 2024
a56f2f6
Merge pull request #35 from RafaelBarbosatec/develop
RafaelBarbosatec Oct 15, 2024
25f1518
chore: adds double check
rafaelalmeidacloudwalk Oct 16, 2024
dc73db8
pull
rafaelalmeidacloudwalk Oct 16, 2024
15c75ab
chore: fix exception
rafaelalmeidacloudwalk Nov 6, 2024
343fdb2
chore: increment version
rafaelalmeidacloudwalk Nov 6, 2024
9450424
chore: enable upc
RafaelBarbosatec Nov 8, 2024
2bcb281
chore: enable upc
RafaelBarbosatec Nov 8, 2024
a9874fa
Merge pull request #37 from RafaelBarbosatec/develop
RafaelBarbosatec Nov 8, 2024
2402f83
chore: adds toggleFlash
RafaelBarbosatec Dec 17, 2024
09666a8
increment versino
RafaelBarbosatec Dec 17, 2024
2f4f77e
Merge pull request #39 from RafaelBarbosatec/develop
RafaelBarbosatec Dec 17, 2024
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
2 changes: 2 additions & 0 deletions .pubignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
apk
example
45 changes: 45 additions & 0 deletions .vscode/launch.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,45 @@
{
// Use IntelliSense to learn about possible attributes.
// Hover to view descriptions of existing attributes.
// For more information, visit: https://go.microsoft.com/fwlink/?linkid=830387
"version": "0.2.0",
"configurations": [
{
"name": "qr_code_dart_scan",
"request": "launch",
"type": "dart"
},
{
"name": "qr_code_dart_scan (profile mode)",
"request": "launch",
"type": "dart",
"flutterMode": "profile"
},
{
"name": "qr_code_dart_scan (release mode)",
"request": "launch",
"type": "dart",
"flutterMode": "release"
},
{
"name": "example",
"cwd": "example",
"request": "launch",
"type": "dart"
},
{
"name": "example (profile mode)",
"cwd": "example",
"request": "launch",
"type": "dart",
"flutterMode": "profile"
},
{
"name": "example (release mode)",
"cwd": "example",
"request": "launch",
"type": "dart",
"flutterMode": "release"
}
]
}
65 changes: 65 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,68 @@
## 0.9.4
- adds methods `toggleFlash`,`setFlash`,`setFlashAuto` in QRCodeDartScanController.

## 0.9.3
- Fix `stopImageStream` exception.

## 0.9.2
- Adds method `stopScan` and `startScan` in `QRCodeDartScanController`.
- Adds get `isLiveScan`.
- Fix `changeCamera` exception.

## 0.9.1
- Fix issue [#28](https://github.com/RafaelBarbosatec/qr_code_dart_scan/issues/28)
- Fix issue [#29](https://github.com/RafaelBarbosatec/qr_code_dart_scan/issues/29)

## 0.9.0
- Camera key improvments
- Update camera pluggin to `0.11.0`
- Performance improvements. Now using pool of isolates to process in live.
- Adds support to `itf`.

## 0.8.3
- Fix camera preview scale.

## 0.8.2
- Remove debug prints

## 0.8.1
- fix app life circle issue [26](https://github.com/RafaelBarbosatec/qr_code_dart_scan/pull/26). Thanks [Ömral Cörüt](https://github.com/omralcrt) !

## 0.8.0
- `QRCodeDartScanController` Improvements
- Adds `Future<void> changeCamera(TypeCamera typeCamera)` method in `QRCodeDartScanController`.
- Adds `intervalScan` param in `QRCodeDartScanView`.
- Adds `onResultInterceptor` param in `QRCodeDartScanView`.

## 0.7.7
- Fix issue [#18](https://github.com/RafaelBarbosatec/qr_code_dart_scan/issues/18). Thanks [MateusLucasDaSilva](https://github.com/MateusLucasDaSilva)!

## 0.7.6
- Handle with `didChangeAppLifecycleState`.
- Fix issue [#15](https://github.com/RafaelBarbosatec/qr_code_dart_scan/issues/15). Thanks [thierrylee](https://github.com/thierrylee)!

## 0.7.5
- Update dependencies.
- Adds the method `dispose` in `QRCodeDartScanController`

## 0.7.4
- Fix issue [#11](https://github.com/RafaelBarbosatec/qr_code_dart_scan/issues/11)
- Fix AspectRatio
- Update dependencies.

## 0.7.3
- Fix issue [#9](https://github.com/RafaelBarbosatec/qr_code_dart_scan/issues/9)

## 0.7.2
- Fix issue [#7](https://github.com/RafaelBarbosatec/qr_code_dart_scan/issues/7). Thanks so much [philseeley](https://github.com/philseeley)!

## 0.7.1
- return `resolutionPreset` default to `QRCodeDartScanResolutionPreset.medium`
- removre debug prints.

## 0.7.0
- Update dependencies.

## 0.6.0
- Adds scan by picture
- Export decoder
Expand Down
43 changes: 24 additions & 19 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,12 @@ It's important to note that the `MediaRecorder` class is not working properly on
return Scaffold(
body: QRCodeDartScanView(
scanInvertedQRCode: true, // enable scan invert qr code ( default = false)
typeScan: TypeScan.live, // if TypeScan.takePicture will try decode when click to take a picture (default TypeScan.live)

typeScan: TypeScan.live, // if TypeScan.takePicture will try decode when click to take a picture(default TypeScan.live)
// intervalScan: const Duration(seconds:1)
// onResultInterceptor: (old,new){
// do any rule to controll onCapture.
// }
// takePictureButtonBuilder: (context,controller,isLoading){ // if typeScan == TypeScan.takePicture you can customize the button.
// if(loading) return CircularProgressIndicator();
// return ElevatedButton(
Expand All @@ -91,15 +96,15 @@ It's important to note that the `MediaRecorder` class is not working properly on
// }
// resolutionPreset: = QrCodeDartScanResolutionPreset.high,
// formats: [ // You can restrict specific formats.
// BarcodeFormat.QR_CODE,
// BarcodeFormat.AZTEC,
// BarcodeFormat.DATA_MATRIX,
// BarcodeFormat.PDF_417,
// BarcodeFormat.CODE_39,
// BarcodeFormat.CODE_93,
// BarcodeFormat.CODE_128,
// BarcodeFormat.EAN_8,
// BarcodeFormat.EAN_13,
// BarcodeFormat.qrCode,
// BarcodeFormat.aztec,
// BarcodeFormat.dataMatrix,
// BarcodeFormat.pdf417,
// BarcodeFormat.code39,
// BarcodeFormat.code93,
// BarcodeFormat.code128,
// BarcodeFormat.ean8,
// BarcodeFormat.ean13,
// ],
onCapture: (Result result) {
// do anything with result
Expand All @@ -124,15 +129,15 @@ You may use only the our decoder if you want:

final decoder = QRCodeDartScanDecoder(
// formats: [ // You can restrict specific formats.
// BarcodeFormat.QR_CODE,
// BarcodeFormat.AZTEC,
// BarcodeFormat.DATA_MATRIX,
// BarcodeFormat.PDF_417,
// BarcodeFormat.CODE_39,
// BarcodeFormat.CODE_93,
// BarcodeFormat.CODE_128,
// BarcodeFormat.EAN_8,
// BarcodeFormat.EAN_13,
// BarcodeFormat.qrCode,
// BarcodeFormat.aztec,
// BarcodeFormat.dataMatrix,
// BarcodeFormat.pdf417,
// BarcodeFormat.code39,
// BarcodeFormat.code93,
// BarcodeFormat.code128,
// BarcodeFormat.ean8,
// BarcodeFormat.ean13,
// ],
);

Expand Down
29 changes: 29 additions & 0 deletions analysis_options.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
# 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.
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
Binary file modified apk/demo.apk
Binary file not shown.
24 changes: 22 additions & 2 deletions example/.metadata
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,27 @@
# This file should be version controlled and should not be manually edited.

version:
revision: d79295af24c3ed621c33713ecda14ad196fd9c31
channel: stable
revision: "41456452f29d64e8deb623a3c927524bcf9f111b"
channel: "stable"

project_type: app

# Tracks metadata for the flutter migrate command
migration:
platforms:
- platform: root
create_revision: 41456452f29d64e8deb623a3c927524bcf9f111b
base_revision: 41456452f29d64e8deb623a3c927524bcf9f111b
- platform: android
create_revision: 41456452f29d64e8deb623a3c927524bcf9f111b
base_revision: 41456452f29d64e8deb623a3c927524bcf9f111b

# User provided section

# List of Local paths (relative to this file) that should be
# ignored by the migrate tool.
#
# Files that are not part of the templates will be ignored by default.
unmanaged_files:
- 'lib/main.dart'
- 'ios/Runner.xcodeproj/project.pbxproj'
28 changes: 28 additions & 0 deletions example/analysis_options.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
# 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.
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.dev/lints.
#
# 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
2 changes: 2 additions & 0 deletions example/android/.gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -9,3 +9,5 @@ GeneratedPluginRegistrant.java
# Remember to never publicly share your keystore.
# See https://flutter.dev/docs/deployment/android#reference-the-keystore-from-the-app
key.properties
**/*.keystore
**/*.jks
43 changes: 28 additions & 15 deletions example/android/app/build.gradle
Original file line number Diff line number Diff line change
@@ -1,3 +1,9 @@
plugins {
id "com.android.application"
id "kotlin-android"
id "dev.flutter.flutter-gradle-plugin"
}

def localProperties = new Properties()
def localPropertiesFile = rootProject.file('local.properties')
if (localPropertiesFile.exists()) {
Expand All @@ -6,11 +12,6 @@ if (localPropertiesFile.exists()) {
}
}

def flutterRoot = localProperties.getProperty('flutter.sdk')
if (flutterRoot == null) {
throw new GradleException("Flutter SDK not found. Define location with flutter.sdk in the local.properties file.")
}

def flutterVersionCode = localProperties.getProperty('flutter.versionCode')
if (flutterVersionCode == null) {
flutterVersionCode = '1'
Expand All @@ -21,22 +22,36 @@ if (flutterVersionName == null) {
flutterVersionName = '1.0'
}

apply plugin: 'com.android.application'
apply plugin: 'kotlin-android'
apply from: "$flutterRoot/packages/flutter_tools/gradle/flutter.gradle"
def flutterMinSdkVersion = localProperties.getProperty('flutter.minSdkVersion')
if (flutterMinSdkVersion == null) {
flutterMinSdkVersion = '21'
}

android {
compileSdkVersion 31
namespace "com.example.example"
compileSdkVersion flutter.compileSdkVersion
ndkVersion flutter.ndkVersion

compileOptions {
sourceCompatibility JavaVersion.VERSION_1_8
targetCompatibility JavaVersion.VERSION_1_8
}

kotlinOptions {
jvmTarget = '1.8'
}

sourceSets {
main.java.srcDirs += 'src/main/kotlin'
}

defaultConfig {
// TODO: Specify your own unique Application ID (https://developer.android.com/studio/build/application-id.html).
applicationId "com.qrcodedartscan.example"
minSdkVersion 21
targetSdkVersion 31
applicationId "com.example.qrcodedartscan"
// You can update the following values to match your application needs.
// For more information, see: https://docs.flutter.dev/deployment/android#reviewing-the-gradle-build-configuration.
minSdkVersion flutterMinSdkVersion.toInteger()
targetSdkVersion flutter.targetSdkVersion
versionCode flutterVersionCode.toInteger()
versionName flutterVersionName
}
Expand All @@ -54,6 +69,4 @@ flutter {
source '../..'
}

dependencies {
implementation "org.jetbrains.kotlin:kotlin-stdlib-jdk7:$kotlin_version"
}
dependencies {}
6 changes: 3 additions & 3 deletions example/android/app/src/debug/AndroidManifest.xml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
package="com.qrcodedartscan.example">
<!-- Flutter needs it to communicate with the running application
<manifest xmlns:android="http://schemas.android.com/apk/res/android">
<!-- The INTERNET permission is required for development. Specifically,
the Flutter tool needs it to communicate with the running application
to allow setting breakpoints, to provide hot reload, etc.
-->
<uses-permission android:name="android.permission.INTERNET"/>
Expand Down
18 changes: 5 additions & 13 deletions example/android/app/src/main/AndroidManifest.xml
Original file line number Diff line number Diff line change
@@ -1,10 +1,11 @@
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
package="com.qrcodedartscan.example">
<application
android:label="QRCodeDartDcan"
<manifest xmlns:android="http://schemas.android.com/apk/res/android">
<application
android:label="QRCodeDartScan"
android:name="${applicationName}"
android:icon="@mipmap/ic_launcher">
<activity
android:name=".MainActivity"
android:exported="true"
android:launchMode="singleTop"
android:theme="@style/LaunchTheme"
android:configChanges="orientation|keyboardHidden|keyboard|screenSize|smallestScreenSize|locale|layoutDirection|fontScale|screenLayout|density|uiMode"
Expand All @@ -18,15 +19,6 @@
android:name="io.flutter.embedding.android.NormalTheme"
android:resource="@style/NormalTheme"
/>
<!-- Displays an Android View that continues showing the launch screen
Drawable until Flutter paints its first frame, then this splash
screen fades out. A splash screen is useful to avoid any visual
gap between the end of Android's launch screen and the painting of
Flutter's first frame. -->
<meta-data
android:name="io.flutter.embedding.android.SplashScreenDrawable"
android:resource="@drawable/launch_background"
/>
<intent-filter>
<action android:name="android.intent.action.MAIN"/>
<category android:name="android.intent.category.LAUNCHER"/>
Expand Down
Loading