@@ -102,7 +102,6 @@ class PhotoViewGallery extends StatefulWidget {
102102 const PhotoViewGallery ({
103103 Key key,
104104 @required this .pageOptions,
105- @Deprecated ("Use loadingBuilder instead" ) this .loadingChild,
106105 this .loadingBuilder,
107106 this .loadFailedChild,
108107 this .backgroundDecoration,
@@ -115,8 +114,7 @@ class PhotoViewGallery extends StatefulWidget {
115114 this .scrollPhysics,
116115 this .scrollDirection = Axis .horizontal,
117116 this .customSize,
118- }) : _isBuilder = false ,
119- itemCount = null ,
117+ }) : itemCount = null ,
120118 builder = null ,
121119 assert (pageOptions != null ),
122120 super (key: key);
@@ -128,7 +126,6 @@ class PhotoViewGallery extends StatefulWidget {
128126 Key key,
129127 @required this .itemCount,
130128 @required this .builder,
131- @Deprecated ("Use loadingBuilder instead" ) this .loadingChild,
132129 this .loadingBuilder,
133130 this .loadFailedChild,
134131 this .backgroundDecoration,
@@ -141,8 +138,7 @@ class PhotoViewGallery extends StatefulWidget {
141138 this .scrollPhysics,
142139 this .scrollDirection = Axis .horizontal,
143140 this .customSize,
144- }) : _isBuilder = true ,
145- pageOptions = null ,
141+ }) : pageOptions = null ,
146142 assert (itemCount != null ),
147143 assert (builder != null ),
148144 super (key: key);
@@ -162,9 +158,6 @@ class PhotoViewGallery extends StatefulWidget {
162158 /// Mirror to [PhotoView.loadingBuilder]
163159 final LoadingBuilder loadingBuilder;
164160
165- /// Mirror to [PhotoView.loadingchild]
166- final Widget loadingChild;
167-
168161 /// Mirror to [PhotoView.loadFailedChild]
169162 final Widget loadFailedChild;
170163
@@ -195,7 +188,7 @@ class PhotoViewGallery extends StatefulWidget {
195188 /// The axis along which the [PageView] scrolls. Mirror to [PageView.scrollDirection]
196189 final Axis scrollDirection;
197190
198- final bool _isBuilder;
191+ bool get _isBuilder => builder != null ;
199192
200193 @override
201194 State <StatefulWidget > createState () {
@@ -277,7 +270,6 @@ class _PhotoViewGalleryState extends State<PhotoViewGallery> {
277270 key: ObjectKey (index),
278271 imageProvider: pageOption.imageProvider,
279272 loadingBuilder: widget.loadingBuilder,
280- loadingChild: widget.loadingChild,
281273 loadFailedChild: widget.loadFailedChild,
282274 backgroundDecoration: widget.backgroundDecoration,
283275 controller: pageOption.controller,
0 commit comments