# This file is generated by rbkconfig_compiler from test9.kcfg.
# All changes you do to this file will be lost.

class Test9 < KDE::ConfigSkeleton

  #
  # Set MyStringList
  #
  def setMyStringList(v)
    item = findItem("MyStringList")
    if !item.immutable?
      item.property = @myStringList = Qt::Variant.fromValue(v)
    end
  end

  def myStringList=(v)
    setMyStringList(v)
  end

  #
  # Get MyStringList
  #
  def myStringList
    @myStringList = findItem("MyStringList").property
    return @myStringList.value
  end

  #
  # Set This is a list of paths
  #
  def setMyPathList(v)
    item = findItem("MyPathList")
    if !item.immutable?
      item.property = @myPathList = Qt::Variant.fromValue(v)
    end
  end

  def myPathList=(v)
    setMyPathList(v)
  end

  #
  # Get This is a list of paths
  #
  def myPathList
    @myPathList = findItem("MyPathList").property
    return @myPathList.value
  end

  #
  # Set This is an additional test for PathList
  #
  def setMyPathsList2(v)
    item = findItem("MyPathsList2")
    if !item.immutable?
      item.property = @myPathsList2 = Qt::Variant.fromValue(v)
    end
  end

  def myPathsList2=(v)
    setMyPathsList2(v)
  end

  #
  # Get This is an additional test for PathList
  #
  def myPathsList2
    @myPathsList2 = findItem("MyPathsList2").property
    return @myPathsList2.value
  end

  def initialize(transport, folder)
    super("examplerc")
    @paramtransport = Qt::Variant.fromValue(transport)
    @paramfolder = Qt::Variant.fromValue(folder)

    # MyOptionsXX
    @myStringList = Qt::Variant.fromValue([])
    @myPathList = Qt::Variant.fromValue([])
    @myPathsList2 = Qt::Variant.fromValue([])
    setCurrentGroup("MyOptionsXX")

    defaultMyStringList = []
    defaultMyStringList << "up"
    defaultMyStringList << "down"

    itemMyStringList = ItemStringList.new(currentGroup(), "MyStringList", @myStringList.value, defaultMyStringList)
    itemMyStringList.property = @myStringList
    addItem(itemMyStringList)
    defaultMyPathList = []
    defaultMyPathList << "/home"
    defaultMyPathList << "~"

    itemMyPathList = ItemPathList.new(currentGroup(), "MyPathList", @myPathList.value, defaultMyPathList)
    itemMyPathList.property = @myPathList
    addItem(itemMyPathList)
    itemMyPathsList2 = ItemPathList.new(currentGroup(), "MyPathsList2", @myPathsList2.value, ["/usr/bin"] << Qt::Dir.homePath)
    itemMyPathsList2.property = @myPathsList2
    addItem(itemMyPathsList2)
  end

end
