Skip to content

Commit 70e6fba

Browse files
authored
Add a requirement checkbox to encourage booting stock rom at least once. (#316)
Resolves #307
2 parents 4c2afb0 + 985681e commit 70e6fba

File tree

1 file changed

+29
-0
lines changed

1 file changed

+29
-0
lines changed

openandroidinstaller/views/requirements_view.py

Lines changed: 29 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -214,6 +214,10 @@ def build(self):
214214
self.checkboxes.append(battery_checkbox)
215215
self.checkbox_cards.append(battery_check_card)
216216

217+
boot_stock_checkbox, boot_stock_check_card = self.get_boot_stock_check()
218+
self.checkboxes.append(boot_stock_checkbox)
219+
self.checkbox_cards.append(boot_stock_check_card)
220+
217221
lock_checkbox, lock_check_card = self.get_lock_check()
218222
self.checkboxes.append(lock_checkbox)
219223
self.checkbox_cards.append(lock_check_card)
@@ -251,6 +255,31 @@ def get_battery_check(self):
251255
)
252256
return battery_checkbox, battery_check_card
253257

258+
def get_boot_stock_check(self):
259+
"""Get checkbox and card for default requirements: boot stock once."""
260+
boot_stock_checkbox = Checkbox(
261+
label="Booted the stock OS at least once.",
262+
on_change=self.enable_continue_button,
263+
)
264+
boot_stock_check_card = Card(
265+
Container(
266+
content=Column(
267+
[
268+
Markdown(
269+
"""
270+
#### Boot your device with the stock OS at least once and check every functionality.
271+
Make sure that you can send and receive SMS and place and receive calls (also via WiFi and LTE, if available),
272+
otherwise it won\'t work on your custom ROM either! Additionally, some devices require that VoLTE/VoWiFi be utilized once on stock to provision IMS.
273+
"""
274+
),
275+
boot_stock_checkbox,
276+
]
277+
),
278+
padding=10,
279+
),
280+
)
281+
return boot_stock_checkbox, boot_stock_check_card
282+
254283
def get_lock_check(self):
255284
"""Get the checkbox and card for the default requirement: disable lock code and fingerprint."""
256285
lock_checkbox = Checkbox(

0 commit comments

Comments
 (0)