/[svn]/qsampler/trunk/src/qsamplerDeviceForm.ui.h
ViewVC logotype

Diff of /qsampler/trunk/src/qsamplerDeviceForm.ui.h

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 490 by capela, Fri Apr 1 00:34:58 2005 UTC revision 920 by capela, Sun Sep 24 12:47:51 2006 UTC
# Line 2  Line 2 
2  //  //
3  // ui.h extension file, included from the uic-generated form implementation.  // ui.h extension file, included from the uic-generated form implementation.
4  /****************************************************************************  /****************************************************************************
5     Copyright (C) 2005, rncbc aka Rui Nuno Capela. All rights reserved.     Copyright (C) 2004-2006, rncbc aka Rui Nuno Capela. All rights reserved.
6    
7     This program is free software; you can redistribute it and/or     This program is free software; you can redistribute it and/or
8     modify it under the terms of the GNU General Public License     modify it under the terms of the GNU General Public License
# Line 14  Line 14 
14     MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the     MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
15     GNU General Public License for more details.     GNU General Public License for more details.
16    
17     You should have received a copy of the GNU General Public License     You should have received a copy of the GNU General Public License along
18     along with this program; if not, write to the Free Software     with this program; if not, write to the Free Software Foundation, Inc.,
19     Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.     51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
20    
21  *****************************************************************************/  *****************************************************************************/
22    
23    #include "qsamplerAbout.h"
24    #include "qsamplerMainForm.h"
25    
26  #include <qmessagebox.h>  #include <qmessagebox.h>
27  #include <qfiledialog.h>  #include <qfiledialog.h>
28  #include <qfileinfo.h>  #include <qfileinfo.h>
# Line 27  Line 30 
30  #include <qptrlist.h>  #include <qptrlist.h>
31  #include <qpopupmenu.h>  #include <qpopupmenu.h>
32    
 #include "qsamplerMainForm.h"  
   
 #include "config.h"  
   
33    
34  // Kind of constructor.  // Kind of constructor.
35  void qsamplerDeviceForm::init (void)  void qsamplerDeviceForm::init (void)
# Line 240  void qsamplerDeviceForm::deleteDevice (v Line 239  void qsamplerDeviceForm::deleteDevice (v
239          // Prompt user if this is for real...          // Prompt user if this is for real...
240          qsamplerOptions *pOptions = m_pMainForm->options();          qsamplerOptions *pOptions = m_pMainForm->options();
241          if (pOptions && pOptions->bConfirmRemove) {          if (pOptions && pOptions->bConfirmRemove) {
242                  if (QMessageBox::warning(this, tr("Warning"),                  if (QMessageBox::warning(this,
243                            QSAMPLER_TITLE ": " + tr("Warning"),
244                          tr("Delete device:\n\n"                          tr("Delete device:\n\n"
245                          "%1\n\n"                          "%1\n\n"
246                          "Are you sure?")                          "Are you sure?")
# Line 360  void qsamplerDeviceForm::selectDevice (v Line 360  void qsamplerDeviceForm::selectDevice (v
360                  DeviceParamTable->setNumRows(0);                  DeviceParamTable->setNumRows(0);
361                  DevicePortComboBox->clear();                  DevicePortComboBox->clear();
362                  DevicePortParamTable->setNumRows(0);                  DevicePortParamTable->setNumRows(0);
363                    DevicePortTextLabel->setEnabled(false);
364                  DevicePortComboBox->setEnabled(false);                  DevicePortComboBox->setEnabled(false);
365                  DevicePortParamTable->setEnabled(false);                  DevicePortParamTable->setEnabled(false);
366                  stabilizeForm();                  stabilizeForm();
# Line 390  void qsamplerDeviceForm::selectDevice (v Line 391  void qsamplerDeviceForm::selectDevice (v
391          // Fill the device parameter table...          // Fill the device parameter table...
392          DeviceParamTable->refresh(device.params(), m_bNewDevice);          DeviceParamTable->refresh(device.params(), m_bNewDevice);
393          // And now the device port/channel parameter table...          // And now the device port/channel parameter table...
394            switch (device.deviceType()) {
395            case qsamplerDevice::Audio:
396                    DevicePortTextLabel->setText(tr("Ch&annel:"));
397                    break;
398            case qsamplerDevice::Midi:
399                    DevicePortTextLabel->setText(tr("P&ort:"));
400                    break;
401            case qsamplerDevice::None:
402                    break;
403            }
404          DevicePortComboBox->clear();          DevicePortComboBox->clear();
405          DevicePortParamTable->setNumRows(0);          DevicePortParamTable->setNumRows(0);
406          if (m_bNewDevice) {          if (m_bNewDevice) {
407                    DevicePortTextLabel->setEnabled(false);
408                  DevicePortComboBox->setEnabled(false);                  DevicePortComboBox->setEnabled(false);
409                  DevicePortParamTable->setEnabled(false);                  DevicePortParamTable->setEnabled(false);
410          } else {          } else {
# Line 415  void qsamplerDeviceForm::selectDevice (v Line 427  void qsamplerDeviceForm::selectDevice (v
427                                  + ' ' + pPort->portName());                                  + ' ' + pPort->portName());
428                  }                  }
429                  bool bEnabled = (ports.count() > 0);                  bool bEnabled = (ports.count() > 0);
430                    DevicePortTextLabel->setEnabled(bEnabled);
431                  DevicePortComboBox->setEnabled(bEnabled);                  DevicePortComboBox->setEnabled(bEnabled);
432                  DevicePortParamTable->setEnabled(bEnabled);                  DevicePortParamTable->setEnabled(bEnabled);
433          }          }

Legend:
Removed from v.490  
changed lines
  Added in v.920

  ViewVC Help
Powered by ViewVC