【发布时间】:2021-10-06 06:19:59
【问题描述】:
我尝试使用 singleChildScrollView 使用属性 reverse: true 将整个屏幕移动到键盘上方。但我只想将底部容器移动到键盘上方,就像在 google keep notes 应用程序中一样。
编辑:-
编辑 2:- 这是我想要在键盘上方的容器。它是列的一部分。
这是我的容器代码。
Container controlButtons() {
return Container(
margin: const EdgeInsets.all(20),
decoration: BoxDecoration(
border:
Border.all(color: Theme.of(context).textSelectionColor, width: 0.3),
borderRadius: BorderRadius.circular(20),
),
child: Padding(
padding: const EdgeInsets.all(12.0),
child: Row(
//row of back and next button
mainAxisAlignment: MainAxisAlignment.spaceBetween,
children: [
InkWell(
onTap: controlBack,
child: Row(
children: [
const Icon(Icons.arrow_back_ios),
(index != 0) ? const Text('Back') : const Text('Cancel'),
],
),
),
InkWell(
onTap: controlNext,
child: Row(
children: [
(index != 3) ? const Text('Next') : const Text('Save'),
const Icon(Icons.arrow_forward_ios),
],
),
),
],
),
),
);
}```
[![My App Screen Screenshot][2]][2]
【问题讨论】:
-
很抱歉,您的陈述仍然无法理解。请详细说明。如果事情变得可以理解,我一定会帮助你。
-
@ShrutiRamnandanSharma 我添加了一个记事本屏幕截图,其中容器位于键盘上方。我想在我的容器上实现相同的功能。
标签: android flutter flutter-layout