author | llornkcor <llornkcor> | 2002-12-05 18:36:11 (UTC) |
---|---|---|
committer | llornkcor <llornkcor> | 2002-12-05 18:36:11 (UTC) |
commit | 05757f4914d19f9c392be1e60e5ec972027886bf (patch) (side-by-side diff) | |
tree | 0096190bb2cf832d90ca93968952b9eccf3d3149 | |
parent | 418fd5dab5503755aa1783d404576252684d4a96 (diff) | |
download | opie-05757f4914d19f9c392be1e60e5ec972027886bf.zip opie-05757f4914d19f9c392be1e60e5ec972027886bf.tar.gz opie-05757f4914d19f9c392be1e60e5ec972027886bf.tar.bz2 |
fix beep so all sessions are the same
-rw-r--r-- | core/apps/embeddedkonsole/konsole.cpp | 8 |
1 files changed, 3 insertions, 5 deletions
diff --git a/core/apps/embeddedkonsole/konsole.cpp b/core/apps/embeddedkonsole/konsole.cpp index 9be4674..275a9a8 100644 --- a/core/apps/embeddedkonsole/konsole.cpp +++ b/core/apps/embeddedkonsole/konsole.cpp @@ -571,101 +571,99 @@ void Konsole::setFont(int fontno) } if ( !f.exactMatch() && fontno != 0) { QString msg = i18n("Font `%1' not found.\nCheck README.linux.console for help.").arg(fonts[fontno]); QMessageBox(this, msg); return; } if (se) se->setFontNo(fontno); te->setVTFont(f); n_font = fontno; } */ // --| color selection |------------------------------------------------------- void Konsole::changeColumns(int columns) { qDebug("change columns"); TEWidget* te = getTe(); if (te != 0) { setColLin(columns,te->Lines()); te->update(); } } //FIXME: If a child dies during session swap, // this routine might be called before // session swap is completed. void Konsole::doneSession(TESession*, int ) { TEWidget *te = getTe(); if (te != 0) { te->currentSession->setConnect(FALSE); tab->removeTab(te); delete te->currentSession; delete te; nsessions--; } if (nsessions == 0) { close(); } } void Konsole::newSession() { if(nsessions < 15) { // seems to be something weird about 16 tabs on the Zaurus.... memory? TEWidget* te = new TEWidget(tab); - if(nsessions == 0) { //set this the first time only - Config c("Konsole"); - c.setGroup("Menubar"); - te->useBeep=c.readBoolEntry("useBeep",0); - } + Config c("Konsole"); + c.setGroup("Menubar"); + te->useBeep=c.readBoolEntry("useBeep",0); // te->setBackgroundMode(PaletteBase); //we want transparent!! te->setVTFont(fonts.at(cfont)->getFont()); tab->addTab(te); TESession* se = new TESession(this, te, se_pgm, se_args, "xterm"); te->currentSession = se; connect( se, SIGNAL(done(TESession*,int)), this, SLOT(doneSession(TESession*,int)) ); se->run(); se->setConnect(TRUE); se->setHistory(b_scroll); tab->setCurrentPage(nsessions); nsessions++; doWrap(); setColor(); } } TEWidget* Konsole::getTe() { if (nsessions) { return (TEWidget *) tab->currentPage(); } else { return 0; } } void Konsole::switchSession(QWidget* w) { TEWidget* te = (TEWidget *) w; QFont teFnt = te->getVTFont(); for(uint i = 0; i < fonts.count(); i++) { VTFont *fnt = fonts.at(i); bool cf = fnt->getFont() == teFnt; fontList->setItemChecked(i, cf); if (cf) { cfont = i; } } } void Konsole::colorMenuIsSelected(int iD) { fromMenu = TRUE; colorMenuSelected(iD); } /// ------------------------------- some new stuff by L.J. Potter void Konsole::colorMenuSelected(int iD) { // this is NOT pretty, elegant or anything else besides functional // QString temp; |