* ./mauka:
- Change: In GraphicMaukaEngine, simplificate the normal menu, put everything else in the "step by step" sub-menu.
This commit is contained in:
parent
6e91d50324
commit
41e93e7c65
|
@ -191,7 +191,7 @@ namespace Mauka {
|
|||
}
|
||||
|
||||
|
||||
void GraphicMaukaEngine::run ()
|
||||
void GraphicMaukaEngine::doSimulatedAnnealing ()
|
||||
{
|
||||
MaukaEngine* mauka = createEngine ();
|
||||
if ( mauka == NULL ) {
|
||||
|
@ -208,6 +208,19 @@ namespace Mauka {
|
|||
}
|
||||
|
||||
|
||||
void GraphicMaukaEngine::place ()
|
||||
{
|
||||
if ( not MetisEngine::isHMetisCapable() ) doQuadriPart ();
|
||||
else {
|
||||
cerr << Warning("Mauka has not been compiled againts hMETIS.\n"
|
||||
" Quadri-partition step is disabled, simulated annealing may be *very* long." ) << endl;
|
||||
}
|
||||
|
||||
doSimulatedAnnealing ();
|
||||
save ();
|
||||
}
|
||||
|
||||
|
||||
void GraphicMaukaEngine::save ()
|
||||
{
|
||||
MaukaEngine* mauka = createEngine ();
|
||||
|
@ -246,24 +259,31 @@ namespace Mauka {
|
|||
prMenu->addSeparator ();
|
||||
}
|
||||
|
||||
QAction* placeAction = _viewer->findChild<QAction*>("viewer.menuBar.placeAndRoute.maukaPlace");
|
||||
QAction* placeAction = _viewer->findChild<QAction*>("viewer.menuBar.placeAndRoute.place");
|
||||
if ( placeAction != NULL )
|
||||
cerr << Warning("GraphicMaukaEngine::addToMenu() - Mauka placer already hooked in.") << endl;
|
||||
else {
|
||||
QAction* quadriPartAction = new QAction ( tr("Mauka - &QuadriPartition"), _viewer );
|
||||
quadriPartAction->setObjectName ( "viewer.menuBar.quadriPartAndRoute.maukaQuadriPartition" );
|
||||
quadriPartAction->setObjectName ( "viewer.menuBar.placeAndRoute.quadriPartition" );
|
||||
quadriPartAction->setStatusTip ( tr("Run the <b>hMETIS</b> quadri-partitioner") );
|
||||
quadriPartAction->setVisible ( true );
|
||||
prMenu->addAction ( quadriPartAction );
|
||||
stepMenu->addAction ( quadriPartAction );
|
||||
|
||||
QAction* annealingAction = new QAction ( tr("Mauka - &Place"), _viewer );
|
||||
annealingAction->setObjectName ( "viewer.menuBar.placeAndRoute.maukaPlace" );
|
||||
annealingAction->setStatusTip ( tr("Run the <b>Mauka</b> placer") );
|
||||
annealingAction->setVisible ( true );
|
||||
stepMenu->addAction ( annealingAction );
|
||||
|
||||
QAction* placeAction = new QAction ( tr("Mauka - &Place"), _viewer );
|
||||
placeAction->setObjectName ( "viewer.menuBar.placeAndRoute.maukaPlace" );
|
||||
placeAction->setObjectName ( "viewer.menuBar.placeAndRoute.place" );
|
||||
placeAction->setStatusTip ( tr("Run the <b>Mauka</b> placer") );
|
||||
placeAction->setVisible ( true );
|
||||
prMenu->addAction ( placeAction );
|
||||
|
||||
connect ( placeAction , SIGNAL(triggered()), this, SLOT(run()) );
|
||||
connect ( quadriPartAction, SIGNAL(triggered()), this, SLOT(doQuadriPart()) );
|
||||
connect ( annealingAction , SIGNAL(triggered()), this, SLOT(doSimulatedAnnealing()) );
|
||||
connect ( placeAction , SIGNAL(triggered()), this, SLOT(place()) );
|
||||
}
|
||||
|
||||
connect ( this, SIGNAL(cellPreModificated ()), _viewer->getCellWidget(), SLOT(cellPreModificate ()) );
|
||||
|
|
|
@ -61,25 +61,26 @@ namespace Mauka {
|
|||
Q_OBJECT;
|
||||
|
||||
public:
|
||||
MaukaEngine* createEngine ();
|
||||
MaukaEngine* getForFramework ();
|
||||
static void initMaukaContainer ( CellWidget* );
|
||||
static void drawMaukaContainer ( CellWidget*
|
||||
, const Go*
|
||||
, const BasicLayer*
|
||||
, const Box&
|
||||
, const Transformation&
|
||||
);
|
||||
static GraphicMaukaEngine* grab ();
|
||||
virtual const Name& getName () const;
|
||||
Cell* getCell ();
|
||||
virtual size_t release ();
|
||||
virtual void addToMenu ( CellViewer* );
|
||||
void refreshViewer ();
|
||||
public slots:
|
||||
void doQuadriPart ();
|
||||
void run ();
|
||||
void save ();
|
||||
MaukaEngine* createEngine ();
|
||||
MaukaEngine* getForFramework ();
|
||||
static void initMaukaContainer ( CellWidget* );
|
||||
static void drawMaukaContainer ( CellWidget*
|
||||
, const Go*
|
||||
, const BasicLayer*
|
||||
, const Box&
|
||||
, const Transformation&
|
||||
);
|
||||
static GraphicMaukaEngine* grab ();
|
||||
virtual const Name& getName () const;
|
||||
Cell* getCell ();
|
||||
virtual size_t release ();
|
||||
virtual void addToMenu ( CellViewer* );
|
||||
void refreshViewer ();
|
||||
public slots:
|
||||
void doQuadriPart ();
|
||||
void doSimulatedAnnealing ();
|
||||
void place ();
|
||||
void save ();
|
||||
|
||||
protected:
|
||||
static size_t _references;
|
||||
|
|
Loading…
Reference in New Issue