forked from mia/Aegisub
Fix some mostly unimportant uses of uninitialized memory
Originally committed to SVN as r6304.
This commit is contained in:
parent
2109d677a7
commit
9ac2f93bf0
4 changed files with 9 additions and 5 deletions
|
@ -147,8 +147,8 @@ void AssFile::Load(const wxString &_filename,wxString charset,bool addToRecent)
|
|||
UndoStack.clear();
|
||||
RedoStack.clear();
|
||||
undoDescription.clear();
|
||||
autosavedCommitId = savedCommitId = commitId + 1;
|
||||
Commit("", COMMIT_NEW);
|
||||
savedCommitId = commitId;
|
||||
|
||||
// Add to recent
|
||||
if (addToRecent) AddToRecent(filename);
|
||||
|
@ -161,7 +161,7 @@ void AssFile::Save(wxString filename, bool setfilename, bool addToRecent, wxStri
|
|||
throw "Unknown file type.";
|
||||
|
||||
if (setfilename) {
|
||||
savedCommitId = commitId;
|
||||
autosavedCommitId = savedCommitId = commitId;
|
||||
this->filename = filename;
|
||||
StandardPaths::SetPathValue("?script", wxFileName(filename).GetPath());
|
||||
}
|
||||
|
@ -423,8 +423,8 @@ void AssFile::LoadDefault(bool defline) {
|
|||
if (defline)
|
||||
AddLine(AssDialogue().GetEntryData(), &version, &attach);
|
||||
|
||||
autosavedCommitId = savedCommitId = commitId + 1;
|
||||
Commit("", COMMIT_NEW);
|
||||
savedCommitId = commitId;
|
||||
loaded = true;
|
||||
StandardPaths::SetPathValue("?script", "");
|
||||
FileOpen("");
|
||||
|
|
|
@ -79,7 +79,10 @@ size_t AudioRendererBitmapCacheBitmapFactory::GetBlockSize() const
|
|||
|
||||
|
||||
AudioRenderer::AudioRenderer()
|
||||
: cache_bitmap_width(32) // arbitrary value for now
|
||||
: pixel_samples(0)
|
||||
, pixel_height(0)
|
||||
, amplitude_scale(0)
|
||||
, cache_bitmap_width(32) // arbitrary value for now
|
||||
, cache_bitmap_maxsize(0)
|
||||
, cache_renderer_maxsize(0)
|
||||
, renderer(0)
|
||||
|
|
|
@ -279,7 +279,7 @@ protected:
|
|||
|
||||
public:
|
||||
/// @brief Constructor
|
||||
AudioRendererBitmapProvider() : provider(0), pixel_samples(0) { };
|
||||
AudioRendererBitmapProvider() : provider(0), pixel_samples(0), amplitude_scale(0) { };
|
||||
|
||||
/// @brief Destructor
|
||||
virtual ~AudioRendererBitmapProvider() { }
|
||||
|
|
|
@ -911,6 +911,7 @@ void BaseGrid::SetColumnWidths() {
|
|||
colWidth[6] = effectLen;
|
||||
for (int i = 0; i < 3; i++)
|
||||
colWidth[i + 7] = showMargin[i] ? marginLen : 0;
|
||||
colWidth[10] = 1;
|
||||
|
||||
// Hide columns
|
||||
for (int i = 0; i < columns; i++) {
|
||||
|
|
Loading…
Reference in a new issue