Class: Y2Packager::Dialogs::ProductLicenseTranslations

Inherits:
CWM::Dialog
  • Object
show all
Defined in:
src/lib/y2packager/dialogs/product_license_translations.rb

Overview

This dialog displays available translation for a given product.

The dialog is open as a pop-up (check #should_open_dialog, #wizard_create_dialog and #layout for technical details) and it relies heavily on the Widgets::ProductLicenseTranslations widget.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(product, language = nil) ⇒ ProductLicenseTranslations


35
36
37
38
39
40
41
# File 'src/lib/y2packager/dialogs/product_license_translations.rb', line 35

def initialize(product, language = nil)
  super()
  textdomain "packager"

  @product = product
  @language = language || Yast::Language.language
end

Instance Attribute Details

#languageString (readonly)


31
32
33
# File 'src/lib/y2packager/dialogs/product_license_translations.rb', line 31

def language
  @language
end

#productY2Packager::Product (readonly)


29
30
31
# File 'src/lib/y2packager/dialogs/product_license_translations.rb', line 29

def product
  @product
end

Instance Method Details

#contentsYast::Term

Dialog content


53
54
55
56
57
# File 'src/lib/y2packager/dialogs/product_license_translations.rb', line 53

def contents
  VBox(
    Y2Packager::Widgets::ProductLicenseTranslations.new(product, language)
  )
end

#titleString

Returns the dialog title


46
47
48
# File 'src/lib/y2packager/dialogs/product_license_translations.rb', line 46

def title
  _("License Agreement")
end