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

Merge remote-tracking branch 'origin/null-safe' into 2.2.x #102

Merged
merged 110 commits into from
Mar 4, 2022
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
Show all changes
110 commits
Select commit Hold shift + click to select a range
0e14055
Null safe (#13)
zhoujuanjuan Dec 15, 2021
9fdb8fd
upgrade dependencies:collection to stable
laiiihz Dec 16, 2021
814920b
migrate constants to null safety
laiiihz Dec 16, 2021
5991726
migrate brn_multi_click_util to null safety
laiiihz Dec 16, 2021
540d5ce
migrate font util to null safety
laiiihz Dec 16, 2021
5ed705a
migrate brn_text_style to null safety
laiiihz Dec 16, 2021
9f41f43
migrate brn picker constants to null safety
laiiihz Dec 16, 2021
577299f
migrate brn appBar theme to null safety
laiiihz Dec 16, 2021
39281ea
optimize bruno theme's import (#16)
laiiihz Dec 20, 2021
ae53073
♻️ [NNBD] Part 1. Migrate configs (#28)
AlexV525 Dec 22, 2021
97b8b77
♻️ [NNBD] Part 2. Migrate utils (#30)
AlexV525 Dec 22, 2021
43acef4
:art: BrnSearchText (#36)
kalifun Dec 27, 2021
d2a37e0
Theme: 优化单例实现,初步优化 BrnAllThemeConfig 属性获取不为 null
zhoujuanjuan Dec 27, 2021
75a2be3
refactor:优化theme,暴露非null引用
zhoujuanjuan Dec 27, 2021
f97bf07
theme:去除无用信息及优化部分代码
zhoujuanjuan Dec 28, 2021
44ba17a
theme:增加属性类型
zhoujuanjuan Dec 28, 2021
d4a4212
Theme: 优化单例实现,初步优化 BrnAllThemeConfig 属性获取不为 null (#40)
zhoujuanjuan Dec 29, 2021
886c48e
🎨 utils-EventBus添加null-safe (#23)
kkkman22 Dec 30, 2021
081a7dc
refactor brn_toast (#33)
leftcoding Dec 30, 2021
cad7451
Merge branch 'LianjiaTech:null-safe' into null-safe
zhoujuanjuan Dec 31, 2021
c19203f
优化修复 EventBus
zhoujuanjuan Dec 31, 2021
7dff62a
优化 EventBus 单例实现 (#43)
zhoujuanjuan Dec 31, 2021
974e0da
brn_toast time change to seconds (#45)
leftcoding Jan 4, 2022
c96cdd3
Merge branch 'LianjiaTech:null-safe' into null-safe
zhoujuanjuan Jan 4, 2022
3ef1aa2
migrate brn_loading to null safety (#32)
laiiihz Jan 4, 2022
2c99d35
Merge branch 'LianjiaTech:null-safe' into null-safe
zhoujuanjuan Jan 4, 2022
6a36110
optimization brn_theme_configurator instance constructor (#47)
leftcoding Jan 4, 2022
c7ae392
Merge branch 'LianjiaTech:null-safe' into null-safe
zhoujuanjuan Jan 5, 2022
6e0834b
迁移example ,优化常量命名,增加export
zhoujuanjuan Jan 4, 2022
5db665d
migrate brn_empty_status.dart
zhoujuanjuan Jan 5, 2022
976d588
Migrate BrnStateTag、BrnTagCustom、BrnSelectTag、BrnDeleteTag to null-sa…
violinday Jan 5, 2022
7c12fc8
删除 BrnThemeImg
zhoujuanjuan Jan 6, 2022
0b75394
Merge remote-tracking branch 'upstream/null-safe' into null-safe
zhoujuanjuan Jan 6, 2022
c00cfd5
fix:tagConfig merge方法增加判空处理
zhoujuanjuan Jan 6, 2022
ada5216
fix:revert tagConfig
zhoujuanjuan Jan 7, 2022
beec378
fix:BrnAbnormalStateWidget空处理
zhoujuanjuan Jan 7, 2022
7d3ed35
reset and migrated package [rating] to null-safety. (#42)
jojinshallar Jan 7, 2022
0203e9f
迁移example ,优化常量命名,增加export (#51)
zhoujuanjuan Jan 7, 2022
b852eb6
Merge branch 'LianjiaTech:null-safe' into null-safe
zhoujuanjuan Jan 7, 2022
6df9863
空安全报错修改 (#55)
HappyImp Jan 7, 2022
e1a515e
优化sketch教程为视频教程
zhoujuanjuan Jan 10, 2022
46ec54a
Migrated package [selectcity] to null-safety (#56)
jojinshallar Jan 10, 2022
27dd619
migrate card_title to null safety (#59)
laiiihz Jan 10, 2022
e69a944
Merge branch 'LianjiaTech:null-safe' into null-safe
zhoujuanjuan Jan 10, 2022
232f347
Migrated package [radio] to null-safety (#62)
jojinshallar Jan 11, 2022
e31532f
Merge branch 'LianjiaTech:null-safe' into null-safe
zhoujuanjuan Jan 11, 2022
162fcfe
Migrated tabbar to null-safety
zhoujuanjuan Jan 11, 2022
fc0579a
Migrated package [guide] to null-safety (#65)
jojinshallar Jan 12, 2022
925350c
🚀 Use the latest Podfile for the example (#68)
AlexV525 Jan 12, 2022
4fe8680
Null safe calendar (#64)
laiiihz Jan 12, 2022
00c53b3
Card Components Null safe adapter (#53)
KennethYo Jan 12, 2022
2bd473f
Merge branch 'LianjiaTech:null-safe' into null-safe
zhoujuanjuan Jan 12, 2022
103ab13
Migrated scroll_anchor to null-safety
zhoujuanjuan Jan 11, 2022
2c991c4
fix #71 (#77)
leftcoding Jan 13, 2022
2b141fd
Merge branch 'LianjiaTech:null-safe' into null-safe
zhoujuanjuan Jan 13, 2022
7e25ffd
fix content_card themeData is not null (#79)
laiiihz Jan 13, 2022
2a4a43b
Null safe of all buttons (#20)
donywan Jan 14, 2022
8237c32
Migrated package [navbar][input] to null-safety (#75)
jojinshallar Jan 17, 2022
04b7a3e
Merge branch 'LianjiaTech:null-safe' into null-safe
zhoujuanjuan Jan 17, 2022
5748da7
fix:修复迁移tabar问题
zhoujuanjuan Jan 17, 2022
244a957
Migrated tabbar & scroll_anchor to null-safety (#66)
zhoujuanjuan Jan 17, 2022
a8101d4
Migrate Selection to null-safe (#54)
violinday Jan 17, 2022
8c25d72
Merge branch 'LianjiaTech:null-safe' into null-safe
zhoujuanjuan Jan 18, 2022
1c33fd9
migrate form to null safety
zhoujuanjuan Jan 18, 2022
07c308a
fix:修复tabbar报错及selection警告信息
zhoujuanjuan Jan 18, 2022
8e07cdf
Migrated package [dialog] to null-safety (#81)
jojinshallar Jan 19, 2022
fdf45af
Merge branch 'LianjiaTech:null-safe' into null-safe
zhoujuanjuan Jan 19, 2022
488f70d
migrate brn_horizontal_steps、brn_step_line to null safety (#89)
leftcoding Jan 21, 2022
0704e89
migrate charts to null safety (#80)
laiiihz Jan 23, 2022
79cb687
migrate actionsheet into null-safe (#73)
junlandroid Jan 23, 2022
e1749fe
Merge remote-tracking branch 'upstream/null-safe' into null-safe
zhoujuanjuan Jan 24, 2022
0b4c168
fix:修复迁移问题
zhoujuanjuan Jan 24, 2022
3f3b4d3
fix:优化迁移部分问题key和style非空问题
zhoujuanjuan Jan 24, 2022
8344fb9
migrate form to null safety (#86)
zhoujuanjuan Jan 24, 2022
1b89f72
Merge branch 'LianjiaTech:null-safe' into null-safe
zhoujuanjuan Jan 24, 2022
8b9e3ab
migrate picker to null safety
zhoujuanjuan Jan 24, 2022
8629bb0
migrate popup to null safety (#69)
hexintao Jan 24, 2022
04432c6
migrate gallery to null safety (#90)
Nayuta403 Jan 25, 2022
fbe085a
Merge branch 'LianjiaTech:null-safe' into null-safe
zhoujuanjuan Jan 25, 2022
2d7fcc1
fix:修复picker空安全迁移问题
zhoujuanjuan Jan 25, 2022
49e9147
migrate appraise dir to null safety (#84)
hexintao Jan 25, 2022
a23e201
fix:修复list没指定泛型及if判断错误问题
zhoujuanjuan Jan 26, 2022
4fa42f7
Merge branch 'LianjiaTech:null-safe' into null-safe
zhoujuanjuan Jan 26, 2022
33ed04a
fix:migrate dashed line to null safty
zhoujuanjuan Jan 26, 2022
a4c1a74
migrate picker to null safety (#91)
zhoujuanjuan Jan 26, 2022
4300e62
Merge branch 'LianjiaTech:null-safe' into null-safe
zhoujuanjuan Jan 26, 2022
069436d
migrate example to null safty
zhoujuanjuan Jan 26, 2022
3e28aa4
fix:修复部分example warning
zhoujuanjuan Jan 26, 2022
00f8a47
fix:修复demo报错问题
zhoujuanjuan Jan 27, 2022
8b17ba3
fix:追加未跟踪修复
zhoujuanjuan Jan 27, 2022
a526542
fix:优化部分接口可空参数为非空
zhoujuanjuan Jan 27, 2022
7add53d
Perf:Button Null safe (#93)
violinday Jan 27, 2022
966b63e
Merge branch 'null-safe' into null-safe
violinday Feb 7, 2022
5401fba
migrate example to null safety (#94)
zhoujuanjuan Feb 14, 2022
7028763
Merge branch 'LianjiaTech:null-safe' into null-safe
zhoujuanjuan Feb 14, 2022
4c62a0c
fix:修复tabar showmore overflow 问题 #98 以及 tabbar 标签颜色默认设置倒置问题
zhoujuanjuan Feb 16, 2022
140cd43
Fix #98 问题及优化部分代码 (#99)
zhoujuanjuan Feb 16, 2022
dcc5731
refactor:优化 BrnInputItemType 常量命名
zhoujuanjuan Feb 16, 2022
fb34dc0
Merge branch 'LianjiaTech:null-safe' into null-safe
zhoujuanjuan Feb 16, 2022
6b10b9c
refactor:优化枚举值命名
zhoujuanjuan Feb 16, 2022
589daf1
fix:修改docs目录下form相关常量命名及所有枚举命名
zhoujuanjuan Feb 16, 2022
a7ec085
优化 BrnInputItemType 常量命名 (#100)
zhoujuanjuan Feb 17, 2022
295b16a
Merge branch 'LianjiaTech:null-safe' into null-safe
zhoujuanjuan Feb 17, 2022
2ead0c1
refactor: 更新 changelog
zhoujuanjuan Feb 17, 2022
b67f8b9
Merge branch 'LianjiaTech:2.2.x' into 2.2.x
zhoujuanjuan Feb 17, 2022
f1d0efc
Merge remote-tracking branch 'origin/null-safe' into 2.2.x
zhoujuanjuan Feb 17, 2022
97f6a1f
refactor:BrnBubbleText 增加属性 bgColor、textStyle,修复demo actionSheet、gal…
zhoujuanjuan Feb 18, 2022
9748fac
fix:修复changelog 错误,brn_gallery_summary_page.dart 中标题空处理
zhoujuanjuan Feb 22, 2022
b0092e0
fix:修复部分问题
zhoujuanjuan Mar 4, 2022
d370e7b
fix:修复部分问题
zhoujuanjuan Mar 4, 2022
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -286,7 +286,7 @@ class _BrnActionSheetSelectedItemListState<T>
AnimationController alphaAnimationController = AnimationController(
duration: const Duration(milliseconds: 200), vsync: this);
widget._alphaAnimationController = alphaAnimationController;
Animation yAnimation = Tween(begin: 65.0, end: this.getContentHeight())
Animation<double> yAnimation = Tween<double>(begin: 65.0, end: this.getContentHeight())
.animate(yAnimationController)
..addListener(() {
setState(() => {});
Expand Down
2 changes: 1 addition & 1 deletion lib/src/components/charts/broken_line/brn_broken_line.dart
Original file line number Diff line number Diff line change
Expand Up @@ -95,7 +95,7 @@ class BrnBrokenLine extends StatefulWidget {
this.isShowXDialText = false,
this.isShowYDialText = false,
}) : super(key: key) {
/// 设置自定义 X 轴时,检查 x轴的最大、最小刻度范围
// 设置自定义 X 轴时,检查 x轴的最大、最小刻度范围
if (xDialValues != null) {
assert(xDialMin != null);
assert(xDialMax != null);
Expand Down
6 changes: 3 additions & 3 deletions lib/src/components/charts/broken_line/brn_line_painter.dart
Original file line number Diff line number Diff line change
Expand Up @@ -377,8 +377,8 @@ class BrnLinePainter extends BrnBasePainter {
void _drawLine(Canvas canvas) {
_lineCanvasModels.forEach((element) {
//阴影区域
if (element.shadowPaths != null && element.shaderColors != null) {
element.shadowPaths!.forEach((shadowPathElement) {
if (element.shaderColors != null) {
element.shadowPaths.forEach((shadowPathElement) {
var shader = LinearGradient(
begin: Alignment.topCenter,
end: Alignment.bottomCenter,
Expand Down Expand Up @@ -577,7 +577,7 @@ class LineCanvasModel {
final Color pathColor;
final double pathWidth;

final List<Path>? shadowPaths;
final List<Path> shadowPaths;
final List<Color>? shaderColors;
violinday marked this conversation as resolved.
Show resolved Hide resolved

final List<Point>? points;
Expand Down
87 changes: 21 additions & 66 deletions lib/src/components/dialog/brn_dialog.dart
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,7 @@ const Divider cDividerLine = const Divider(
color: Color(0xF0F0F0F0),
);

enum ButtonType {
enum _ButtonType {
/// 单按钮
single,

Expand Down Expand Up @@ -239,9 +239,6 @@ class BrnDialog extends AlertDialog {
/// 水平分割线
final Divider divider;

/// 对话框样式
final BrnDialogStyle? brnDialogStyle;

/// 底部按钮的点击监听回调
final DialogIndexedActionClickCallback? indexedActionCallback;

Expand All @@ -267,7 +264,6 @@ class BrnDialog extends AlertDialog {
this.warningText,
this.warningWidget,
this.actionsWidget,
this.brnDialogStyle,
this.divider = cDividerLine,
this.verticalDivider = cVerticalDivider,
this.actionsText,
Expand All @@ -278,8 +274,7 @@ class BrnDialog extends AlertDialog {

@override
Widget build(BuildContext context) {
BrnDialogConfig? defaultConfig =
_convertStyleToConfig() ?? BrnDialogConfig();
BrnDialogConfig? defaultConfig = BrnDialogConfig();

defaultConfig = BrnThemeConfigurator.instance
.getConfig(configId: defaultConfig.configId)
Expand Down Expand Up @@ -441,23 +436,23 @@ class BrnDialog extends AlertDialog {
/// 单个button 左右有圆角
/// 两个button 左button有左圆角&右直角 右button有右圆角&左直角
/// 多个button 最后一个左右圆角 其他均直角
Widget _generateMainWidget(Widget widget, Color background, ButtonType type,
Widget _generateMainWidget(Widget widget, Color background, _ButtonType type,
int index, BrnDialogConfig dialogConfig) {
return Container(
decoration: ShapeDecoration(
color: background,
shape: RoundedRectangleBorder(
borderRadius: BorderRadius.only(
bottomLeft: Radius.circular(type == ButtonType.single ||
type == ButtonType.left ||
(type == ButtonType.multi &&
bottomLeft: Radius.circular(type == _ButtonType.single ||
type == _ButtonType.left ||
(type == _ButtonType.multi &&
actionsText != null &&
index == actionsText!.length - 1)
? BrnDialogUtils.getDialogRadius(dialogConfig)
: 0),
bottomRight: Radius.circular(type == ButtonType.single ||
type == ButtonType.right ||
(type == ButtonType.multi &&
bottomRight: Radius.circular(type == _ButtonType.single ||
type == _ButtonType.right ||
(type == _ButtonType.multi &&
actionsText != null &&
index == actionsText!.length - 1)
? BrnDialogUtils.getDialogRadius(dialogConfig)
Expand All @@ -476,24 +471,24 @@ class BrnDialog extends AlertDialog {
/// 单个button 左右有圆角
/// 两个button 左button有左圆角&右直角 右button有右圆角&左直角
/// 多个button 最后一个左右圆角 其他均直角
Widget _generateGreyWidget(Widget widget, Color background, ButtonType type,
Widget _generateGreyWidget(Widget widget, Color background, _ButtonType type,
int index, BrnDialogConfig dialogConfig) {
return Container(
constraints: BoxConstraints.tightFor(height: cBottomHeight),
decoration: ShapeDecoration(
color: background,
shape: RoundedRectangleBorder(
borderRadius: BorderRadius.only(
bottomLeft: Radius.circular(type == ButtonType.single ||
type == ButtonType.left ||
(type == ButtonType.multi &&
bottomLeft: Radius.circular(type == _ButtonType.single ||
type == _ButtonType.left ||
(type == _ButtonType.multi &&
actionsText != null &&
index == actionsText!.length - 1)
? BrnDialogUtils.getDialogRadius(dialogConfig)
: 0),
bottomRight: Radius.circular(type == ButtonType.single ||
type == ButtonType.right ||
(type == ButtonType.multi &&
bottomRight: Radius.circular(type == _ButtonType.single ||
type == _ButtonType.right ||
(type == _ButtonType.multi &&
actionsText != null &&
index == actionsText!.length - 1)
? BrnDialogUtils.getDialogRadius(dialogConfig)
Expand All @@ -519,7 +514,7 @@ class BrnDialog extends AlertDialog {
0,
true,
defaultConfig,
type: ButtonType.single,
type: _ButtonType.single,
)
: actionsWidget![0];
} else if (length == 2) {
Expand All @@ -531,7 +526,7 @@ class BrnDialog extends AlertDialog {
child: showTextActions
? _mapTextToGesWidget(
context, actionsText![0], 0, false, defaultConfig,
type: ButtonType.left)
type: _ButtonType.left)
: actionsWidget![0],
),
Container(
Expand All @@ -542,7 +537,7 @@ class BrnDialog extends AlertDialog {
child: showTextActions
? _mapTextToGesWidget(
context, actionsText![1], 1, true, defaultConfig,
type: ButtonType.right)
type: _ButtonType.right)
: actionsWidget![1],
)
],
Expand All @@ -558,7 +553,7 @@ class BrnDialog extends AlertDialog {
return showTextActions
? _mapTextToGesWidget(
context, actionsText![i], i, true, defaultConfig,
type: ButtonType.multi)
type: _ButtonType.multi)
: actionsWidget![i];
},
separatorBuilder: (context, i) {
Expand All @@ -571,7 +566,7 @@ class BrnDialog extends AlertDialog {

Widget _mapTextToGesWidget(BuildContext context, String label, int index,
bool main, BrnDialogConfig dialogConfig,
{ButtonType type = ButtonType.single}) {
{_ButtonType type = _ButtonType.single}) {
Text text = Text(label);
Widget ges = GestureDetector(
child: main
Expand Down Expand Up @@ -619,43 +614,6 @@ class BrnDialog extends AlertDialog {
return actionsWidget == null || actionsWidget!.isEmpty;
}

/// 将已有的BrnDialogStyle转换成BrnDialogConfig
/// 当用户配置了最新的themeData则ljDialogStyle失效
/// 当用户配置仅配置ljDialogStyle,则将ljDialogStyle转换成themeData
BrnDialogConfig? _convertStyleToConfig() {
if (brnDialogStyle == null) {
return themeData;
}
BrnDialogConfig defaultConfig = themeData ?? BrnDialogConfig();
defaultConfig = defaultConfig.merge(BrnDialogConfig(
mainActionTextStyle:
BrnTextStyle.withStyle(brnDialogStyle!.mainTextStyle),
mainActionBackgroundColor: brnDialogStyle!.mainBackgroundColor,
assistActionsTextStyle:
BrnTextStyle.withStyle(brnDialogStyle!.greyActionsTextStyle),
assistActionsBackgroundColor: brnDialogStyle!.greyActionsBackgroundColor,
radius: brnDialogStyle!.radius,
iconPadding: brnDialogStyle!.iconPadding,
titlePaddingSm: brnDialogStyle!.titlePadding,
titlePaddingLg: brnDialogStyle!.titlePadding,
titleTextAlign: brnDialogStyle!.titleTextAlign,
titleTextStyle: BrnTextStyle.withStyle(brnDialogStyle!.titleTextStyle),
contentPaddingSm: brnDialogStyle!.contentPadding,
contentPaddingLg: brnDialogStyle!.contentPadding,
contentTextAlign: brnDialogStyle!.contentTextAlign,
contentTextStyle:
BrnTextStyle.withStyle(brnDialogStyle!.contentTextStyle),
warningPaddingSm: brnDialogStyle!.warningPadding,
warningPaddingLg: brnDialogStyle!.warningPadding,
warningTextAlign: brnDialogStyle!.warningTextAlign,
warningTextStyle:
BrnTextStyle.withStyle(brnDialogStyle!.warningTextStyle),
bottomHeight: brnDialogStyle!.bottomHeight,
backgroundColor: brnDialogStyle!.backgroundColor,
));
return defaultConfig;
}

/// 主题配置的标题间距
EdgeInsetsGeometry _configTitlePadding(BrnDialogConfig dialogConfig) {
return _isShowIcon()
Expand Down Expand Up @@ -743,7 +701,6 @@ class BrnDialogManager {
warningText: warning,
warningWidget: warningWidget,
actionsText: [label],
brnDialogStyle: dialogStyle,
actionsWidget: actionsWidget,
titleMaxLines: titleMaxLines,
themeData: themeData,
Expand Down Expand Up @@ -808,7 +765,6 @@ class BrnDialogManager {
warningText: warning,
themeData: themeData,
titleMaxLines: titleMaxLines,
brnDialogStyle: dialogStyle,
actionsText: [cancel, confirm],
actionsWidget: actionsWidget,
indexedActionCallback: (index) {
Expand Down Expand Up @@ -862,7 +818,6 @@ class BrnDialogManager {
contentWidget: messageWidget,
warningWidget: warningWidget,
warningText: warning,
brnDialogStyle: dialogStyle,
actionsText: actions,
actionsWidget: actionsWidget,
themeData: themeData,
Expand Down
14 changes: 7 additions & 7 deletions lib/src/components/dialog/brn_enhance_operation_dialog.dart
Original file line number Diff line number Diff line change
Expand Up @@ -8,16 +8,16 @@ import 'package:flutter/material.dart';

class BrnDialogConstants {
/// 提示图标
static const int ICON_ALERT = 0;
static const int iconAlert = 0;

/// 警示图标
static const int ICON_WARNING = 1;
static const int iconWarning = 1;

/// 成功图标
static const int ICON_SUCCESS = 2;
static const int iconSuccess = 2;

/// 自定义图标
static const int ICON_CUSTOM = 100;
static const int iconCustom = 100;

/// icon地址列表
static const List shareItemImagePathList = [
Expand All @@ -34,7 +34,7 @@ class BrnEnhanceOperationDialog extends StatelessWidget {
/// 构建环境上下文
final BuildContext context;

/// 图片类型,默认 0,[BrnDialogConstants.ICON_ALERT]
/// 图片类型,默认 0,[BrnDialogConstants.iconAlert]
final int iconType;

/// 自定义图标
Expand Down Expand Up @@ -62,7 +62,7 @@ class BrnEnhanceOperationDialog extends StatelessWidget {
BrnDialogConfig? themeData;

BrnEnhanceOperationDialog({
this.iconType = BrnDialogConstants.ICON_ALERT,
this.iconType = BrnDialogConstants.iconAlert,
this.customIconWidget,
required this.context,
this.titleText,
Expand All @@ -86,7 +86,7 @@ class BrnEnhanceOperationDialog extends StatelessWidget {
type: MaterialType.transparency,
child: BrnDialog(
themeData: themeData,
iconImage: (iconType == BrnDialogConstants.ICON_CUSTOM)
iconImage: (iconType == BrnDialogConstants.iconCustom)
? customIconWidget as Image
: BrunoTools.getAssetImage(
BrnDialogConstants.shareItemImagePathList[iconType]),
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ abstract class BaseAZListViewPage extends StatefulWidget {
}

class _BaseAZListViewPageState extends State<BaseAZListViewPage> {
String? suspensionTag = "";
String suspensionTag = "";

List<ISuspensionBean> _dataList = [];
late StreamController<String> streamController;
Expand Down
2 changes: 1 addition & 1 deletion lib/src/components/selectcity/brn_index_bar.dart
Original file line number Diff line number Diff line change
Expand Up @@ -200,7 +200,7 @@ class _IndexBarState extends State<_IndexBar> {
onVerticalDragDown: (DragDownDetails details) {
if (_widgetTop == -1 || _widgetTopChange) {
_widgetTopChange = false;
RenderBox? box = context.findRenderObject() as RenderBox;
RenderBox box = context.findRenderObject() as RenderBox;
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

findRenderObject() 返回是可空的
image

Offset topLeftPosition = box.localToGlobal(Offset.zero);
_widgetTop = topLeftPosition.dy.toInt();
}
Expand Down