/[svn]/qsampler/trunk/src/qsamplerInstrumentForm.cpp
ViewVC logotype

Diff of /qsampler/trunk/src/qsamplerInstrumentForm.cpp

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

revision 1509 by capela, Thu Nov 22 11:10:44 2007 UTC revision 1526 by capela, Mon Nov 26 10:58:23 2007 UTC
# Line 20  Line 20 
20    
21  *****************************************************************************/  *****************************************************************************/
22    
23    #include "qsamplerAbout.h"
24  #include "qsamplerInstrumentForm.h"  #include "qsamplerInstrumentForm.h"
25    
26  #include "qsamplerAbout.h"  #include "qsamplerOptions.h"
27    #include "qsamplerChannel.h"
28  #include "qsamplerMainForm.h"  #include "qsamplerMainForm.h"
29    
30  #include <QFileDialog>  #include <QFileDialog>
# Line 31  Line 33 
33  // Needed for lroundf()  // Needed for lroundf()
34  #include <math.h>  #include <math.h>
35    
   
 namespace QSampler {  
   
36  #ifndef CONFIG_ROUND  #ifndef CONFIG_ROUND
37  static inline long lroundf ( float x )  static inline long lroundf ( float x )
38  {  {
# Line 44  static inline long lroundf ( float x ) Line 43  static inline long lroundf ( float x )
43  }  }
44  #endif  #endif
45    
46    
47    namespace QSampler {
48    
49  InstrumentForm::InstrumentForm ( QWidget* pParent )  InstrumentForm::InstrumentForm ( QWidget* pParent )
50          : QDialog(pParent)          : QDialog(pParent)
51  {  {
# Line 163  void InstrumentForm::setup ( qsamplerIns Line 165  void InstrumentForm::setup ( qsamplerIns
165                  iMap = 0;                  iMap = 0;
166          const QString& sMapName = qsamplerInstrument::getMapName(iMap);          const QString& sMapName = qsamplerInstrument::getMapName(iMap);
167          if (!sMapName.isEmpty()) {          if (!sMapName.isEmpty()) {
168                  m_ui.MapComboBox->setItemText(                  m_ui.MapComboBox->setCurrentIndex(
169                          m_ui.MapComboBox->currentIndex(),                          m_ui.MapComboBox->findText(sMapName,
170                          sMapName);                                  Qt::MatchExactly | Qt::MatchCaseSensitive));
171          }          }
172    
173          // It might be no maps around...          // It might be no maps around...
174          bool bMapEnabled = (m_ui.MapComboBox->count() > 0);          bool bMapEnabled = (m_ui.MapComboBox->count() > 0);
175          m_ui.MapTextLabel->setEnabled(bMapEnabled);          m_ui.MapTextLabel->setEnabled(bMapEnabled);

Legend:
Removed from v.1509  
changed lines
  Added in v.1526

  ViewVC Help
Powered by ViewVC