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

void KarchiveurApp::displayMessageArchiveSize (  ) 

Displays in the status bar the size of the archive

Definition at line 1143 of file karchiveur.cpp.

References archiveSize(), CArchiveChoice::getArchiveName(), and slotStatusMsg().

Referenced by slotComboDirectoriesActivated(), slotFileOpen(), slotMessageArchiveOperation(), slotMouseClick(), slotRemoveSelectedFiles(), slotRemoveThoseFiles(), and slotShowContextualMenu().

                                             {
  QString message;
  QString filesselected=i18n(" files selected");
  if(selectedfilesStatusbarMessage.nbselectedfiles==1)
    filesselected=i18n(" file selected");

  message=IDS_STATUS_DEFAULT;
  if(archivechoice->getArchiveName()!=NULL)
    message=QString("%1  -  %2 %3").arg(IDS_STATUS_DEFAULT)
                                   .arg(archiveSize(archivechoice->getArchiveName()))
                                   .arg(i18n("bytes"));
  if(selectedfilesStatusbarMessage.nbselectedfiles>0)
  {
    message+=QString(" - %1 %2 %3 %4") .arg( selectedfilesStatusbarMessage.nbselectedfiles)
                                       .arg(filesselected)
                                       .arg(selectedfilesStatusbarMessage.sizeselectedfiles)
                                       .arg(i18n("bytes"));
    editCut->setEnabled( true );
    editCopy->setEnabled( true );
    archiveViewSelection->setEnabled( true );
    archiveDeleteSelection->setEnabled(true);
    archiveDeleteToTrashSelection->setEnabled(true);
  }
  else
  {
    archiveViewSelection->setEnabled( false );
    archiveDeleteSelection->setEnabled(false);
    archiveDeleteToTrashSelection->setEnabled(false);
    editCut->setEnabled( false );
    editCopy->setEnabled( false );
  }
  
  slotStatusMsg(message);
}


Generated by  Doxygen 1.6.0   Back to index