annotate data/fileio/AudioFileReader.cpp @ 288:7b96b3bd4bae

* Fix #1757772 tempo, dynamic related plug-ins bug -- make auto-align only auto-align if there is a unit involved * Fix #1755366 text layer bug in retrieved session * Fix input model selection in plugin parameter dialog (was being ignored) * Use lighter background than the standard widget one for panes (assuming the widget background is light but not white) -- similarly darker if dark * Fix colour reference counting in loaded session in SingleColourLayer * Reset overview pane colour when switching dark background on or off
author Chris Cannam
date Tue, 14 Aug 2007 13:58:53 +0000
parents 20028c634494
children 92e8dbde73cd
rev   line source
Chris@175 1 /* -*- c-basic-offset: 4 indent-tabs-mode: nil -*- vi:set ts=8 sts=4 sw=4: */
Chris@175 2
Chris@175 3 /*
Chris@175 4 Sonic Visualiser
Chris@175 5 An audio file viewer and annotation editor.
Chris@175 6 Centre for Digital Music, Queen Mary, University of London.
Chris@175 7 This file copyright 2006 Chris Cannam.
Chris@175 8
Chris@175 9 This program is free software; you can redistribute it and/or
Chris@175 10 modify it under the terms of the GNU General Public License as
Chris@175 11 published by the Free Software Foundation; either version 2 of the
Chris@175 12 License, or (at your option) any later version. See the file
Chris@175 13 COPYING included with this distribution for more information.
Chris@175 14 */
Chris@175 15
Chris@175 16 #include "AudioFileReader.h"
Chris@175 17
Chris@285 18 void
Chris@285 19 AudioFileReader::setError(std::string text, std::string arg)
Chris@285 20 {
Chris@285 21 if (arg == "") m_error = text;
Chris@285 22 else m_error = text + ": " + arg;
Chris@285 23 }
Chris@285 24
Chris@285 25 void
Chris@285 26 AudioFileReader::setError(std::string text, int arg)
Chris@285 27 {
Chris@285 28 char *buf = new char(text.length() + 100);
Chris@285 29 sprintf(buf, "%s: code %d", text.c_str(), arg);
Chris@285 30 m_error = buf;
Chris@285 31 delete[] buf;
Chris@285 32 }
Chris@285 33