~arcachofo/simulide/simulide_0.4.14

« back to all changes in this revision

Viewing changes to src/gui/circuitwidget/components/mcu/mcucomponent.cpp

  • Committer: arcachofo
  • Date: 2021-06-15 08:12:10 UTC
  • Revision ID: arcachofo@simulide.com-20210615081210-r6ko36sd5dcuf03t
Editor/Compiler: no Error msg if upload not successful.

Show diffs side-by-side

added added

removed removed

Lines of Context:
385
385
    else QMessageBox::warning( 0, tr("No File:"), tr("No File to reload ") );
386
386
}
387
387
 
388
 
void McuComponent::load( QString fileName )
 
388
bool McuComponent::load( QString fileName )
389
389
{
 
390
    bool ok = false;
390
391
    QDir circuitDir;
391
392
    if( m_subcDir != "" ) circuitDir.setPath( m_subcDir );
392
393
    else circuitDir = QFileInfo( Circuit::self()->getFileName() ).absoluteDir();
407
408
 
408
409
        QSettings* settings = MainWindow::self()->settings();
409
410
        settings->setValue( "lastFirmDir", m_symbolFile );
 
411
        ok = true;
410
412
    }
411
413
    //else QMessageBox::warning( 0, tr("Error:"), tr("Could not load: \n")+ fileName );
412
414
    
413
415
    if( pauseSim ) Simulator::self()->runContinuous();
 
416
    return ok;
414
417
}
415
418
 
416
419
void McuComponent::setSubcDir( QString dir ) // Used in subcircuits