Class: Y2Network::Widgets::EthtoolsOptions

Inherits:
CWM::InputField
  • Object
show all
Defined in:
src/lib/y2network/widgets/ethtools_options.rb

Instance Method Summary collapse

Constructor Details

#initialize(settings) ⇒ EthtoolsOptions

Returns a new instance of EthtoolsOptions.



26
27
28
29
30
31
# File 'src/lib/y2network/widgets/ethtools_options.rb', line 26

def initialize(settings)
  super()
  textdomain "network"

  @settings = settings
end

Instance Method Details

#helpObject



37
38
39
40
41
42
# File 'src/lib/y2network/widgets/ethtools_options.rb', line 37

def help
  _(
    "<p>If you specify options via <b>Ethtool options</b>, ifup will call " \
    "ethtool with these options.</p>\n"
  )
end

#initObject



48
49
50
# File 'src/lib/y2network/widgets/ethtools_options.rb', line 48

def init
  self.value = @settings.ethtool_options
end

#labelObject



33
34
35
# File 'src/lib/y2network/widgets/ethtools_options.rb', line 33

def label
  _("Ethtool Options")
end

#optObject



44
45
46
# File 'src/lib/y2network/widgets/ethtools_options.rb', line 44

def opt
  [:hstretch]
end

#storeObject



52
53
54
# File 'src/lib/y2network/widgets/ethtools_options.rb', line 52

def store
  @settings.ethtool_options = value
end