Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Sign in
Toggle navigation
F
Front-End
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
abdullh.alsoleman
Front-End
Commits
14b3f740
Unverified
Commit
14b3f740
authored
Mar 02, 2023
by
Kevin Moore
Committed by
GitHub
Mar 02, 2023
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
flutter_tool: DRY up features that are fully enabled (#121754)
flutter_tool: DRY up features that are fully enabled
parent
b85f195d
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
25 additions
and
79 deletions
+25
-79
features.dart
packages/flutter_tools/lib/src/features.dart
+25
-79
No files found.
packages/flutter_tools/lib/src/features.dart
View file @
14b3f740
...
...
@@ -67,116 +67,43 @@ const List<Feature> allFeatures = <Feature>[
];
/// The [Feature] for flutter web.
const
Feature
flutterWebFeature
=
Feature
(
const
Feature
flutterWebFeature
=
Feature
.
fullyEnabled
(
name:
'Flutter for web'
,
configSetting:
'enable-web'
,
environmentOverride:
'FLUTTER_WEB'
,
master:
FeatureChannelSetting
(
available:
true
,
enabledByDefault:
true
,
),
beta:
FeatureChannelSetting
(
available:
true
,
enabledByDefault:
true
,
),
stable:
FeatureChannelSetting
(
available:
true
,
enabledByDefault:
true
,
),
);
/// The [Feature] for macOS desktop.
const
Feature
flutterMacOSDesktopFeature
=
Feature
(
const
Feature
flutterMacOSDesktopFeature
=
Feature
.
fullyEnabled
(
name:
'support for desktop on macOS'
,
configSetting:
'enable-macos-desktop'
,
environmentOverride:
'FLUTTER_MACOS'
,
master:
FeatureChannelSetting
(
available:
true
,
enabledByDefault:
true
,
),
beta:
FeatureChannelSetting
(
available:
true
,
enabledByDefault:
true
,
),
stable:
FeatureChannelSetting
(
available:
true
,
enabledByDefault:
true
,
),
);
/// The [Feature] for Linux desktop.
const
Feature
flutterLinuxDesktopFeature
=
Feature
(
const
Feature
flutterLinuxDesktopFeature
=
Feature
.
fullyEnabled
(
name:
'support for desktop on Linux'
,
configSetting:
'enable-linux-desktop'
,
environmentOverride:
'FLUTTER_LINUX'
,
master:
FeatureChannelSetting
(
available:
true
,
enabledByDefault:
true
,
),
beta:
FeatureChannelSetting
(
available:
true
,
enabledByDefault:
true
,
),
stable:
FeatureChannelSetting
(
available:
true
,
enabledByDefault:
true
,
),
);
/// The [Feature] for Windows desktop.
const
Feature
flutterWindowsDesktopFeature
=
Feature
(
const
Feature
flutterWindowsDesktopFeature
=
Feature
.
fullyEnabled
(
name:
'support for desktop on Windows'
,
configSetting:
'enable-windows-desktop'
,
environmentOverride:
'FLUTTER_WINDOWS'
,
master:
FeatureChannelSetting
(
available:
true
,
enabledByDefault:
true
,
),
beta:
FeatureChannelSetting
(
available:
true
,
enabledByDefault:
true
,
),
stable:
FeatureChannelSetting
(
available:
true
,
enabledByDefault:
true
,
),
);
/// The [Feature] for Android devices.
const
Feature
flutterAndroidFeature
=
Feature
(
const
Feature
flutterAndroidFeature
=
Feature
.
fullyEnabled
(
name:
'Flutter for Android'
,
configSetting:
'enable-android'
,
master:
FeatureChannelSetting
(
available:
true
,
enabledByDefault:
true
,
),
beta:
FeatureChannelSetting
(
available:
true
,
enabledByDefault:
true
,
),
stable:
FeatureChannelSetting
(
available:
true
,
enabledByDefault:
true
,
),
);
/// The [Feature] for iOS devices.
const
Feature
flutterIOSFeature
=
Feature
(
const
Feature
flutterIOSFeature
=
Feature
.
fullyEnabled
(
name:
'Flutter for iOS'
,
configSetting:
'enable-ios'
,
master:
FeatureChannelSetting
(
available:
true
,
enabledByDefault:
true
,
),
beta:
FeatureChannelSetting
(
available:
true
,
enabledByDefault:
true
,
),
stable:
FeatureChannelSetting
(
available:
true
,
enabledByDefault:
true
,
),
);
/// The [Feature] for Fuchsia support.
...
...
@@ -238,6 +165,25 @@ class Feature {
this
.
stable
=
const
FeatureChannelSetting
()
});
/// Creates a [Feature] that is fully enabled across channels.
const
Feature
.
fullyEnabled
(
{
required
this
.
name
,
this
.
environmentOverride
,
this
.
configSetting
,
this
.
extraHelpText
})
:
master
=
const
FeatureChannelSetting
(
available:
true
,
enabledByDefault:
true
,
),
beta
=
const
FeatureChannelSetting
(
available:
true
,
enabledByDefault:
true
,
),
stable
=
const
FeatureChannelSetting
(
available:
true
,
enabledByDefault:
true
,
);
/// The user visible name for this feature.
final
String
name
;
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment