1 /***************************************************************************
2 nationality.cpp - description
5 copyright : (C) 2002 by Gael de Chalendar
6 email : Gael.de.Chalendar@free.fr
7 ***************************************************************************/
9 /***************************************************************************
11 * This program is free software; you can redistribute it and/or modify *
12 * it under the terms of the GNU General Public License as published by *
13 * the Free Software Foundation; either version 2 of the License, or *
14 * (at your option) any later version. *
16 * You should have received a copy of the GNU General Public License
17 * along with this program; if not, write to the Free Software
18 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
20 ***************************************************************************/
22 #include "nationality.h"
24 namespace KsirkSkinEditor
27 Nationality::Nationality(const QString
&myName
, const QString
&myFlag
,
28 const QString
& leaderName
) :
29 m_name(myName
), m_leaderName(leaderName
), m_flagFileName(myFlag
)
33 void Nationality::saveXml(QTextStream
& xmlStream
)
35 QString name
= m_name
;
36 name
= name
.replace("&","&");
37 name
= name
.replace("<","<");
38 name
= name
.replace(">",">");
39 xmlStream
<< "<nationality name=\"" << name
<< "\" flag=\"" << m_flagFileName
<< "\" />";