Update of /cvsroot/audacity/audacity-src/src/prefs
In directory sc8-pr-cvs11.sourceforge.net:/tmp/cvs-serv17874/prefs

Modified Files:
      Tag: Audacity_UmixIt
        GUIPrefs.cpp SpectrumPrefs.cpp 
Log Message:
Branding Panel updates, including merging some of the Thinklabs changes 
relevant to UmixIt requests.

Index: GUIPrefs.cpp
===================================================================
RCS file: /cvsroot/audacity/audacity-src/src/prefs/GUIPrefs.cpp,v
retrieving revision 1.19.2.4.2.1
retrieving revision 1.19.2.4.2.2
diff -u -d -r1.19.2.4.2.1 -r1.19.2.4.2.2
--- GUIPrefs.cpp        4 Apr 2007 19:30:30 -0000       1.19.2.4.2.1
+++ GUIPrefs.cpp        18 Apr 2007 01:34:54 -0000      1.19.2.4.2.2
@@ -50,7 +50,7 @@
    #elif (AUDACITY_BRANDING == BRAND_THINKLABS)
       // no Mixer or Meter Toolbar by default for Thinklabs
       bDefaultMixerToolbar = false;
-      bDefaultMeterToolbar = false;
+      bDefaultMeterToolbar = true;
    #endif
    gPrefs->Read("/GUI/EnableEditToolBar", &editToolBar, bDefaultEditToolbar);
    gPrefs->Read("/GUI/EnableMixerToolBar", &mixerToolBar, 
bDefaultMixerToolbar);

Index: SpectrumPrefs.cpp
===================================================================
RCS file: /cvsroot/audacity/audacity-src/src/prefs/SpectrumPrefs.cpp,v
retrieving revision 1.5
retrieving revision 1.5.10.1
diff -u -d -r1.5 -r1.5.10.1
--- SpectrumPrefs.cpp   17 Apr 2002 05:56:39 -0000      1.5
+++ SpectrumPrefs.cpp   18 Apr 2007 01:34:54 -0000      1.5.10.1
@@ -20,6 +20,8 @@
 #include <wx/textctrl.h>
 
 #include "../Prefs.h"
+#include "../AudacityBranding.h"
+#include "../Project.h"
 #include "SpectrumPrefs.h"
 
 int numFFTSizes = 7;
@@ -47,15 +49,24 @@
 SpectrumPrefs::SpectrumPrefs(wxWindow * parent):
 PrefsPanel(parent)
 {
-   int fftSize = gPrefs->Read("/Spectrum/FFTSize", 256L);
+   int defaultFFTSize = 256L;
+   int defaultMaxFreq = 8000L;
+   #if (AUDACITY_BRANDING == BRAND_THINKLABS)
+      // Thinklabs has lower default for Spectrum MaxFreq & bigger FFTSize 
than standard Audacity
+      defaultFFTSize = 4096L;
+      defaultMaxFreq = 1000L;
+   #endif
+
+   int fftSize = gPrefs->Read("/Spectrum/FFTSize", defaultFFTSize);
+   
    bool isGrayscale = false;
    gPrefs->Read("/Spectrum/Grayscale", &isGrayscale, false);
 
-   int i;
-   int maxFreq = gPrefs->Read("/Spectrum/MaxFreq", 8000L);
+   int maxFreq = gPrefs->Read("/Spectrum/MaxFreq", defaultMaxFreq);
    wxString maxFreqStr;
    maxFreqStr.Printf("%d", maxFreq);
 
+   int i;
    int pos = 3;                 // Fall back to 256 if it doesn't match 
anything else
    for (i = 0; i < numFFTSizes; i++)
       if (fftSize == FFTSizes[i]) {
@@ -155,7 +166,12 @@
    }
    gPrefs->Write("/Spectrum/MaxFreq", maxFreq);
 
-   // TODO: Force all projects to repaint themselves
+   // TODO: Force all projects to repaint themselves 
+   //v? Or just the active project, voila?
+   // Update the TrackPanel correspondingly. 
+   // Calling RedrawProject is inefficient relative to sending a msg to 
TrackPanel 
+   // for a particular track and control, but not a real performance hit.
+   GetActiveProject()->RedrawProject();
 
    return true;
 


-------------------------------------------------------------------------
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
_______________________________________________
Audacity-cvs mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/audacity-cvs

Reply via email to