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
c22812e0
Commit
c22812e0
authored
Mar 10, 2017
by
Alexandre Ardhuin
Committed by
GitHub
Mar 10, 2017
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Flutter style guide: Prefer naming the argument to a setter 'value' (#8691)
parent
7b9cefb3
Changes
16
Show whitespace changes
Inline
Side-by-side
Showing
16 changed files
with
148 additions
and
148 deletions
+148
-148
slider.dart
packages/flutter/lib/src/cupertino/slider.dart
+3
-3
slider.dart
packages/flutter/lib/src/material/slider.dart
+8
-8
tab_controller.dart
packages/flutter/lib/src/material/tab_controller.dart
+5
-5
simulation_group.dart
packages/flutter/lib/src/physics/simulation_group.dart
+3
-3
custom_layout.dart
packages/flutter/lib/src/rendering/custom_layout.dart
+5
-5
performance_overlay.dart
packages/flutter/lib/src/rendering/performance_overlay.dart
+12
-12
proxy_box.dart
packages/flutter/lib/src/rendering/proxy_box.dart
+75
-75
shifted_box.dart
packages/flutter/lib/src/rendering/shifted_box.dart
+4
-4
sliver_fixed_extent_list.dart
...s/flutter/lib/src/rendering/sliver_fixed_extent_list.dart
+8
-8
sliver_grid.dart
packages/flutter/lib/src/rendering/sliver_grid.dart
+6
-6
page_view.dart
packages/flutter/lib/src/widgets/page_view.dart
+3
-3
placeholder.dart
packages/flutter/lib/src/widgets/placeholder.dart
+3
-3
markdown_raw.dart
packages/flutter_markdown/lib/src/markdown_raw.dart
+3
-3
binding.dart
packages/flutter_test/lib/src/binding.dart
+2
-2
devfs.dart
packages/flutter_tools/lib/src/devfs.dart
+6
-6
flutter_command.dart
packages/flutter_tools/lib/src/runner/flutter_command.dart
+2
-2
No files found.
packages/flutter/lib/src/cupertino/slider.dart
View file @
c22812e0
...
@@ -225,10 +225,10 @@ class _RenderCupertinoSlider extends RenderConstrainedBox implements SemanticsAc
...
@@ -225,10 +225,10 @@ class _RenderCupertinoSlider extends RenderConstrainedBox implements SemanticsAc
int
get
divisions
=>
_divisions
;
int
get
divisions
=>
_divisions
;
int
_divisions
;
int
_divisions
;
set
divisions
(
int
newDivisions
)
{
set
divisions
(
int
value
)
{
if
(
newDivisions
==
_divisions
)
if
(
value
==
_divisions
)
return
;
return
;
_divisions
=
newDivisions
;
_divisions
=
value
;
markNeedsPaint
();
markNeedsPaint
();
}
}
...
...
packages/flutter/lib/src/material/slider.dart
View file @
c22812e0
...
@@ -316,27 +316,27 @@ class _RenderSlider extends RenderConstrainedBox implements SemanticsActionHandl
...
@@ -316,27 +316,27 @@ class _RenderSlider extends RenderConstrainedBox implements SemanticsActionHandl
int
get
divisions
=>
_divisions
;
int
get
divisions
=>
_divisions
;
int
_divisions
;
int
_divisions
;
set
divisions
(
int
newDivisions
)
{
set
divisions
(
int
value
)
{
if
(
newDivisions
==
_divisions
)
if
(
value
==
_divisions
)
return
;
return
;
_divisions
=
newDivisions
;
_divisions
=
value
;
markNeedsPaint
();
markNeedsPaint
();
}
}
String
get
label
=>
_label
;
String
get
label
=>
_label
;
String
_label
;
String
_label
;
set
label
(
String
newLabel
)
{
set
label
(
String
value
)
{
if
(
newLabel
==
_label
)
if
(
value
==
_label
)
return
;
return
;
_label
=
newLabel
;
_label
=
value
;
additionalConstraints
=
_getAdditionalConstraints
(
_label
);
additionalConstraints
=
_getAdditionalConstraints
(
_label
);
if
(
newLabel
!=
null
)
{
if
(
value
!=
null
)
{
// TODO(abarth): Handle textScaleFactor.
// TODO(abarth): Handle textScaleFactor.
// https://github.com/flutter/flutter/issues/5938
// https://github.com/flutter/flutter/issues/5938
_labelPainter
_labelPainter
..
text
=
new
TextSpan
(
..
text
=
new
TextSpan
(
style:
_textTheme
.
body1
.
copyWith
(
fontSize:
10.0
),
style:
_textTheme
.
body1
.
copyWith
(
fontSize:
10.0
),
text:
newLabel
text:
value
)
)
..
layout
();
..
layout
();
}
else
{
}
else
{
...
...
packages/flutter/lib/src/material/tab_controller.dart
View file @
c22812e0
...
@@ -148,13 +148,13 @@ class TabController extends ChangeNotifier {
...
@@ -148,13 +148,13 @@ class TabController extends ChangeNotifier {
/// TabBarView has been dragged to the left. Similarly a value between
/// TabBarView has been dragged to the left. Similarly a value between
/// 0.0 and 1.0 implies that the TabBarView has been dragged to the right.
/// 0.0 and 1.0 implies that the TabBarView has been dragged to the right.
double
get
offset
=>
_animationController
.
value
-
_index
.
toDouble
();
double
get
offset
=>
_animationController
.
value
-
_index
.
toDouble
();
set
offset
(
double
newOffset
)
{
set
offset
(
double
value
)
{
assert
(
newOffset
!=
null
);
assert
(
value
!=
null
);
assert
(
newOffset
>=
-
1.0
&&
newOffset
<=
1.0
);
assert
(
value
>=
-
1.0
&&
value
<=
1.0
);
assert
(!
indexIsChanging
);
assert
(!
indexIsChanging
);
if
(
newOffset
==
offset
)
if
(
value
==
offset
)
return
;
return
;
_animationController
.
value
=
newOffset
+
_index
.
toDouble
();
_animationController
.
value
=
value
+
_index
.
toDouble
();
}
}
@override
@override
...
...
packages/flutter/lib/src/physics/simulation_group.dart
View file @
c22812e0
...
@@ -69,8 +69,8 @@ abstract class SimulationGroup extends Simulation {
...
@@ -69,8 +69,8 @@ abstract class SimulationGroup extends Simulation {
}
}
@override
@override
set
tolerance
(
Tolerance
t
)
{
set
tolerance
(
Tolerance
value
)
{
currentSimulation
.
tolerance
=
t
;
currentSimulation
.
tolerance
=
value
;
super
.
tolerance
=
t
;
super
.
tolerance
=
value
;
}
}
}
}
packages/flutter/lib/src/rendering/custom_layout.dart
View file @
c22812e0
...
@@ -282,13 +282,13 @@ class RenderCustomMultiChildLayoutBox extends RenderBox
...
@@ -282,13 +282,13 @@ class RenderCustomMultiChildLayoutBox extends RenderBox
/// The delegate that controls the layout of the children.
/// The delegate that controls the layout of the children.
MultiChildLayoutDelegate
get
delegate
=>
_delegate
;
MultiChildLayoutDelegate
get
delegate
=>
_delegate
;
MultiChildLayoutDelegate
_delegate
;
MultiChildLayoutDelegate
_delegate
;
set
delegate
(
MultiChildLayoutDelegate
newDelegat
e
)
{
set
delegate
(
MultiChildLayoutDelegate
valu
e
)
{
assert
(
newDelegat
e
!=
null
);
assert
(
valu
e
!=
null
);
if
(
_delegate
==
newDelegat
e
)
if
(
_delegate
==
valu
e
)
return
;
return
;
if
(
newDelegate
.
runtimeType
!=
_delegate
.
runtimeType
||
newDelegat
e
.
shouldRelayout
(
_delegate
))
if
(
value
.
runtimeType
!=
_delegate
.
runtimeType
||
valu
e
.
shouldRelayout
(
_delegate
))
markNeedsLayout
();
markNeedsLayout
();
_delegate
=
newDelegat
e
;
_delegate
=
valu
e
;
}
}
Size
_getSize
(
BoxConstraints
constraints
)
{
Size
_getSize
(
BoxConstraints
constraints
)
{
...
...
packages/flutter/lib/src/rendering/performance_overlay.dart
View file @
c22812e0
...
@@ -77,11 +77,11 @@ class RenderPerformanceOverlay extends RenderBox {
...
@@ -77,11 +77,11 @@ class RenderPerformanceOverlay extends RenderBox {
/// [PerformanceOverlayOption] to enable.
/// [PerformanceOverlayOption] to enable.
int
get
optionsMask
=>
_optionsMask
;
int
get
optionsMask
=>
_optionsMask
;
int
_optionsMask
;
int
_optionsMask
;
set
optionsMask
(
int
mask
)
{
set
optionsMask
(
int
value
)
{
assert
(
mask
!=
null
);
assert
(
value
!=
null
);
if
(
mask
==
_optionsMask
)
if
(
value
==
_optionsMask
)
return
;
return
;
_optionsMask
=
mask
;
_optionsMask
=
value
;
markNeedsPaint
();
markNeedsPaint
();
}
}
...
@@ -90,22 +90,22 @@ class RenderPerformanceOverlay extends RenderBox {
...
@@ -90,22 +90,22 @@ class RenderPerformanceOverlay extends RenderBox {
/// is suitable for capturing an SkPicture trace for further analysis.
/// is suitable for capturing an SkPicture trace for further analysis.
int
get
rasterizerThreshold
=>
_rasterizerThreshold
;
int
get
rasterizerThreshold
=>
_rasterizerThreshold
;
int
_rasterizerThreshold
;
int
_rasterizerThreshold
;
set
rasterizerThreshold
(
int
threshold
)
{
set
rasterizerThreshold
(
int
value
)
{
assert
(
threshold
!=
null
);
assert
(
value
!=
null
);
if
(
threshold
==
_rasterizerThreshold
)
if
(
value
==
_rasterizerThreshold
)
return
;
return
;
_rasterizerThreshold
=
threshold
;
_rasterizerThreshold
=
value
;
markNeedsPaint
();
markNeedsPaint
();
}
}
/// Whether the raster cache should checkerboard cached entries.
/// Whether the raster cache should checkerboard cached entries.
bool
get
checkerboardRasterCacheImages
=>
_checkerboardRasterCacheImages
;
bool
get
checkerboardRasterCacheImages
=>
_checkerboardRasterCacheImages
;
bool
_checkerboardRasterCacheImages
;
bool
_checkerboardRasterCacheImages
;
set
checkerboardRasterCacheImages
(
bool
checkerboard
)
{
set
checkerboardRasterCacheImages
(
bool
value
)
{
assert
(
checkerboard
!=
null
);
assert
(
value
!=
null
);
if
(
checkerboard
==
_checkerboardRasterCacheImages
)
if
(
value
==
_checkerboardRasterCacheImages
)
return
;
return
;
_checkerboardRasterCacheImages
=
checkerboard
;
_checkerboardRasterCacheImages
=
value
;
markNeedsPaint
();
markNeedsPaint
();
}
}
...
...
packages/flutter/lib/src/rendering/proxy_box.dart
View file @
c22812e0
...
@@ -206,12 +206,12 @@ class RenderConstrainedBox extends RenderProxyBox {
...
@@ -206,12 +206,12 @@ class RenderConstrainedBox extends RenderProxyBox {
/// Additional constraints to apply to [child] during layout
/// Additional constraints to apply to [child] during layout
BoxConstraints
get
additionalConstraints
=>
_additionalConstraints
;
BoxConstraints
get
additionalConstraints
=>
_additionalConstraints
;
BoxConstraints
_additionalConstraints
;
BoxConstraints
_additionalConstraints
;
set
additionalConstraints
(
BoxConstraints
newConstraints
)
{
set
additionalConstraints
(
BoxConstraints
value
)
{
assert
(
newConstraints
!=
null
);
assert
(
value
!=
null
);
assert
(
newConstraints
.
debugAssertIsValid
());
assert
(
value
.
debugAssertIsValid
());
if
(
_additionalConstraints
==
newConstraints
)
if
(
_additionalConstraints
==
value
)
return
;
return
;
_additionalConstraints
=
newConstraints
;
_additionalConstraints
=
value
;
markNeedsLayout
();
markNeedsLayout
();
}
}
...
@@ -399,13 +399,13 @@ class RenderAspectRatio extends RenderProxyBox {
...
@@ -399,13 +399,13 @@ class RenderAspectRatio extends RenderProxyBox {
/// a 16:9 width:height aspect ratio would have a value of 16.0/9.0.
/// a 16:9 width:height aspect ratio would have a value of 16.0/9.0.
double
get
aspectRatio
=>
_aspectRatio
;
double
get
aspectRatio
=>
_aspectRatio
;
double
_aspectRatio
;
double
_aspectRatio
;
set
aspectRatio
(
double
newAspectRatio
)
{
set
aspectRatio
(
double
value
)
{
assert
(
newAspectRatio
!=
null
);
assert
(
value
!=
null
);
assert
(
newAspectRatio
>
0.0
);
assert
(
value
>
0.0
);
assert
(
newAspectRatio
.
isFinite
);
assert
(
value
.
isFinite
);
if
(
_aspectRatio
==
newAspectRatio
)
if
(
_aspectRatio
==
value
)
return
;
return
;
_aspectRatio
=
newAspectRatio
;
_aspectRatio
=
value
;
markNeedsLayout
();
markNeedsLayout
();
}
}
...
@@ -541,20 +541,20 @@ class RenderIntrinsicWidth extends RenderProxyBox {
...
@@ -541,20 +541,20 @@ class RenderIntrinsicWidth extends RenderProxyBox {
/// If non-null, force the child's width to be a multiple of this value.
/// If non-null, force the child's width to be a multiple of this value.
double
get
stepWidth
=>
_stepWidth
;
double
get
stepWidth
=>
_stepWidth
;
double
_stepWidth
;
double
_stepWidth
;
set
stepWidth
(
double
newStepWidth
)
{
set
stepWidth
(
double
value
)
{
if
(
newStepWidth
==
_stepWidth
)
if
(
value
==
_stepWidth
)
return
;
return
;
_stepWidth
=
newStepWidth
;
_stepWidth
=
value
;
markNeedsLayout
();
markNeedsLayout
();
}
}
/// If non-null, force the child's height to be a multiple of this value.
/// If non-null, force the child's height to be a multiple of this value.
double
get
stepHeight
=>
_stepHeight
;
double
get
stepHeight
=>
_stepHeight
;
double
_stepHeight
;
double
_stepHeight
;
set
stepHeight
(
double
newStepHeight
)
{
set
stepHeight
(
double
value
)
{
if
(
newStepHeight
==
_stepHeight
)
if
(
value
==
_stepHeight
)
return
;
return
;
_stepHeight
=
newStepHeight
;
_stepHeight
=
value
;
markNeedsLayout
();
markNeedsLayout
();
}
}
...
@@ -721,12 +721,12 @@ class RenderOpacity extends RenderProxyBox {
...
@@ -721,12 +721,12 @@ class RenderOpacity extends RenderProxyBox {
/// expensive.
/// expensive.
double
get
opacity
=>
_opacity
;
double
get
opacity
=>
_opacity
;
double
_opacity
;
double
_opacity
;
set
opacity
(
double
newOpacity
)
{
set
opacity
(
double
value
)
{
assert
(
newOpacity
!=
null
);
assert
(
value
!=
null
);
assert
(
newOpacity
>=
0.0
&&
newOpacity
<=
1.0
);
assert
(
value
>=
0.0
&&
value
<=
1.0
);
if
(
_opacity
==
newOpacity
)
if
(
_opacity
==
value
)
return
;
return
;
_opacity
=
newOpacity
;
_opacity
=
value
;
_alpha
=
_getAlphaFromOpacity
(
_opacity
);
_alpha
=
_getAlphaFromOpacity
(
_opacity
);
markNeedsCompositingBitsUpdate
();
markNeedsCompositingBitsUpdate
();
markNeedsPaint
();
markNeedsPaint
();
...
@@ -792,11 +792,11 @@ class RenderShaderMask extends RenderProxyBox {
...
@@ -792,11 +792,11 @@ class RenderShaderMask extends RenderProxyBox {
// repaints when the ShaderCallback changes identity.
// repaints when the ShaderCallback changes identity.
ShaderCallback
get
shaderCallback
=>
_shaderCallback
;
ShaderCallback
get
shaderCallback
=>
_shaderCallback
;
ShaderCallback
_shaderCallback
;
ShaderCallback
_shaderCallback
;
set
shaderCallback
(
ShaderCallback
newShaderCallback
)
{
set
shaderCallback
(
ShaderCallback
value
)
{
assert
(
newShaderCallback
!=
null
);
assert
(
value
!=
null
);
if
(
_shaderCallback
==
newShaderCallback
)
if
(
_shaderCallback
==
value
)
return
;
return
;
_shaderCallback
=
newShaderCallback
;
_shaderCallback
=
value
;
markNeedsPaint
();
markNeedsPaint
();
}
}
...
@@ -806,11 +806,11 @@ class RenderShaderMask extends RenderProxyBox {
...
@@ -806,11 +806,11 @@ class RenderShaderMask extends RenderProxyBox {
/// to the child. Other blend modes can be used to create other effects.
/// to the child. Other blend modes can be used to create other effects.
BlendMode
get
blendMode
=>
_blendMode
;
BlendMode
get
blendMode
=>
_blendMode
;
BlendMode
_blendMode
;
BlendMode
_blendMode
;
set
blendMode
(
BlendMode
newBlendMod
e
)
{
set
blendMode
(
BlendMode
valu
e
)
{
assert
(
newBlendMod
e
!=
null
);
assert
(
valu
e
!=
null
);
if
(
_blendMode
==
newBlendMod
e
)
if
(
_blendMode
==
valu
e
)
return
;
return
;
_blendMode
=
newBlendMod
e
;
_blendMode
=
valu
e
;
markNeedsPaint
();
markNeedsPaint
();
}
}
...
@@ -846,11 +846,11 @@ class RenderBackdropFilter extends RenderProxyBox {
...
@@ -846,11 +846,11 @@ class RenderBackdropFilter extends RenderProxyBox {
/// blur effect
/// blur effect
ui
.
ImageFilter
get
filter
=>
_filter
;
ui
.
ImageFilter
get
filter
=>
_filter
;
ui
.
ImageFilter
_filter
;
ui
.
ImageFilter
_filter
;
set
filter
(
ui
.
ImageFilter
newFilter
)
{
set
filter
(
ui
.
ImageFilter
value
)
{
assert
(
newFilter
!=
null
);
assert
(
value
!=
null
);
if
(
_filter
==
newFilter
)
if
(
_filter
==
value
)
return
;
return
;
_filter
=
newFilter
;
_filter
=
value
;
markNeedsPaint
();
markNeedsPaint
();
}
}
...
@@ -1329,24 +1329,24 @@ class RenderDecoratedBox extends RenderProxyBox {
...
@@ -1329,24 +1329,24 @@ class RenderDecoratedBox extends RenderProxyBox {
/// Commonly a [BoxDecoration].
/// Commonly a [BoxDecoration].
Decoration
get
decoration
=>
_decoration
;
Decoration
get
decoration
=>
_decoration
;
Decoration
_decoration
;
Decoration
_decoration
;
set
decoration
(
Decoration
newDecoration
)
{
set
decoration
(
Decoration
value
)
{
assert
(
newDecoration
!=
null
);
assert
(
value
!=
null
);
if
(
newDecoration
==
_decoration
)
if
(
value
==
_decoration
)
return
;
return
;
_painter
?.
dispose
();
_painter
?.
dispose
();
_painter
=
null
;
_painter
=
null
;
_decoration
=
newDecoration
;
_decoration
=
value
;
markNeedsPaint
();
markNeedsPaint
();
}
}
/// Whether to paint the box decoration behind or in front of the child.
/// Whether to paint the box decoration behind or in front of the child.
DecorationPosition
get
position
=>
_position
;
DecorationPosition
get
position
=>
_position
;
DecorationPosition
_position
;
DecorationPosition
_position
;
set
position
(
DecorationPosition
newPosition
)
{
set
position
(
DecorationPosition
value
)
{
assert
(
newPosition
!=
null
);
assert
(
value
!=
null
);
if
(
newPosition
==
_position
)
if
(
value
==
_position
)
return
;
return
;
_position
=
newPosition
;
_position
=
value
;
markNeedsPaint
();
markNeedsPaint
();
}
}
...
@@ -1355,11 +1355,11 @@ class RenderDecoratedBox extends RenderProxyBox {
...
@@ -1355,11 +1355,11 @@ class RenderDecoratedBox extends RenderProxyBox {
/// [BoxPainter.paint].
/// [BoxPainter.paint].
ImageConfiguration
get
configuration
=>
_configuration
;
ImageConfiguration
get
configuration
=>
_configuration
;
ImageConfiguration
_configuration
;
ImageConfiguration
_configuration
;
set
configuration
(
ImageConfiguration
newConfiguration
)
{
set
configuration
(
ImageConfiguration
value
)
{
assert
(
newConfiguration
!=
null
);
assert
(
value
!=
null
);
if
(
newConfiguration
==
_configuration
)
if
(
value
==
_configuration
)
return
;
return
;
_configuration
=
newConfiguration
;
_configuration
=
value
;
markNeedsPaint
();
markNeedsPaint
();
}
}
...
@@ -1449,10 +1449,10 @@ class RenderTransform extends RenderProxyBox {
...
@@ -1449,10 +1449,10 @@ class RenderTransform extends RenderProxyBox {
/// translation. This property is provided just for convenience.
/// translation. This property is provided just for convenience.
Offset
get
origin
=>
_origin
;
Offset
get
origin
=>
_origin
;
Offset
_origin
;
Offset
_origin
;
set
origin
(
Offset
newOrigin
)
{
set
origin
(
Offset
value
)
{
if
(
_origin
==
newOrigin
)
if
(
_origin
==
value
)
return
;
return
;
_origin
=
newOrigin
;
_origin
=
value
;
markNeedsPaint
();
markNeedsPaint
();
}
}
...
@@ -1462,11 +1462,11 @@ class RenderTransform extends RenderProxyBox {
...
@@ -1462,11 +1462,11 @@ class RenderTransform extends RenderProxyBox {
/// If it is specified at the same time as an offset, both are applied.
/// If it is specified at the same time as an offset, both are applied.
FractionalOffset
get
alignment
=>
_alignment
;
FractionalOffset
get
alignment
=>
_alignment
;
FractionalOffset
_alignment
;
FractionalOffset
_alignment
;
set
alignment
(
FractionalOffset
newAlignment
)
{
set
alignment
(
FractionalOffset
value
)
{
assert
(
newAlignment
==
null
||
(
newAlignment
.
dx
!=
null
&&
newAlignment
.
dy
!=
null
));
assert
(
value
==
null
||
(
value
.
dx
!=
null
&&
value
.
dy
!=
null
));
if
(
_alignment
==
newAlignment
)
if
(
_alignment
==
value
)
return
;
return
;
_alignment
=
newAlignment
;
_alignment
=
value
;
markNeedsPaint
();
markNeedsPaint
();
}
}
...
@@ -1482,11 +1482,11 @@ class RenderTransform extends RenderProxyBox {
...
@@ -1482,11 +1482,11 @@ class RenderTransform extends RenderProxyBox {
Matrix4
_transform
;
Matrix4
_transform
;
/// The matrix to transform the child by during painting.
/// The matrix to transform the child by during painting.
set
transform
(
Matrix4
newTransform
)
{
set
transform
(
Matrix4
value
)
{
assert
(
newTransform
!=
null
);
assert
(
value
!=
null
);
if
(
_transform
==
newTransform
)
if
(
_transform
==
value
)
return
;
return
;
_transform
=
new
Matrix4
.
copy
(
newTransform
);
_transform
=
new
Matrix4
.
copy
(
value
);
markNeedsPaint
();
markNeedsPaint
();
}
}
...
@@ -1607,11 +1607,11 @@ class RenderFittedBox extends RenderProxyBox {
...
@@ -1607,11 +1607,11 @@ class RenderFittedBox extends RenderProxyBox {
/// How to inscribe the child into the space allocated during layout.
/// How to inscribe the child into the space allocated during layout.
ImageFit
get
fit
=>
_fit
;
ImageFit
get
fit
=>
_fit
;
ImageFit
_fit
;
ImageFit
_fit
;
set
fit
(
ImageFit
newFit
)
{
set
fit
(
ImageFit
value
)
{
assert
(
newFit
!=
null
);
assert
(
value
!=
null
);
if
(
_fit
==
newFit
)
if
(
_fit
==
value
)
return
;
return
;
_fit
=
newFit
;
_fit
=
value
;
_clearPaintData
();
_clearPaintData
();
markNeedsPaint
();
markNeedsPaint
();
}
}
...
@@ -1623,11 +1623,11 @@ class RenderFittedBox extends RenderProxyBox {
...
@@ -1623,11 +1623,11 @@ class RenderFittedBox extends RenderProxyBox {
/// of the right edge of its parent's bounds.
/// of the right edge of its parent's bounds.
FractionalOffset
get
alignment
=>
_alignment
;
FractionalOffset
get
alignment
=>
_alignment
;
FractionalOffset
_alignment
;
FractionalOffset
_alignment
;
set
alignment
(
FractionalOffset
newAlignment
)
{
set
alignment
(
FractionalOffset
value
)
{
assert
(
newAlignment
!=
null
&&
newAlignment
.
dx
!=
null
&&
newAlignment
.
dy
!=
null
);
assert
(
value
!=
null
&&
value
.
dx
!=
null
&&
value
.
dy
!=
null
);
if
(
_alignment
==
newAlignment
)
if
(
_alignment
==
value
)
return
;
return
;
_alignment
=
newAlignment
;
_alignment
=
value
;
_clearPaintData
();
_clearPaintData
();
markNeedsPaint
();
markNeedsPaint
();
}
}
...
@@ -1744,11 +1744,11 @@ class RenderFractionalTranslation extends RenderProxyBox {
...
@@ -1744,11 +1744,11 @@ class RenderFractionalTranslation extends RenderProxyBox {
/// The translation to apply to the child, as a multiple of the size.
/// The translation to apply to the child, as a multiple of the size.
FractionalOffset
get
translation
=>
_translation
;
FractionalOffset
get
translation
=>
_translation
;
FractionalOffset
_translation
;
FractionalOffset
_translation
;
set
translation
(
FractionalOffset
newTranslation
)
{
set
translation
(
FractionalOffset
value
)
{
assert
(
newTranslation
==
null
||
(
newTranslation
.
dx
!=
null
&&
newTranslation
.
dy
!=
null
));
assert
(
value
==
null
||
(
value
.
dx
!=
null
&&
value
.
dy
!=
null
));
if
(
_translation
==
newTranslation
)
if
(
_translation
==
value
)
return
;
return
;
_translation
=
newTranslation
;
_translation
=
value
;
markNeedsPaint
();
markNeedsPaint
();
}
}
...
@@ -1947,11 +1947,11 @@ class RenderCustomPaint extends RenderProxyBox {
...
@@ -1947,11 +1947,11 @@ class RenderCustomPaint extends RenderProxyBox {
/// delegate will be called.
/// delegate will be called.
///
///
/// If the new value is null, then there is no background custom painter.
/// If the new value is null, then there is no background custom painter.
set
painter
(
CustomPainter
newPainter
)
{
set
painter
(
CustomPainter
value
)
{
if
(
_painter
==
newPainter
)
if
(
_painter
==
value
)
return
;
return
;
final
CustomPainter
oldPainter
=
_painter
;
final
CustomPainter
oldPainter
=
_painter
;
_painter
=
newPainter
;
_painter
=
value
;
_didUpdatePainter
(
_painter
,
oldPainter
);
_didUpdatePainter
(
_painter
,
oldPainter
);
}
}
...
@@ -1972,11 +1972,11 @@ class RenderCustomPaint extends RenderProxyBox {
...
@@ -1972,11 +1972,11 @@ class RenderCustomPaint extends RenderProxyBox {
/// delegate will be called.
/// delegate will be called.
///
///
/// If the new value is null, then there is no foreground custom painter.
/// If the new value is null, then there is no foreground custom painter.
set
foregroundPainter
(
CustomPainter
newPainter
)
{
set
foregroundPainter
(
CustomPainter
value
)
{
if
(
_foregroundPainter
==
newPainter
)
if
(
_foregroundPainter
==
value
)
return
;
return
;
final
CustomPainter
oldPainter
=
_foregroundPainter
;
final
CustomPainter
oldPainter
=
_foregroundPainter
;
_foregroundPainter
=
newPainter
;
_foregroundPainter
=
value
;
_didUpdatePainter
(
_foregroundPainter
,
oldPainter
);
_didUpdatePainter
(
_foregroundPainter
,
oldPainter
);
}
}
...
...
packages/flutter/lib/src/rendering/shifted_box.dart
View file @
c22812e0
...
@@ -212,11 +212,11 @@ abstract class RenderAligningShiftedBox extends RenderShiftedBox {
...
@@ -212,11 +212,11 @@ abstract class RenderAligningShiftedBox extends RenderShiftedBox {
/// Sets the alignment to a new value, and triggers a layout update.
/// Sets the alignment to a new value, and triggers a layout update.
///
///
/// The new alignment must not be null or have any null properties.
/// The new alignment must not be null or have any null properties.
set
alignment
(
FractionalOffset
newAlignment
)
{
set
alignment
(
FractionalOffset
value
)
{
assert
(
newAlignment
!=
null
&&
newAlignment
.
dx
!=
null
&&
newAlignment
.
dy
!=
null
);
assert
(
value
!=
null
&&
value
.
dx
!=
null
&&
value
.
dy
!=
null
);
if
(
_alignment
==
newAlignment
)
if
(
_alignment
==
value
)
return
;
return
;
_alignment
=
newAlignment
;
_alignment
=
value
;
markNeedsLayout
();
markNeedsLayout
();
}
}
...
...
packages/flutter/lib/src/rendering/sliver_fixed_extent_list.dart
View file @
c22812e0
...
@@ -163,11 +163,11 @@ class RenderSliverFixedExtentList extends RenderSliverFixedExtentBoxAdaptor {
...
@@ -163,11 +163,11 @@ class RenderSliverFixedExtentList extends RenderSliverFixedExtentBoxAdaptor {
@override
@override
double
get
itemExtent
=>
_itemExtent
;
double
get
itemExtent
=>
_itemExtent
;
double
_itemExtent
;
double
_itemExtent
;
set
itemExtent
(
double
newV
alue
)
{
set
itemExtent
(
double
v
alue
)
{
assert
(
newV
alue
!=
null
);
assert
(
v
alue
!=
null
);
if
(
_itemExtent
==
newV
alue
)
if
(
_itemExtent
==
v
alue
)
return
;
return
;
_itemExtent
=
newV
alue
;
_itemExtent
=
v
alue
;
markNeedsLayout
();
markNeedsLayout
();
}
}
}
}
...
@@ -186,11 +186,11 @@ class RenderSliverFill extends RenderSliverFixedExtentBoxAdaptor {
...
@@ -186,11 +186,11 @@ class RenderSliverFill extends RenderSliverFixedExtentBoxAdaptor {
double
get
viewportFraction
=>
_viewportFraction
;
double
get
viewportFraction
=>
_viewportFraction
;
double
_viewportFraction
;
double
_viewportFraction
;
set
viewportFraction
(
double
newV
alue
)
{
set
viewportFraction
(
double
v
alue
)
{
assert
(
newV
alue
!=
null
);
assert
(
v
alue
!=
null
);
if
(
_viewportFraction
==
newV
alue
)
if
(
_viewportFraction
==
v
alue
)
return
;
return
;
_viewportFraction
=
newV
alue
;
_viewportFraction
=
v
alue
;
markNeedsLayout
();
markNeedsLayout
();
}
}
...
...
packages/flutter/lib/src/rendering/sliver_grid.dart
View file @
c22812e0
...
@@ -426,14 +426,14 @@ class RenderSliverGrid extends RenderSliverMultiBoxAdaptor {
...
@@ -426,14 +426,14 @@ class RenderSliverGrid extends RenderSliverMultiBoxAdaptor {
SliverGridDelegate
get
gridDelegate
=>
_gridDelegate
;
SliverGridDelegate
get
gridDelegate
=>
_gridDelegate
;
SliverGridDelegate
_gridDelegate
;
SliverGridDelegate
_gridDelegate
;
set
gridDelegate
(
SliverGridDelegate
newDelegat
e
)
{
set
gridDelegate
(
SliverGridDelegate
valu
e
)
{
assert
(
newDelegat
e
!=
null
);
assert
(
valu
e
!=
null
);
if
(
_gridDelegate
==
newDelegat
e
)
if
(
_gridDelegate
==
valu
e
)
return
;
return
;
if
(
newDelegat
e
.
runtimeType
!=
_gridDelegate
.
runtimeType
||
if
(
valu
e
.
runtimeType
!=
_gridDelegate
.
runtimeType
||
newDelegat
e
.
shouldRelayout
(
_gridDelegate
))
valu
e
.
shouldRelayout
(
_gridDelegate
))
markNeedsLayout
();
markNeedsLayout
();
_gridDelegate
=
newDelegat
e
;
_gridDelegate
=
valu
e
;
}
}
@override
@override
...
...
packages/flutter/lib/src/widgets/page_view.dart
View file @
c22812e0
...
@@ -159,11 +159,11 @@ class _PagePosition extends ScrollPosition {
...
@@ -159,11 +159,11 @@ class _PagePosition extends ScrollPosition {
double
get
viewportFraction
=>
_viewportFraction
;
double
get
viewportFraction
=>
_viewportFraction
;
double
_viewportFraction
;
double
_viewportFraction
;
set
viewportFraction
(
double
newV
alue
)
{
set
viewportFraction
(
double
v
alue
)
{
if
(
_viewportFraction
==
newV
alue
)
if
(
_viewportFraction
==
v
alue
)
return
;
return
;
final
double
oldPage
=
page
;
final
double
oldPage
=
page
;
_viewportFraction
=
newV
alue
;
_viewportFraction
=
v
alue
;
if
(
oldPage
!=
null
)
if
(
oldPage
!=
null
)
correctPixels
(
getPixelsFromPage
(
oldPage
));
correctPixels
(
getPixelsFromPage
(
oldPage
));
}
}
...
...
packages/flutter/lib/src/widgets/placeholder.dart
View file @
c22812e0
...
@@ -23,11 +23,11 @@ class PlaceholderState extends State<Placeholder> {
...
@@ -23,11 +23,11 @@ class PlaceholderState extends State<Placeholder> {
/// Mutating this field will cause this widget to rebuild with the new child.
/// Mutating this field will cause this widget to rebuild with the new child.
Widget
get
child
=>
_child
;
Widget
get
child
=>
_child
;
Widget
_child
;
Widget
_child
;
set
child
(
Widget
child
)
{
set
child
(
Widget
value
)
{
if
(
_child
==
child
)
if
(
_child
==
value
)
return
;
return
;
setState
(()
{
setState
(()
{
_child
=
child
;
_child
=
value
;
});
});
}
}
...
...
packages/flutter_markdown/lib/src/markdown_raw.dart
View file @
c22812e0
...
@@ -356,9 +356,9 @@ class _Block {
...
@@ -356,9 +356,9 @@ class _Block {
List
<
_Block
>
subBlocks
;
List
<
_Block
>
subBlocks
;
bool
get
open
=>
_open
;
bool
get
open
=>
_open
;
set
open
(
bool
open
)
{
set
open
(
bool
value
)
{
_open
=
open
;
_open
=
value
;
if
(!
open
&&
subBlocks
.
isNotEmpty
)
if
(!
value
&&
subBlocks
.
isNotEmpty
)
subBlocks
.
last
.
isLast
=
true
;
subBlocks
.
last
.
isLast
=
true
;
}
}
...
...
packages/flutter_test/lib/src/binding.dart
View file @
c22812e0
...
@@ -202,8 +202,8 @@ abstract class TestWidgetsFlutterBinding extends BindingBase
...
@@ -202,8 +202,8 @@ abstract class TestWidgetsFlutterBinding extends BindingBase
/// the focus change.
/// the focus change.
EditableTextState
get
focusedEditable
=>
_focusedEditable
;
EditableTextState
get
focusedEditable
=>
_focusedEditable
;
EditableTextState
_focusedEditable
;
EditableTextState
_focusedEditable
;
set
focusedEditable
(
EditableTextState
editabl
e
)
{
set
focusedEditable
(
EditableTextState
valu
e
)
{
_focusedEditable
=
editabl
e
..
requestKeyboard
();
_focusedEditable
=
valu
e
..
requestKeyboard
();
}
}
/// Returns the exception most recently caught by the Flutter framework.
/// Returns the exception most recently caught by the Flutter framework.
...
...
packages/flutter_tools/lib/src/devfs.dart
View file @
c22812e0
...
@@ -113,8 +113,8 @@ class DevFSByteContent extends DevFSContent {
...
@@ -113,8 +113,8 @@ class DevFSByteContent extends DevFSContent {
List
<
int
>
get
bytes
=>
_bytes
;
List
<
int
>
get
bytes
=>
_bytes
;
set
bytes
(
List
<
int
>
newBytes
)
{
set
bytes
(
List
<
int
>
value
)
{
_bytes
=
newBytes
;
_bytes
=
value
;
_isModified
=
true
;
_isModified
=
true
;
}
}
...
@@ -145,14 +145,14 @@ class DevFSStringContent extends DevFSByteContent {
...
@@ -145,14 +145,14 @@ class DevFSStringContent extends DevFSByteContent {
String
get
string
=>
_string
;
String
get
string
=>
_string
;
set
string
(
String
newString
)
{
set
string
(
String
value
)
{
_string
=
newString
;
_string
=
value
;
super
.
bytes
=
UTF8
.
encode
(
_string
);
super
.
bytes
=
UTF8
.
encode
(
_string
);
}
}
@override
@override
set
bytes
(
List
<
int
>
newBytes
)
{
set
bytes
(
List
<
int
>
value
)
{
string
=
UTF8
.
decode
(
newBytes
);
string
=
UTF8
.
decode
(
value
);
}
}
}
}
...
...
packages/flutter_tools/lib/src/runner/flutter_command.dart
View file @
c22812e0
...
@@ -77,8 +77,8 @@ abstract class FlutterCommand extends Command<Null> {
...
@@ -77,8 +77,8 @@ abstract class FlutterCommand extends Command<Null> {
help:
'Build a release version of your app
${defaultToRelease ? ' (default mode)' : ''}
.'
);
help:
'Build a release version of your app
${defaultToRelease ? ' (default mode)' : ''}
.'
);
}
}
set
defaultBuildMode
(
BuildMode
buildMod
e
)
{
set
defaultBuildMode
(
BuildMode
valu
e
)
{
_defaultBuildMode
=
buildMod
e
;
_defaultBuildMode
=
valu
e
;
}
}
BuildMode
getBuildMode
()
{
BuildMode
getBuildMode
()
{
...
...
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