2021-07-16 16:19:11 +00:00
|
|
|
""" Overview
|
|
|
|
|
|
|
|
Overview provides user with the overview of all the current settings.
|
|
|
|
|
|
|
|
"""
|
|
|
|
|
|
|
|
import logging
|
|
|
|
|
|
|
|
from subiquitycore.ui.buttons import done_btn
|
|
|
|
from subiquitycore.ui.utils import button_pile, screen
|
|
|
|
from subiquitycore.view import BaseView
|
|
|
|
|
|
|
|
log = logging.getLogger("ubuntu_wsl_oobe.ui.views.overview")
|
|
|
|
|
|
|
|
|
|
|
|
class OverviewView(BaseView):
|
|
|
|
title = _("Setup Complete")
|
|
|
|
|
2021-08-31 11:25:28 +00:00
|
|
|
def __init__(self, controller, real_name):
|
2021-07-16 16:19:11 +00:00
|
|
|
self.controller = controller
|
2021-08-31 11:25:28 +00:00
|
|
|
complete_text = _("Hi {real_name},\n\n"
|
2021-07-16 16:19:11 +00:00
|
|
|
"You have complete the setup!\n\n"
|
2021-08-31 11:25:28 +00:00
|
|
|
"It is suggested to run the following commands"
|
2021-08-12 14:31:27 +00:00
|
|
|
" to update your Ubuntu to the latest version:"
|
|
|
|
"\n\n\n"
|
2021-07-16 16:19:11 +00:00
|
|
|
" $ sudo apt update\n $ sudo apt upgrade\n\n\n"
|
2021-08-31 11:25:28 +00:00
|
|
|
"All settings will take effect after next "
|
|
|
|
"restart of Ubuntu.").format(real_name=real_name)
|
2021-07-16 16:19:11 +00:00
|
|
|
|
|
|
|
super().__init__(
|
|
|
|
screen(
|
|
|
|
rows=[],
|
|
|
|
buttons=button_pile(
|
|
|
|
[done_btn(_("Done"), on_press=self.confirm), ]),
|
|
|
|
focus_buttons=True,
|
|
|
|
excerpt=complete_text,
|
|
|
|
)
|
|
|
|
)
|
|
|
|
|
|
|
|
def confirm(self, result):
|
|
|
|
self.controller.done(result)
|