-
Notifications
You must be signed in to change notification settings - Fork 29.7k
Closed
flutter/packages
#9536Labels
P2Important issues not at the top of the work listImportant issues not at the top of the work listgood first issueRelatively approachable for first-time contributorsRelatively approachable for first-time contributorsp: cameraThe camera pluginThe camera pluginpackageflutter/packages repository. See also p: labels.flutter/packages repository. See also p: labels.r: fixedIssue is closed as already fixed in a newer versionIssue is closed as already fixed in a newer versionteam-ecosystemOwned by Ecosystem teamOwned by Ecosystem teamtriaged-ecosystemTriaged by Ecosystem teamTriaged by Ecosystem team
Description
What package does this bug report belong to?
camera
What target platforms are you seeing this bug on?
Platform-Independent
Have you already upgraded your packages?
Yes
Dependency versions
Occurring on latest version 0.11.1
Steps to reproduce
- Import the package using
import 'package:camera/camera.dart';. - Try to filter the
availableCameras()by LensType - Can't filter by lens type because of missing export of
CameraLensType
Expected results
No analysis errors
Actual results
Analysis error:
Undefined name 'CameraLensType'.
Try correcting the name to one that is defined, or defining the name.
Code sample
Camera selection could look like this:
cameras.firstWhere(
(camera) => camera.lensDirection == CameraLensDirection.back && camera.lensType == CameraLensType.wide,
);With this default import:
import 'package:camera/camera.dart';Screenshots or Videos
No response
Logs
No response
Flutter Doctor output
Not relevant for this issue
tirth-patel-nc and esenmx
Metadata
Metadata
Assignees
Labels
P2Important issues not at the top of the work listImportant issues not at the top of the work listgood first issueRelatively approachable for first-time contributorsRelatively approachable for first-time contributorsp: cameraThe camera pluginThe camera pluginpackageflutter/packages repository. See also p: labels.flutter/packages repository. See also p: labels.r: fixedIssue is closed as already fixed in a newer versionIssue is closed as already fixed in a newer versionteam-ecosystemOwned by Ecosystem teamOwned by Ecosystem teamtriaged-ecosystemTriaged by Ecosystem teamTriaged by Ecosystem team