- layerDialog now will be automatically opened:

* every time a raster is imported
* after the second mesh is loaded
This commit is contained in:
Guido Ranzuglia granzuglia 2012-10-02 12:48:09 +00:00
parent 6547210d04
commit 316a7edba7
3 changed files with 12 additions and 4 deletions

View File

@ -143,7 +143,7 @@ private slots:
void showInfoPane();
void showTrackBall();
void resetTrackBall();
void showLayerDlg();
void showLayerDlg(bool visible);
void showRaster();
///////////Slot Menu Windows /////////////////////
void updateWindowMenu();

View File

@ -313,7 +313,7 @@ void MainWindow::createActions()
showLayerDlgAct = new QAction (QIcon(":/images/layers.png"),tr("Show Layer Dialog"), this);
showLayerDlgAct->setCheckable(true);
showLayerDlgAct->setChecked(true);
connect(showLayerDlgAct, SIGNAL(triggered()), this, SLOT(showLayerDlg()));
connect(showLayerDlgAct, SIGNAL(triggered(bool)), this, SLOT(showLayerDlg(bool)));
showRasterAct = new QAction (QIcon(":/images/view_raster.png"),tr("Show Current Raster Mode"), this);

View File

@ -1906,6 +1906,7 @@ bool MainWindow::importRaster(const QString& fileImg)
rm->setLabel(fileImg);
rm->addPlane(new Plane(fileName,QString("")));
meshDoc()->setBusy(false);
showLayerDlg(true);
/// Intrinsics extraction from EXIF
/// If no CCD Width value is provided, the intrinsics are extracted using the Equivalent 35mm focal
@ -2139,7 +2140,7 @@ bool MainWindow::importMesh(QString fileName)
pCurrentIOPlugin->applyOpenParameter(extension, *mm, par);
}
if (meshDoc()->size() > 1)
showLayerDlg();
showLayerDlg(true);
}
else
GLA()->log->Logf(0,"Warning: Mesh %s has not been opened",qPrintable(fileName));
@ -2406,7 +2407,14 @@ void MainWindow::showInfoPane() {if(GLA() != 0) GLA()->infoAreaVisible =!GLA()-
void MainWindow::showTrackBall() {if(GLA() != 0) GLA()->showTrackBall(!GLA()->isTrackBallVisible());}
void MainWindow::resetTrackBall(){if(GLA() != 0) GLA()->resetTrackBall();}
void MainWindow::showRaster() {if(GLA() != 0) GLA()->showRaster((QApplication::keyboardModifiers () & Qt::ShiftModifier));}
void MainWindow::showLayerDlg() {if(GLA() != 0) layerDialog->setVisible( !layerDialog->isVisible() );}
void MainWindow::showLayerDlg(bool visible)
{
if(GLA() != 0)
{
layerDialog->setVisible( visible);
showLayerDlgAct->setChecked(visible);
}
}
void MainWindow::showXMLPluginEditorGui(){if(GLA() != 0) plugingui->setVisible( !plugingui->isVisible() );}