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



738
739
740
# File 'src/lib/bootloader/grub2_widgets.rb', line 738

def initialize
  self.initial = true
end

Instance Method Details

- (Object) contents



748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
# File 'src/lib/bootloader/grub2_widgets.rb', line 748

def contents
  widgets = []

  widgets << indented_widget(LoaderLocationWidget.new) if loader_location_widget?

  if generic_mbr_widget?
    widgets << indented_widget(ActivateWidget.new)
    widgets << indented_widget(GenericMBRWidget.new)
  end

  widgets << indented_widget(SecureBootWidget.new) if secure_boot_widget?

  widgets << indented_widget(PMBRWidget.new) if pmbr_widget?

  widgets << indented_widget(DeviceMapWidget.new) if device_map_button?

  VBox(
    LoaderTypeWidget.new,
    *widgets,
    VStretch()
  )
end

- (Object) label



742
743
744
745
746
# File 'src/lib/bootloader/grub2_widgets.rb', line 742

def label
  textdomain "bootloader"

  _("boot code options")
end