Font attachments now have the "_0" part.

Originally committed to SVN as r474.
This commit is contained in:
Rodrigo Braz Monteiro 2006-07-08 01:56:17 +00:00
parent bd26c5d411
commit 85035b4dca
1 changed files with 12 additions and 1 deletions

View File

@ -37,12 +37,23 @@
////////////
// Includes
#include <wx/wfstream.h>
#include <wx/filename.h>
#include "ass_attachment.h"
///////////////
// Constructor
AssAttachment::AssAttachment(wxString name) {
AssAttachment::AssAttachment(wxString _name) {
// Parse name
wxFileName fname(_name);
wxString ext = fname.GetExt().Lower();
wxString name;
if (ext == _T("ttf")) {
name = fname.GetName() + _T("_0.") + ext;
}
else name = _name;
// Set data
filename = name;
data = boost::shared_ptr<AttachData> (new AttachData);
}