Subversion Repositories tpanel

Rev

Rev 446 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 446 Rev 462
Line 43... Line 43...
43
using std::vector;
43
using std::vector;
44
using std::map;
44
using std::map;
45
using std::pair;
45
using std::pair;
46
using namespace Expat;
46
using namespace Expat;
47
 
47
 
48
TPalette::TPalette()
48
TPalette::TPalette(bool tp)
-
 
49
    : mIsTP5(tp)
49
{
50
{
50
    DECL_TRACER("TPalette::TPalette()");
51
    DECL_TRACER("TPalette::TPalette(bool tp)");
51
 
52
 
52
    mPath = TConfig::getProjectPath();
53
    mPath = TConfig::getProjectPath();
53
}
54
}
54
 
55
 
55
TPalette::TPalette(const std::string& file)
56
TPalette::TPalette(const std::string& file, bool tp)
-
 
57
    : mIsTP5(tp)
56
{
58
{
57
    DECL_TRACER("TPalette::TPalette(const std::string& file)");
59
    DECL_TRACER("TPalette::TPalette(const std::string& file, bool tp)");
58
 
60
 
59
    mPath = TConfig::getProjectPath();
61
    mPath = TConfig::getProjectPath();
60
    initialize(file);
62
    initialize(file);
61
}
63
}
62
 
64
 
Line 77... Line 79...
77
 
79
 
78
    if (isValidFile())
80
    if (isValidFile())
79
        path = getFileName();
81
        path = getFileName();
80
 
82
 
81
    TExpat xml(path);
83
    TExpat xml(path);
-
 
84
 
-
 
85
    if (!mIsTP5)
82
    xml.setEncoding(ENC_CP1250);
86
        xml.setEncoding(ENC_CP1250);
83
 
87
 
84
    if (!xml.parse(false))
88
    if (!xml.parse(false))
85
        return;
89
        return;
86
 
90
 
87
    int depth = 0;
91
    int depth = 0;