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

void NewProjectDlg::locationChanged ( const QString &   )  [slot]

Called when the projectName or projectLocation edit boxes are edited. Checks whether the resultant location combination is a valid path - if so, enabels the OK button; otherwise disables it.

Definition at line 65 of file projectdlgs.cpp.

{
      m_location = m_pWidget->projectLocationURL->url();
      QDir subDir(m_location);
    
      if ( !m_location.endsWith("/") )
            m_location.append("/");
    
      if ( !m_pWidget->projectNameEdit->text().isEmpty() )
            m_location.append( m_pWidget->projectNameEdit->text().lower() + "/" );
    
      m_pWidget->locationLabel->setText( m_location );
    
      QDir dir(m_location);
      
      if ( dir.exists() || !subDir.exists() ) 
            enableButtonOK(false);
      
      else
            enableButtonOK(true);
}


Generated by  Doxygen 1.6.0   Back to index