Logo Search packages:      
Sourcecode: kallery version File versions  Download package

void DescSourcePage::slotLoadDescriptions (  )  [private, slot]

Load the descriptions from a text file.

Definition at line 62 of file descsourcepage.cpp.

References OptionType::descList, OptionType::descSetting, OptionType::imageList, OptionType::LoadDescriptions, KalleryGlobals::options, KalleryFunctions::readDescriptions(), KalleryFunctions::ref(), KalleryGlobals::ref(), and setupPage().

{
  QString tempStr;

  tempStr = KFileDialog::getOpenFileName(QFileInfo(KalleryGlobals::ref()->options.fileName).dirPath(),"*",this,i18n("Select a description file"));
  if(!tempStr.isEmpty())
  {
    KalleryFunctions::ref()->readDescriptions(tempStr,KalleryGlobals::ref()->options.descList);
    for (uint i = KalleryGlobals::ref()->options.descList.count(); i < KalleryGlobals::ref()->options.imageList.count(); i ++)
    {
      KalleryGlobals::ref()->options.descList.append(OptionType::Description());
    }
    KalleryGlobals::ref()->options.descSetting = OptionType::LoadDescriptions;
    setupPage();
  }
}


Generated by  Doxygen 1.6.0   Back to index