Skip to content

Commit e23a45a

Browse files
committed
Buat function showDialogPermissionScreenRecording didalam widget_helper.dart
1 parent 2811da5 commit e23a45a

File tree

1 file changed

+47
-0
lines changed

1 file changed

+47
-0
lines changed

lib/core/util/widget_helper.dart

Lines changed: 47 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -84,4 +84,51 @@ class WidgetHelper {
8484
directory.createSync(recursive: true);
8585
return directoryPath;
8686
}
87+
88+
void showDialogPermissionScreenRecording(BuildContext context) {
89+
showDialog(
90+
context: context,
91+
barrierDismissible: false,
92+
builder: (context) {
93+
return AlertDialog(
94+
title: Text(
95+
'title_screen_recording_mac'.tr(),
96+
),
97+
content: Column(
98+
crossAxisAlignment: CrossAxisAlignment.start,
99+
mainAxisSize: MainAxisSize.min,
100+
children: [
101+
Text(
102+
'description_screen_recording_mac'.tr(),
103+
),
104+
Text.rich(
105+
TextSpan(
106+
children: [
107+
TextSpan(
108+
text: '\n${'note'.tr()}',
109+
),
110+
TextSpan(
111+
text: ' ${'note_description_screen_recording_mac'.tr()}',
112+
),
113+
],
114+
),
115+
style: Theme.of(context).textTheme.bodyMedium?.copyWith(
116+
fontStyle: FontStyle.italic,
117+
fontWeight: FontWeight.w500,
118+
),
119+
),
120+
],
121+
),
122+
actions: [
123+
TextButton(
124+
onPressed: () {
125+
Navigator.pop(context);
126+
},
127+
child: Text('ok'.tr()),
128+
),
129+
],
130+
);
131+
},
132+
);
133+
}
87134
}

0 commit comments

Comments
 (0)