Ensure file info is always UTF-8 encoded
This commit is contained in:
parent
b3a79940b7
commit
18d2e5f155
|
@ -24,6 +24,7 @@
|
|||
#include <QFileDialog>
|
||||
#include <QFileSystemModel>
|
||||
#include <QTextStream>
|
||||
#include <QTextCodec>
|
||||
|
||||
#include <iomanip>
|
||||
|
||||
|
@ -467,6 +468,7 @@ void MainWindow::saveFileInformation()
|
|||
QFile file(path);
|
||||
if(file.open(QIODevice::WriteOnly | QIODevice::Truncate)) {
|
||||
QTextStream stream(&file);
|
||||
stream.setCodec(QTextCodec::codecForName("UTF-8"));
|
||||
stream << htmlData;
|
||||
file.close();
|
||||
if(file.error() != QFileDevice::NoError) {
|
||||
|
|
|
@ -1865,58 +1865,58 @@ another position would prevent rewriting the entire file</source>
|
|||
<translation type="unfinished"></translation>
|
||||
</message>
|
||||
<message>
|
||||
<location filename="../gui/mainwindow.cpp" line="284"/>
|
||||
<location filename="../gui/mainwindow.cpp" line="285"/>
|
||||
<source>No file opened.</source>
|
||||
<translation type="unfinished"></translation>
|
||||
</message>
|
||||
<message>
|
||||
<location filename="../gui/mainwindow.cpp" line="305"/>
|
||||
<location filename="../gui/mainwindow.cpp" line="306"/>
|
||||
<source>A tag editing utility supporting ID3, MP4 (iTunes style), Vorbis and Matroska tags.</source>
|
||||
<translation type="unfinished"></translation>
|
||||
</message>
|
||||
<message>
|
||||
<location filename="../gui/mainwindow.cpp" line="422"/>
|
||||
<location filename="../gui/mainwindow.cpp" line="423"/>
|
||||
<source>Unable to show the next file because it can't be found anymore.</source>
|
||||
<translation type="unfinished"></translation>
|
||||
</message>
|
||||
<message>
|
||||
<location filename="../gui/mainwindow.cpp" line="432"/>
|
||||
<location filename="../gui/mainwindow.cpp" line="433"/>
|
||||
<source>Open file - </source>
|
||||
<translation type="unfinished"></translation>
|
||||
</message>
|
||||
<message>
|
||||
<location filename="../gui/mainwindow.cpp" line="443"/>
|
||||
<location filename="../gui/mainwindow.cpp" line="444"/>
|
||||
<source>Save changes as - </source>
|
||||
<translation type="unfinished"></translation>
|
||||
</message>
|
||||
<message>
|
||||
<location filename="../gui/mainwindow.cpp" line="465"/>
|
||||
<location filename="../gui/mainwindow.cpp" line="466"/>
|
||||
<source>Save file information - </source>
|
||||
<translation type="unfinished"></translation>
|
||||
</message>
|
||||
<message>
|
||||
<location filename="../gui/mainwindow.cpp" line="473"/>
|
||||
<location filename="../gui/mainwindow.cpp" line="475"/>
|
||||
<source>Unable to write to file.
|
||||
%1</source>
|
||||
<translation type="unfinished"></translation>
|
||||
</message>
|
||||
<message>
|
||||
<location filename="../gui/mainwindow.cpp" line="476"/>
|
||||
<location filename="../gui/mainwindow.cpp" line="478"/>
|
||||
<source>Unable to open file.</source>
|
||||
<translation type="unfinished"></translation>
|
||||
</message>
|
||||
<message>
|
||||
<location filename="../gui/mainwindow.cpp" line="480"/>
|
||||
<location filename="../gui/mainwindow.cpp" line="482"/>
|
||||
<source>No file information available.</source>
|
||||
<translation type="unfinished"></translation>
|
||||
</message>
|
||||
<message>
|
||||
<location filename="../gui/mainwindow.cpp" line="483"/>
|
||||
<location filename="../gui/mainwindow.cpp" line="485"/>
|
||||
<source>No file is opened.</source>
|
||||
<translation type="unfinished"></translation>
|
||||
</message>
|
||||
<message>
|
||||
<location filename="../gui/mainwindow.cpp" line="486"/>
|
||||
<location filename="../gui/mainwindow.cpp" line="488"/>
|
||||
<source>Unable to save file information because the current process hasn't been finished yet.</source>
|
||||
<translation type="unfinished"></translation>
|
||||
</message>
|
||||
|
|
|
@ -1865,58 +1865,58 @@ another position would prevent rewriting the entire file</source>
|
|||
<translation type="unfinished"></translation>
|
||||
</message>
|
||||
<message>
|
||||
<location filename="../gui/mainwindow.cpp" line="284"/>
|
||||
<location filename="../gui/mainwindow.cpp" line="285"/>
|
||||
<source>No file opened.</source>
|
||||
<translation type="unfinished"></translation>
|
||||
</message>
|
||||
<message>
|
||||
<location filename="../gui/mainwindow.cpp" line="305"/>
|
||||
<location filename="../gui/mainwindow.cpp" line="306"/>
|
||||
<source>A tag editing utility supporting ID3, MP4 (iTunes style), Vorbis and Matroska tags.</source>
|
||||
<translation type="unfinished"></translation>
|
||||
</message>
|
||||
<message>
|
||||
<location filename="../gui/mainwindow.cpp" line="422"/>
|
||||
<location filename="../gui/mainwindow.cpp" line="423"/>
|
||||
<source>Unable to show the next file because it can't be found anymore.</source>
|
||||
<translation type="unfinished"></translation>
|
||||
</message>
|
||||
<message>
|
||||
<location filename="../gui/mainwindow.cpp" line="432"/>
|
||||
<location filename="../gui/mainwindow.cpp" line="433"/>
|
||||
<source>Open file - </source>
|
||||
<translation type="unfinished"></translation>
|
||||
</message>
|
||||
<message>
|
||||
<location filename="../gui/mainwindow.cpp" line="443"/>
|
||||
<location filename="../gui/mainwindow.cpp" line="444"/>
|
||||
<source>Save changes as - </source>
|
||||
<translation type="unfinished"></translation>
|
||||
</message>
|
||||
<message>
|
||||
<location filename="../gui/mainwindow.cpp" line="465"/>
|
||||
<location filename="../gui/mainwindow.cpp" line="466"/>
|
||||
<source>Save file information - </source>
|
||||
<translation type="unfinished"></translation>
|
||||
</message>
|
||||
<message>
|
||||
<location filename="../gui/mainwindow.cpp" line="473"/>
|
||||
<location filename="../gui/mainwindow.cpp" line="475"/>
|
||||
<source>Unable to write to file.
|
||||
%1</source>
|
||||
<translation type="unfinished"></translation>
|
||||
</message>
|
||||
<message>
|
||||
<location filename="../gui/mainwindow.cpp" line="476"/>
|
||||
<location filename="../gui/mainwindow.cpp" line="478"/>
|
||||
<source>Unable to open file.</source>
|
||||
<translation type="unfinished"></translation>
|
||||
</message>
|
||||
<message>
|
||||
<location filename="../gui/mainwindow.cpp" line="480"/>
|
||||
<location filename="../gui/mainwindow.cpp" line="482"/>
|
||||
<source>No file information available.</source>
|
||||
<translation type="unfinished"></translation>
|
||||
</message>
|
||||
<message>
|
||||
<location filename="../gui/mainwindow.cpp" line="483"/>
|
||||
<location filename="../gui/mainwindow.cpp" line="485"/>
|
||||
<source>No file is opened.</source>
|
||||
<translation type="unfinished"></translation>
|
||||
</message>
|
||||
<message>
|
||||
<location filename="../gui/mainwindow.cpp" line="486"/>
|
||||
<location filename="../gui/mainwindow.cpp" line="488"/>
|
||||
<source>Unable to save file information because the current process hasn't been finished yet.</source>
|
||||
<translation type="unfinished"></translation>
|
||||
</message>
|
||||
|
|
Loading…
Reference in New Issue