19
19
* You should have received a copy of the GNU Library General Public
20
20
* License along with this program; if not, write to the Free
21
* Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
21
* Software Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
26
24
// include files for QT
28
#include <qapplication.h>
29
#include <qpopupmenu.h>
31
#include <qinputdialog.h>
27
#include <qcheckbox.h>
28
#include <qradiobutton.h>
29
#include <qwidgetstack.h>
35
33
// include files for KDE
34
#include <kcombobox.h>
36
35
#include <kiconloader.h>
37
36
#include <kmessagebox.h>
38
37
#include <kmenubar.h>
38
#include <klineeditdlg.h>
39
39
#include <klocale.h>
40
40
#include <kconfig.h>
41
41
#include <kaction.h>
42
#include <kapplication.h>
42
43
#include <kstdaction.h>
43
44
#include <kpanelapplet.h>
44
45
#include <kpopupmenu.h>
45
46
#include <khelpmenu.h>
46
#include <kiconloader.h>
47
47
#include <kdebug.h>
48
48
#include <kaccel.h>
49
#include <kpopupmenu.h>
50
51
// application specific includes
52
#include "mixertoolbox.h"
52
54
#include "kmixerwidget.h"
53
55
#include "kmixprefdlg.h"
54
56
#include "kmixdockwidget.h"
58
: KUniqueApplication(), m_kmix( 0 )
69
int KMixApp::newInstance()
74
m_kmix = new KMixWindow;
75
if ( isRestored() && KMainWindow::canBeRestored(0) )
76
m_kmix->restore(0, FALSE);
57
#include "kmixtoolbox.h"
61
* Constructs a mixer window (KMix main window)
83
63
KMixWindow::KMixWindow()
84
: KMainWindow(0, 0, 0 ), m_maxId( 0 ), m_visibleTabs( 0 ), m_dockWidget( 0L )
64
: KMainWindow(0, 0, 0 ), m_showTicks( true ),
92
// create mixer widgets for unused mixers
93
for (Mixer *mixer=m_mixers.first(); mixer!=0; mixer=m_mixers.next()) {
95
// search for mixer widget with current mixer
97
for ( widget=m_mixerWidgets.first(); widget!=0; widget=m_mixerWidgets.next() )
98
if ( widget->mixer()==mixer ) break;
103
KMixerWidget *mw = new KMixerWidget( m_maxId, mixer,
106
false, KPanelApplet::Up,
108
mw->setName( mixer->mixerName() );
109
insertMixerWidget( mw );
119
if ( m_startVisible )
68
m_visibilityUpdateAllowed = true;
69
m_multiDriverMode = false; // -<- I never-ever want the multi-drivermode to be activated by accident
70
m_surroundView = false; // -<- The same is true for the experimental surround View (3D)
71
// As long as we do not know better, we assume to start hidden. We need
72
// to initialize this variable here, as we don't trigger a hideEvent().
74
m_mixerWidgets.setAutoDelete(true);
75
loadConfig(); // Need to load config before initMixer(), due to "MultiDriver" keyword
76
MixerToolBox::initMixer(m_mixers, m_multiDriverMode, m_hwInfoString);
86
/* Started visible: We should do probably do:
88
* But as a showEvent() is triggered by show() we don't need it.
96
connect( kapp, SIGNAL( aboutToQuit()), SLOT( saveSettings()) );
126
100
KMixWindow::~KMixWindow()
106
KMixWindow::initActions()
109
KStdAction::quit( this, SLOT(quit()), actionCollection());
112
KStdAction::showMenubar( this, SLOT(toggleMenuBar()), actionCollection());
113
KStdAction::preferences( this, SLOT(showSettings()), actionCollection());
114
KStdAction::keyBindings( guiFactory(), SLOT(configureShortcuts()), actionCollection());
116
/* Belongs in KMixDockWidget
117
(void)new KToggleAction( i18n( "M&ute" ), 0, this, SLOT( dockMute() ),
118
actionCollection(), "dock_mute" );
120
(void) new KAction( i18n( "Hardware &Information" ), 0, this, SLOT( slotHWInfo() ), actionCollection(), "hwinfo" );
121
(void) new KAction( i18n( "Hide Mixer Window" ), Key_Escape, this, SLOT(hide()), actionCollection(), "hide_kmixwindow" );
122
createGUI( "kmixui.rc" );
127
KMixWindow::initPrefDlg()
129
m_prefDlg = new KMixPrefDlg( this );
130
connect( m_prefDlg, SIGNAL(signalApplied(KMixPrefDlg *)),
131
this, SLOT(applyPrefs(KMixPrefDlg *)) );
136
KMixWindow::initWidgets()
138
// Main widget and layout
139
setCentralWidget( new QWidget( this, "qt_central_widget" ) );
142
widgetsLayout = new QVBoxLayout( centralWidget(), 0, 0, "widgetsLayout" );
143
widgetsLayout->setResizeMode(QLayout::Minimum); // works fine
147
mixerNameLayout = new QHBox( centralWidget(), "mixerNameLayout" );
148
widgetsLayout->setStretchFactor( mixerNameLayout, 0 );
149
QSizePolicy qsp( QSizePolicy::Ignored, QSizePolicy::Maximum);
150
mixerNameLayout->setSizePolicy(qsp);
151
mixerNameLayout->setSpacing(KDialog::spacingHint());
152
QLabel *qlbl = new QLabel( i18n(" Current mixer:"), mixerNameLayout );
153
qlbl->setFixedHeight(qlbl->sizeHint().height());
154
m_cMixer = new KComboBox( FALSE, mixerNameLayout, "mixerCombo" );
155
m_cMixer->setFixedHeight(m_cMixer->sizeHint().height());
156
connect( m_cMixer, SIGNAL( activated( int ) ), this, SLOT( showSelectedMixer( int ) ) );
157
QToolTip::add( m_cMixer, i18n("Current mixer" ) );
159
// Add first layout to widgets
160
widgetsLayout->addWidget( mixerNameLayout );
162
m_wsMixers = new QWidgetStack( centralWidget(), "MixerWidgetStack" );
163
widgetsLayout->setStretchFactor( m_wsMixers, 10 );
164
widgetsLayout->addWidget( m_wsMixers );
171
widgetsLayout->activate();
176
KMixWindow::updateDocking()
178
// delete old dock widget
185
if (m_showDockWidget)
188
// create dock widget
189
// !! This should be a View in the future
190
m_dockWidget = new KMixDockWidget( m_mixers.first(), this, "mainDockWidget", m_volumeWidget );
192
/* Belongs in KMixDockWidget
194
KPopupMenu *menu = m_dockWidget->contextMenu();
197
KAction *a = actionCollection()->action( "dock_mute" );
198
if ( a ) a->plug( menu );
202
* Mail from 31.1.2005: "make sure your features are at least string complete"
203
* Preparation for fixing Bug #55078 - scheduled for KDE3.4.1 .
204
* This text will be plugged into the dock-icon popup menu.
206
QString selectChannel = i18n("Select Channel"); // This text will be used in KDE3.4.1 !!!
208
m_dockWidget->show();
213
KMixWindow::saveSettings()
132
void KMixWindow::initActions()
135
(void)new KAction( i18n("&New mixer tab"), "filenew", 0, this,
136
SLOT(newMixer()), actionCollection(), "file_new_tab" );
137
(void)new KAction( i18n("&Close mixer tab"), "fileclose", 0, this,
138
SLOT(closeMixer()), actionCollection(), "file_close_tab" );
139
(void)new KAction( i18n("&Restore default volumes"), 0, this, SLOT(loadVolumes()),
140
actionCollection(), "file_load_volume" );
141
(void)new KAction( i18n("&Save current volumes as default"), 0, this, SLOT(saveVolumes()),
142
actionCollection(), "file_save_volume" );
143
KStdAction::quit( this, SLOT(quit()), actionCollection());
146
KAction *a = KStdAction::showMenubar( this, SLOT(toggleMenuBar()), actionCollection());
147
a->setAccel( CTRL+Key_M );
148
a->plugAccel( new KAccel(this) ); // to make action working without visible menubar
149
KStdAction::preferences( this, SLOT(showSettings()), actionCollection());
151
createGUI( "kmixui.rc" );
155
void KMixWindow::initMixer()
157
QTimer *timer = new QTimer( this );
160
// get maximum values
161
KConfig *config= new KConfig("kcmkmixrc", false);
162
config->setGroup("Misc");
163
int maxCards = config->readNumEntry( "maxCards", 2 );
164
int maxDevices = config->readNumEntry( "maxDevices", 2 );
168
QMap<QString,int> mixerNums;
169
int drvNum = Mixer::getDriverNum();
170
for( int drv=0; drv<drvNum && m_mixers.count()==0; drv++ )
171
for( int dev=0; dev<maxDevices; dev++ )
172
for( int card=0; card<maxCards; card++ ){
174
Mixer *mixer = Mixer::getMixer( drv, dev, card );
175
int mixerError = mixer->grab();
179
connect( timer, SIGNAL(timeout()), mixer, SLOT(readSetFromHW()));
180
m_mixers.append( mixer );
182
// count mixer nums for every mixer name to identify mixers with equal names
183
mixerNums[mixer->mixerName()]++;
184
mixer->setMixerNum( mixerNums[mixer->mixerName()] );
191
void KMixWindow::initPrefDlg()
193
m_prefDlg = new KMixPrefDlg;
194
connect( m_prefDlg, SIGNAL(signalApplied(KMixPrefDlg *)),
195
this, SLOT(applyPrefs(KMixPrefDlg *)) );
199
void KMixWindow::initWidgets()
201
m_tab = new QTabWidget( this );
202
setCentralWidget( m_tab );
206
void KMixWindow::updateDocking()
208
// delete old dock widget
214
if (m_showDockWidget) {
216
// create dock widget
217
m_dockWidget = new KMixDockWidget( m_mixers.first(), this );
218
m_dockWidget->setPixmap( BarIcon("kmixdocked") );
221
QPopupMenu *menu = m_dockWidget->contextMenu();
223
KAction *a = actionCollection()->action("options_configure");
224
if (a) a->plug( menu );
226
menu->insertSeparator();
228
a = actionCollection()->action("help_about_app");
229
if (a) a->plug( menu );
231
a = actionCollection()->action("help");
232
if (a) a->plug( menu );
234
m_dockWidget->show();
239
void KMixWindow::saveConfig()
241
KConfig *config = kapp->config();
220
KMixWindow::saveConfig()
222
KConfig *config = kapp->config();
225
// make sure we don't start without any UI
226
// can happen e.g. when not docked and kmix closed via 'X' button
227
bool startVisible = m_isVisible;
228
if ( !m_showDockWidget )
244
231
config->writeEntry( "Size", size() );
245
232
config->writeEntry( "Position", pos() );
246
config->writeEntry( "Visible", isVisible() );
233
// Cannot use isVisible() here, as in the "aboutToQuit()" case this widget is already hidden.
234
// (Please note that the problem was only there when quitting via Systray - esken).
235
config->writeEntry( "Visible", startVisible );
247
236
config->writeEntry( "Menubar", m_showMenubar );
248
237
config->writeEntry( "AllowDocking", m_showDockWidget );
249
238
config->writeEntry( "TrayVolumeControl", m_volumeWidget );
250
// commented out for usability. nolden
251
// config->writeEntry( "HideOnClose", m_hideOnClose );
252
239
config->writeEntry( "Tickmarks", m_showTicks );
253
240
config->writeEntry( "Labels", m_showLabels );
241
config->writeEntry( "startkdeRestore", m_onLogin );
242
if ( m_toplevelOrientation == Qt::Vertical )
243
config->writeEntry( "Orientation","Vertical" );
245
config->writeEntry( "Orientation","Horizontal" );
255
247
// save mixer widgets
257
for (KMixerWidget *mw=m_mixerWidgets.first(); mw!=0; mw=m_mixerWidgets.next())
248
for ( KMixerWidget *mw = m_mixerWidgets.first(); mw != 0; mw = m_mixerWidgets.next() )
260
grp.sprintf( "%i", mw->id() );
263
config->setGroup( grp );
264
config->writeEntry( "Mixer", mw->mixerNum() );
265
config->writeEntry( "MixerName", mw->mixerName() );
266
config->writeEntry( "Name", mw->name() );
268
mw->saveConfig( config, grp );
251
grp.sprintf( "%i", mw->id() );
252
mw->saveConfig( config, grp );
271
255
config->setGroup(0);
272
config->writeEntry( "Tabs", tabs );
276
void KMixWindow::loadConfig()
259
KMixWindow::loadConfig()
278
KConfig *config = kapp->config();
261
KConfig *config = kapp->config();
281
264
m_showDockWidget = config->readBoolEntry("AllowDocking", true);
282
265
m_volumeWidget = config->readBoolEntry("TrayVolumeControl", true);
283
//hide on close has to stay true for usability. KMixPrefDlg option commented out. nolden
266
//hide on close has to stay true for usability. KMixPrefDlg option commented out. nolden
284
267
m_hideOnClose = config->readBoolEntry("HideOnClose", true);
285
m_showTicks = config->readBoolEntry("Tickmarks", false);
286
m_showLabels = config->readBoolEntry("Labels", false);
268
m_showTicks = config->readBoolEntry("Tickmarks", true);
269
m_showLabels = config->readBoolEntry("Labels", true);
270
m_onLogin = config->readBoolEntry("startkdeRestore", true );
287
271
m_startVisible = config->readBoolEntry("Visible", true);
272
m_multiDriverMode = config->readBoolEntry("MultiDriver", false);
273
m_surroundView = config->readBoolEntry("Experimental-ViewSurround", false );
274
const QString& orientationString = config->readEntry("Orientation", "Horizontal");
275
if ( orientationString == "Vertical" )
276
m_toplevelOrientation = Qt::Vertical;
278
m_toplevelOrientation = Qt::Horizontal;
289
280
// show/hide menu bar
290
281
m_showMenubar = config->readBoolEntry("Menubar", true);
296
283
KToggleAction *a = static_cast<KToggleAction*>(actionCollection()->action("options_show_menubar"));
297
284
if (a) a->setChecked( m_showMenubar );
299
// load mixer widgets
300
QString tabsStr = config->readEntry( "Tabs" );
301
QStringList tabs = QStringList::split( ',', tabsStr );
302
m_mixerWidgets.clear();
303
for ( QStringList::Iterator tab=tabs.begin(); tab!=tabs.end(); ++tab )
306
config->setGroup(*tab);
309
int id = (*tab).toInt();
310
if ( id>=m_maxId ) m_maxId = id+1;
313
int mixerNum = config->readNumEntry( "Mixer", -1 );
314
QString mixerName = config->readEntry( "MixerName", QString::null );
315
QString name = config->readEntry( "Name", mixerName );
320
for ( mixer=m_mixers.first(); mixer!=0; mixer=m_mixers.next() ) {
321
if ( mixer->mixerName()==mixerName && mixer->mixerNum()==mixerNum ) break;
326
KMixerWidget *mw = new KMixerWidget( id, mixer, mixerName, mixerNum,
327
false, KPanelApplet::Up, this );
329
mw->loadConfig( config, *tab );
330
insertMixerWidget( mw );
333
286
// restore window size and position
334
287
if ( !kapp->isRestored() ) // done by the session manager otherwise
336
QSize defSize( minimumWidth(), height() );
337
QSize size = config->readSizeEntry("Size", &defSize );
338
if(!size.isEmpty()) resize(size);
340
QPoint defPos = pos();
341
QPoint pos = config->readPointEntry("Position", &defPos);
347
void KMixWindow::insertMixerWidget( KMixerWidget *mw )
349
m_mixerWidgets.append( mw );
352
m_tab->addTab( mw, mw->name() );
353
mw->setTicks( m_showTicks );
354
mw->setLabels( m_showLabels );
356
connect( mw, SIGNAL(updateLayout()), this, SLOT(updateLayout()) );
358
KAction *a = actionCollection()->action( "file_close_tab" );
359
if ( a ) a->setEnabled( m_visibleTabs>1 );
365
void KMixWindow::removeMixerWidget( KMixerWidget *mw )
368
m_tab->removePage( mw );
369
m_mixerWidgets.remove( mw );
371
KAction *a = actionCollection()->action( "file_close_tab" );
372
if ( a ) a->setEnabled( m_visibleTabs>1 );
378
void KMixWindow::updateLayout()
380
m_tab->setMinimumSize( m_tab->minimumSizeHint() );
383
void KMixWindow::closeEvent ( QCloseEvent * e )
385
if ( /*m_hideOnClose &&*/ m_showDockWidget )
289
QSize defSize( minimumWidth(), height() );
290
QSize size = config->readSizeEntry("Size", &defSize );
291
if(!size.isEmpty()) resize(size);
293
QPoint defPos = pos();
294
QPoint pos = config->readPointEntry("Position", &defPos);
301
KMixWindow::initMixerWidgets()
303
m_mixerWidgets.clear();
308
// Attention!! If m_mixers is empty, we behave stupid. We don't show nothing and there
309
// is not even a context menu.
310
for ( mixer=m_mixers.first(),id=0; mixer!=0; mixer=m_mixers.next(),id++ )
312
//kdDebug(67100) << "Mixer number: " << id << " Name: " << mixer->mixerName() << endl ;
315
ViewBase::ViewFlags vflags = ViewBase::HasMenuBar;
316
if ( m_showMenubar ) {
317
vflags |= ViewBase::MenuBarVisible;
319
if ( m_surroundView ) {
320
vflags |= ViewBase::Experimental_SurroundView;
322
if ( m_toplevelOrientation == Qt::Vertical ) {
323
vflags |= ViewBase::Vertical;
326
vflags |= ViewBase::Horizontal;
330
KMixerWidget *mw = new KMixerWidget( id, mixer, mixer->mixerName(), mixer->mixerNum(),
331
MixDevice::ALL, this, "KMixerWidget", vflags );
333
//mw->setName( mixer->mixerName() );
335
m_mixerWidgets.append( mw );
338
m_cMixer->insertItem( mixer->mixerName() );
341
//kdDebug(67100) << "Inserted mixer " << id << ":" << mw->name() << endl;
342
m_wsMixers->addWidget( mw, id );
345
grp.sprintf( "%i", mw->id() );
346
mw->loadConfig( kapp->config(), grp );
348
mw->setTicks( m_showTicks );
349
mw->setLabels( m_showLabels );
350
// !! I am still not sure whether this works 100% reliably - chris
356
// don't show the Current Mixer bit unless we have multiple mixers
357
mixerNameLayout->hide();
362
KMixWindow::queryClose ( )
364
if ( m_showDockWidget && !kapp->sessionSaving() )
388
kapp->ref(); // prevent KMainWindow from closing the app
391
kapp->quit(); // force the application to quit
393
KMainWindow::closeEvent( e );
397
void KMixWindow::quit()
403
void KMixWindow::showSettings()
381
KMixWindow::showSettings()
405
383
if (!m_prefDlg->isVisible())
407
385
m_prefDlg->m_dockingChk->setChecked( m_showDockWidget );
408
386
m_prefDlg->m_volumeChk->setChecked(m_volumeWidget);
409
// m_prefDlg->m_hideOnCloseChk->setChecked( m_hideOnClose );
410
387
m_prefDlg->m_showTicks->setChecked( m_showTicks );
411
388
m_prefDlg->m_showLabels->setChecked( m_showLabels );
389
m_prefDlg->m_onLogin->setChecked( m_onLogin );
390
m_prefDlg->_rbVertical ->setChecked( m_toplevelOrientation == Qt::Vertical );
391
m_prefDlg->_rbHorizontal->setChecked( m_toplevelOrientation == Qt::Horizontal );
413
393
m_prefDlg->show();
418
void KMixWindow::showHelp()
399
KMixWindow::showHelp()
420
actionCollection()->action( "help_contents" )->activate();
401
actionCollection()->action( "help_contents" )->activate();
424
void KMixWindow::showAbout()
406
KMixWindow::showAbout()
426
408
actionCollection()->action( "help_about_app" )->activate();
430
void KMixWindow::closeMixer()
432
if (m_mixerWidgets.count()<=1) return;
433
removeMixerWidget( (KMixerWidget *)m_tab->currentPage() );
437
void KMixWindow::newMixer()
442
for (Mixer *mixer=m_mixers.first(); mixer!=0; mixer=m_mixers.next())
445
s.sprintf("%i. %s", n, mixer->mixerName().ascii());
451
QString res = QInputDialog::getItem( i18n("Mixers"),
452
i18n( "Available mixers" ), lst,
453
1, TRUE, &ok, this );
457
Mixer *mixer = m_mixers.at( lst.findIndex( res ) );
459
KMessageBox::sorry( this, i18n("Invalid mixer entered.") );
463
// ask for description
464
QString name = QInputDialog::getText( i18n("Description"), i18n( "Description" ),
465
mixer->mixerName(), &ok, this );
468
// create mixer widget
469
KMixerWidget *mw = new KMixerWidget( m_maxId, mixer, mixer->mixerName(), mixer->mixerNum(),
470
false, KPanelApplet::Up, this );
473
insertMixerWidget( mw );
479
void KMixWindow::loadVolumes()
481
KConfig *cfg = new KConfig( "kmixctrlrc", true );
482
for (Mixer *mixer=m_mixers.first(); mixer!=0; mixer=m_mixers.next())
483
mixer->volumeLoad( cfg );
488
void KMixWindow::saveVolumes()
490
KConfig *cfg = new KConfig( "kmixctrlrc", false );
491
for (Mixer *mixer=m_mixers.first(); mixer!=0; mixer=m_mixers.next())
492
mixer->volumeSave( cfg );
497
void KMixWindow::applyPrefs( KMixPrefDlg *prefDlg )
412
* Loads the volumes of all mixers from kmixctrlrc.
414
* Restores the default voumes as stored via saveVolumes() or the
415
* execution of "kmixctrl --save"
417
/* Currently this is not in use
419
KMixWindow::loadVolumes()
421
KConfig *cfg = new KConfig( "kmixctrlrc", true );
422
for (Mixer *mixer=m_mixers.first(); mixer!=0; mixer=m_mixers.next())
424
mixer->volumeLoad( cfg );
431
* Stores the volumes of all mixers Can be restored via loadVolumes() or
432
* the kmixctrl application.
435
KMixWindow::saveVolumes()
437
KConfig *cfg = new KConfig( "kmixctrlrc", false );
438
for (Mixer *mixer=m_mixers.first(); mixer!=0; mixer=m_mixers.next()) {
439
//kdDebug(67100) << "KMixWindow::saveConfig()" << endl;
440
mixer->volumeSave( cfg );
447
KMixWindow::applyPrefs( KMixPrefDlg *prefDlg )
499
449
m_showDockWidget = prefDlg->m_dockingChk->isChecked();
500
450
m_volumeWidget = prefDlg->m_volumeChk->isChecked();
501
// m_hideOnClose = prefDlg->m_hideOnCloseChk->isChecked();
502
451
m_showTicks = prefDlg->m_showTicks->isChecked();
503
452
m_showLabels = prefDlg->m_showLabels->isChecked();
453
m_onLogin = prefDlg->m_onLogin->isChecked();
454
if ( prefDlg->_rbVertical->isChecked() ) {
455
kdDebug(67100) << "KMix should change to Vertical layout\n";
456
m_toplevelOrientation = Qt::Vertical;
458
else if ( prefDlg->_rbHorizontal->isChecked() ) {
459
kdDebug(67100) << "KMix should change to Horizontal layout\n";
460
m_toplevelOrientation = Qt::Horizontal;
464
this->setUpdatesEnabled(false);
505
467
for (KMixerWidget *mw=m_mixerWidgets.first(); mw!=0; mw=m_mixerWidgets.next())
507
469
mw->setTicks( m_showTicks );
508
470
mw->setLabels( m_showLabels );
471
mw->mixer()->readSetFromHWforceUpdate(); // needed, as updateDocking() has reconstructed the DockWidget
474
this->setUpdatesEnabled(false);
513
476
// avoid invisible and unaccessible main window
514
477
if( !m_showDockWidget && !isVisible() )
482
this->repaint(); // make KMix look fast (saveConfig() often uses several seconds)
483
kapp->processEvents();
521
void KMixWindow::toggleMenuBar()
489
KMixWindow::toggleMenuBar()
523
m_showMenubar = !m_showMenubar;
491
m_showMenubar = !m_showMenubar;
531
void KMixWindow::toggleVisibility()
533
if ( isVisible() ) hide(); else show();
503
KMixWindow::showEvent( QShowEvent * )
505
if ( m_visibilityUpdateAllowed )
506
m_isVisible = isVisible();
507
// !! could possibly start polling now (idea: use someting like ref() and unref() on Mixer instance
511
KMixWindow::hideEvent( QHideEvent * )
513
if ( m_visibilityUpdateAllowed )
515
m_isVisible = isVisible();
517
// !! could possibly stop polling now (idea: use someting like ref() and unref() on Mixer instance
518
// Update: This is a stupid idea, because now the views are responsible for updating. So it will be done in the Views.
519
// But the dock icon is currently no View, so that must be done first.
524
KMixWindow::stopVisibilityUpdates() {
525
m_visibilityUpdateAllowed = false;
529
KMixWindow::slotHWInfo() {
530
KMessageBox::information( 0, m_hwInfoString, i18n("Mixer Hardware Information") );
534
KMixWindow::showSelectedMixer( int mixer )
536
m_wsMixers->raiseWidget( mixer );
536
539
#include "kmix.moc"