Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion plugins/HydrogenImport/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
INCLUDE(BuildPlugin)

BUILD_PLUGIN(hydrogenimport HydrogenImport.cpp HydrogenImport.h local_file_mgr.cpp LocalFileMng.h)
BUILD_PLUGIN(hydrogenimport HydrogenImport.cpp HydrogenImport.h LocalFileMng.cpp LocalFileMng.h)

3 changes: 2 additions & 1 deletion plugins/HydrogenImport/HydrogenImport.cpp
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
#include "HydrogenImport.h"

#include <QDomDocument>

#include "LocalFileMng.h"
#include "HydrogenImport.h"
#include "Song.h"
#include "Engine.h"
#include "Instrument.h"
Expand Down
Original file line number Diff line number Diff line change
@@ -1,12 +1,11 @@
#include <sys/stat.h>
#include "LocalFileMng.h"

#include <cctype>

#include <QDomDocument>
#include <QFile>
#include <QLocale>
#include <QTextCodec>

#include "LocalFileMng.h"

namespace lmms
{
Expand Down Expand Up @@ -197,10 +196,7 @@ QDomDocument LocalFileMng::openXmlDocument( const QString& filename )
return QDomDocument();

if( TinyXMLCompat ) {
QString enc = QTextCodec::codecForLocale()->name();
if( enc == QString("System") ) {
enc = "UTF-8";
}
const QString enc = "UTF-8"; // unknown encoding, so assume utf-8 and call it a day
QByteArray line;
QByteArray buf = QString("<?xml version='1.0' encoding='%1' ?>\n")
.arg( enc )
Expand Down
7 changes: 0 additions & 7 deletions plugins/HydrogenImport/LocalFileMng.h
Original file line number Diff line number Diff line change
Expand Up @@ -14,20 +14,13 @@ namespace lmms
class LocalFileMng
{
public:
LocalFileMng();
~LocalFileMng();
std::vector<QString> getallPatternList(){
return m_allPatternList;
}

static QString readXmlString( QDomNode , const QString& nodeName, const QString& defaultValue, bool bCanBeEmpty = false, bool bShouldExists = true , bool tinyXmlCompatMode = false);
static float readXmlFloat( QDomNode , const QString& nodeName, float defaultValue, bool bCanBeEmpty = false, bool bShouldExists = true , bool tinyXmlCompatMode = false);
static int readXmlInt( QDomNode , const QString& nodeName, int defaultValue, bool bCanBeEmpty = false, bool bShouldExists = true , bool tinyXmlCompatMode = false);
static bool readXmlBool( QDomNode , const QString& nodeName, bool defaultValue, bool bShouldExists = true , bool tinyXmlCompatMode = false );
static void convertFromTinyXMLString( QByteArray* str );
static bool checkTinyXMLCompatMode( const QString& filename );
static QDomDocument openXmlDocument( const QString& filename );
std::vector<QString> m_allPatternList;
};


Expand Down