added 'view mlog'/'view msr' switch

This commit is contained in:
nemu 2009-02-27 11:32:04 +00:00
parent 0fc7f8c4bf
commit 0f2e10fd3b
2 changed files with 26 additions and 0 deletions

View File

@ -240,6 +240,17 @@ void PTextEdit::setupMusrActions()
connect( a, SIGNAL( activated() ), this, SLOT( musrPrefs() ) ); connect( a, SIGNAL( activated() ), this, SLOT( musrPrefs() ) );
a->addTo( tb ); a->addTo( tb );
a->addTo( menu ); a->addTo( menu );
fComboShowMlog = new QComboBox( TRUE, tb );
fComboShowMlog->setEditable(false);
fComboShowMlog->insertItem("view mlog");
fComboShowMlog->insertItem("view msr");
connect( fComboShowMlog, SIGNAL( activated( const QString & ) ),
this, SLOT( musrShowMlog( const QString & ) ) );
if (fShowMlog)
fComboShowMlog->setCurrentItem(0);
else
fComboShowMlog->setCurrentItem(1);
} }
//---------------------------------------------------------------------------------------------------- //----------------------------------------------------------------------------------------------------
@ -813,6 +824,18 @@ void PTextEdit::musrPrefs()
"NOT IMPLEMENTED YET :-(" ); "NOT IMPLEMENTED YET :-(" );
} }
//----------------------------------------------------------------------------------------------------
/**
* <p>
*/
void PTextEdit::musrShowMlog( const QString &str )
{
if (str.find("mlog") > 0)
fShowMlog = true;
else
fShowMlog = false;
}
//---------------------------------------------------------------------------------------------------- //----------------------------------------------------------------------------------------------------
/** /**
* <p> * <p>

View File

@ -84,6 +84,7 @@ private slots:
void musrView(); void musrView();
void musrT0(); void musrT0();
void musrPrefs(); void musrPrefs();
void musrShowMlog( const QString &str );
void helpContents(); void helpContents();
void helpAboutQt(); void helpAboutQt();
@ -100,6 +101,8 @@ private:
QComboBox *fComboFont; QComboBox *fComboFont;
QComboBox *fComboSize; QComboBox *fComboSize;
QComboBox *fComboShowMlog;
QTabWidget *fTabWidget; QTabWidget *fTabWidget;
QMap<QTextEdit*, QString> fFilenames; QMap<QTextEdit*, QString> fFilenames;
}; };