Subversion Repositories OpenInventory

Compare Revisions

Regard whitespace Rev 199 → Rev 198

/trunk/DBViewer/fileform.cpp
57,16 → 57,12
 
void FileForm::on_pushButton_3_clicked(){ // îáðàáîò÷èê íàæàòèÿ êíîïêè "Ñîõðàíèòü ôàéë"
 
QString fileName = QFileDialog::getSaveFileName(this, tr("Save File"),
"",
tr("All Files (*.*);;Image Files (*.png *.jpg *.bmp);;Text files (*.txt);;XML files (*.xml)"));
 
QByteArray data_tmp;
QFile file;
QDataStream out(&Data,QIODevice::ReadOnly);
QString fileName;
out >> fileName;
fileName = QFileDialog::getSaveFileName(this, tr("Save File"),
fileName,
tr("All Files (*.*);;Image Files (*.png *.jpg *.bmp);;Text files (*.txt);;XML files (*.xml)"));
 
 
int i;
i++;
if (fileName.isEmpty()) return;
77,17 → 73,17
 
 
// Data = file.readAll();
 
QDataStream out(&Data,QIODevice::ReadOnly);
// out.device()->reset();
out >> fileName;
 
 
 
file.setFileName(fileName);
if (!file.open(QIODevice::ReadWrite)) return;
data_tmp.clear();
out >> data_tmp;
int count;
count = file.write(data_tmp);
int size;
size = file.size();
 
file.close();