Class: Bootloader::BootCodeTab

Inherits:
CWM::Tab
  • Object
show all
Includes:
Grub2Widget
Defined in:
src/lib/bootloader/grub2_widgets.rb

Overview

Represent tab with options related to stage1 location and bootloader type

Instance Method Summary (collapse)

Methods included from Grub2Widget

#grub2, #grub_default, #password, #sections, #stage1

Constructor Details

- (BootCodeTab) initialize

Returns a new instance of BootCodeTab



799
800
801
# File 'src/lib/bootloader/grub2_widgets.rb', line 799

def initialize
  self.initial = true
end

Instance Method Details

- (Object) contents



809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
# File 'src/lib/bootloader/grub2_widgets.rb', line 809

def contents
  widgets = []

  widgets << LoaderLocationWidget.new if loader_location_widget?

  if generic_mbr_widget?
    widgets << ActivateWidget.new
    widgets << GenericMBRWidget.new
  end

  widgets << SecureBootWidget.new if secure_boot_widget?

  widgets << TrustedBootWidget.new if trusted_boot_widget?

  widgets << PMBRWidget.new if pmbr_widget?

  widgets << DeviceMapWidget.new if device_map_button?

  widgets = widgets.map { |w| indented_widget(w) }
  VBox(
    LoaderTypeWidget.new,
    *widgets,
    VStretch()
  )
end

- (Object) label



803
804
805
806
807
# File 'src/lib/bootloader/grub2_widgets.rb', line 803

def label
  textdomain "bootloader"

  _("Boot Co&de Options")
end