[SCM] Audacity debian packaging branch, master, updated. debian/1.3.11-2-5-g8d35a1e
bdrung-guest at users.alioth.debian.org
bdrung-guest at users.alioth.debian.org
Thu Apr 1 01:16:46 UTC 2010
The following commit has been merged in the master branch:
commit 8d35a1ea9aca20c63781e08a55ccea3d2bc740c6
Author: Benjamin Drung <bdrung at gmail.com>
Date: Thu Apr 1 03:11:49 2010 +0200
Really remove all patches.
diff --git a/src/AudacityApp.cpp b/src/AudacityApp.cpp
index de36ecc..21be5ac 100644
--- a/src/AudacityApp.cpp
+++ b/src/AudacityApp.cpp
@@ -70,7 +70,6 @@ It handles initialization and termination by subclassing wxApp.
#include "GStreamerLoader.h"
#include "Internat.h"
#include "LangChoice.h"
-#include "Languages.h"
#include "Prefs.h"
#include "Project.h"
#include "Screenshot.h"
@@ -1025,8 +1024,9 @@ bool AudacityApp::OnInit()
wxString lang = gPrefs->Read(wxT("/Locale/Language"), wxT(""));
+ // Pop up a dialog the first time the program is run
if (lang == wxT(""))
- lang = GetSystemLanguageCode();
+ lang = ChooseLanguage(NULL);
#ifdef NOT_RQD
//TIDY-ME: (CleanSpeech) Language prompt??
@@ -1038,6 +1038,7 @@ bool AudacityApp::OnInit()
//lda if (lang == "")
//lda lang = ChooseLanguage(NULL);
#endif
+ gPrefs->Write(wxT("/Locale/Language"), lang);
mLocale = NULL;
InitLang( lang );
diff --git a/src/Languages.cpp b/src/Languages.cpp
index c625243..061beb6 100644
--- a/src/Languages.cpp
+++ b/src/Languages.cpp
@@ -223,10 +223,6 @@ void GetLanguages(wxArrayString &langCodes, wxArrayString &langNames)
tempNames.Sort();
- // Add system language
- langNames.Add(wxT("System"));
- langCodes.Add(wxT(""));
-
for(j=0; j<tempNames.GetCount(); j++) {
langNames.Add(tempNames[j]);
langCodes.Add(reverseHash[tempNames[j]]);
diff --git a/src/export/ExportMultiple.cpp b/src/export/ExportMultiple.cpp
index 377e2db..ed3c159 100644
--- a/src/export/ExportMultiple.cpp
+++ b/src/export/ExportMultiple.cpp
@@ -65,7 +65,6 @@ enum {
TrackID,
ByNameID,
ByNumberID,
- ByNameAndNumberID,
PrefixID,
OverwriteID
};
@@ -308,21 +307,13 @@ void ExportMultiple::PopulateOrExchange(ShuttleGui& S)
{
// Row 1
S.SetBorder(1);
- mByNumberAndName = S.Id(ByNameAndNumberID)
- .AddRadioButton(wxT(""));
- mByNumberAndName->SetName(_("Consecutively numbered Label/Track Name"));
- S.SetBorder(3);
- mByNumberAndNameLabel = S.AddVariableText(_("Consecutively numbered Label/Track Name"), false);
-
- // Row 2
- S.SetBorder(1);
mByName = S.Id(ByNameID)
- .AddRadioButtonToGroup(wxT(""));
+ .AddRadioButton(wxT(""));
mByName->SetName(_("Using Label/Track Name"));
S.SetBorder(3);
mByNameLabel = S.AddVariableText(_("Using Label/Track Name"), false);
- // Row 3
+ // Row 2
S.SetBorder(1);
mByNumber = S.Id(ByNumberID)
.AddRadioButtonToGroup(wxT(""));
@@ -330,7 +321,7 @@ void ExportMultiple::PopulateOrExchange(ShuttleGui& S)
S.SetBorder(3);
mByNumberLabel = S.AddVariableText(_("Numbering consecutively"), false);
- // Row 4
+ // Row 3
S.AddVariableText(wxT(""), false);
S.StartHorizontalLay(wxEXPAND, false);
{
@@ -374,7 +365,7 @@ void ExportMultiple::EnableControls()
mFirst->Enable(mLabel->GetValue());
enable = mLabel->GetValue() &&
- (mByName->GetValue() || mByNumberAndName->GetValue()) &&
+ mByName->GetValue() &&
mFirst->GetValue();
mFirstFileLabel->Enable(enable);
mFirstFileName->Enable(enable);
@@ -527,14 +518,12 @@ void ExportMultiple::OnExport(wxCommandEvent& event)
mExported.Empty();
if (mLabel->GetValue()) {
- ok = ExportMultipleByLabel(mByName->GetValue() || mByNumberAndName->GetValue(),
- mPrefix->GetValue(),
- mByNumberAndName->GetValue());
+ ok = ExportMultipleByLabel(mByName->GetValue(),
+ mPrefix->GetValue());
}
else {
- ok = ExportMultipleByTrack(mByName->GetValue() || mByNumberAndName->GetValue(),
- mPrefix->GetValue(),
- mByNumberAndName->GetValue());
+ ok = ExportMultipleByTrack(mByName->GetValue(),
+ mPrefix->GetValue());
}
// Give 'em the result
@@ -613,7 +602,7 @@ bool ExportMultiple::DirOk()
return fn.Mkdir(0777, wxPATH_MKDIR_FULL);
}
-int ExportMultiple::ExportMultipleByLabel(bool byName, wxString prefix, bool addNumber)
+int ExportMultiple::ExportMultipleByLabel(bool byName, wxString prefix)
{
wxASSERT(mProject);
bool tagsPrompt = mProject->GetShowId3Dialog();
@@ -680,14 +669,9 @@ int ExportMultiple::ExportMultipleByLabel(bool byName, wxString prefix, bool add
name.Printf(wxT("%s-%02d"), prefix.c_str(), l+1);
else
name.Printf(wxT("%s-%d"), prefix.c_str(), l+1);
- } else if (addNumber) {
- if (numFiles > 9)
- name.Prepend(wxString::Format(wxT("%02d "), l+1));
- else
- name.Prepend(wxString::Format(wxT("%d "), l+1));
}
- // store sanitised and user checked name in object
+ // store sanitised and user checjed name in object
setting.destfile.SetName(MakeFileName(name));
wxASSERT(setting.destfile.IsOk()); // scream if file name is broke
@@ -731,8 +715,7 @@ int ExportMultiple::ExportMultipleByLabel(bool byName, wxString prefix, bool add
}
int ExportMultiple::ExportMultipleByTrack(bool byName,
- wxString prefix,
- bool addNumber)
+ wxString prefix)
{
wxASSERT(mProject);
bool tagsPrompt = mProject->GetShowId3Dialog();
@@ -810,13 +793,6 @@ int ExportMultiple::ExportMultipleByTrack(bool byName,
title = tr->GetName();
if (byName) {
name = title;
- if (addNumber) {
- if (numTracks > 9) {
- name.Prepend(wxString::Format(wxT("%02d "), l+1));
- } else {
- name.Prepend(wxString::Format(wxT("%d "), l+1));
- }
- }
}
else {
if (numTracks > 9) {
diff --git a/src/export/ExportMultiple.h b/src/export/ExportMultiple.h
index e148936..42175c7 100644
--- a/src/export/ExportMultiple.h
+++ b/src/export/ExportMultiple.h
@@ -52,7 +52,7 @@ private:
* labels that define them (true), or just numbered (false).
* @param prefix The string used to prefix the file number if files are being
* numbered rather than named */
- int ExportMultipleByLabel(bool byName, wxString prefix, bool addNumber);
+ int ExportMultipleByLabel(bool byName, wxString prefix);
/** \brief Export each track in the project to a separate file
*
@@ -60,7 +60,7 @@ private:
* (true), or just numbered (false).
* @param prefix The string used to prefix the file number if files are being
* numbered rather than named */
- int ExportMultipleByTrack(bool byName, wxString prefix, bool addNumber);
+ int ExportMultipleByTrack(bool byName, wxString prefix);
/** Export one file of an export multiple set
*
@@ -155,9 +155,6 @@ private:
wxRadioButton *mByNumber; /**< button to choose numbering exported files */
wxStaticText *mByNumberLabel;
- wxRadioButton *mByNumberAndName;
- wxStaticText *mByNumberAndNameLabel;
-
wxStaticText *mPrefixLabel;
wxTextCtrl *mPrefix;
diff --git a/src/export/ExportPCM.cpp b/src/export/ExportPCM.cpp
index 2234daa..f898fc3 100644
--- a/src/export/ExportPCM.cpp
+++ b/src/export/ExportPCM.cpp
@@ -529,7 +529,6 @@ int ExportPCM::Export(AudacityProject *project,
formatStr.c_str()));
while(updateResult == eProgressSuccess) {
- sampleCount samplesWritten;
sampleCount numSamples = mixer->Process(maxBlockLen);
if (numSamples == 0)
@@ -539,20 +538,11 @@ int ExportPCM::Export(AudacityProject *project,
ODManager::LockLibSndFileMutex();
if (format == int16Sample)
- samplesWritten = sf_writef_short(sf, (short *)mixed, numSamples);
+ sf_writef_short(sf, (short *)mixed, numSamples);
else
- samplesWritten = sf_writef_float(sf, (float *)mixed, numSamples);
+ sf_writef_float(sf, (float *)mixed, numSamples);
ODManager::UnlockLibSndFileMutex();
- if (samplesWritten != numSamples) {
- char buffer2[1000];
- sf_error_str(sf, buffer2, 1000);
- /* Tried the format %s variant (like below) but got garbage, probably it depends on
- Audacity and/or libsndfile being compiled with unicode or not */
- wxMessageBox(_("Error while writing file (disk full?): ") + wxString::FromAscii(buffer2));
- break;
- }
-
updateResult = progress->Update(mixer->MixGetCurrentTime()-t0, t1-t0);
}
diff --git a/src/prefs/DevicePrefs.cpp b/src/prefs/DevicePrefs.cpp
index a80123e..b984a2e 100644
--- a/src/prefs/DevicePrefs.cpp
+++ b/src/prefs/DevicePrefs.cpp
@@ -334,10 +334,6 @@ wxString DevicePrefs::GetDefaultPlayDevice(int index)
wxLogDebug(wxT("GetDefaultPlayDevice(): HostAPI index %d, name %s"), index, wxString(apiinfo->name, wxConvLocal).c_str());
wxLogDebug(wxT("GetDefaultPlayDevice() default output %d"), apiinfo->defaultOutputDevice);
const PaDeviceInfo* devinfo = Pa_GetDeviceInfo(apiinfo->defaultOutputDevice);
- if (devinfo == NULL) {
- wxLogDebug(wxT("GetDefaultPlayDevice() no default output device"));
- return wxString("", wxConvLocal);
- }
wxString name(devinfo->name, wxConvLocal);
wxLogDebug(wxT("GetDefaultPlayDevice() default output device name %s"), name.c_str());
return name;
@@ -353,10 +349,6 @@ wxString DevicePrefs::GetDefaultRecordDevice(int index)
wxLogDebug(wxT("GetDefaultRecordDevice(): HostAPI index %d, name %s"), index, wxString(apiinfo->name, wxConvLocal).c_str());
wxLogDebug(wxT("GetDefaultRecordDevice() default input %d"), apiinfo->defaultInputDevice);
const PaDeviceInfo* devinfo = Pa_GetDeviceInfo(apiinfo->defaultInputDevice);
- if (devinfo == NULL) {
- wxLogDebug(wxT("GetDefaultRecordDevice() no default input device"));
- return wxString("", wxConvLocal);
- }
wxString name(devinfo->name, wxConvLocal);
wxLogDebug(wxT("GetDefaultRecordDevice() default input device name %s"), name.c_str());
return name;
diff --git a/src/prefs/EffectsPrefs.cpp b/src/prefs/EffectsPrefs.cpp
index 7728baf..ce63d66 100644
--- a/src/prefs/EffectsPrefs.cpp
+++ b/src/prefs/EffectsPrefs.cpp
@@ -126,8 +126,6 @@ bool EffectsPrefs::Apply()
// If language has changed, we want to change it now, not on the next reboot.
wxString lang = gPrefs->Read(wxT("/Locale/Language"), wxT(""));
- if (lang == wxT(""))
- lang = GetSystemLanguageCode();
wxGetApp().InitLang(lang);
return true;
diff --git a/src/prefs/GUIPrefs.cpp b/src/prefs/GUIPrefs.cpp
index a6539c1..5971088 100644
--- a/src/prefs/GUIPrefs.cpp
+++ b/src/prefs/GUIPrefs.cpp
@@ -113,7 +113,7 @@ void GUIPrefs::PopulateOrExchange(ShuttleGui & S)
S.TieChoice(_("&Language:"),
wxT("/Locale/Language"),
- wxT(""),
+ wxT("en"),
mLangNames,
mLangCodes);
S.SetSizeHints(mLangNames);
@@ -161,8 +161,6 @@ bool GUIPrefs::Apply()
// If language has changed, we want to change it now, not on the next reboot.
wxString lang = gPrefs->Read(wxT("/Locale/Language"), wxT(""));
- if (lang == wxT(""))
- lang = GetSystemLanguageCode();
wxGetApp().InitLang(lang);
return true;
--
Audacity debian packaging
More information about the pkg-multimedia-commits
mailing list