mirror of
https://github.com/creyD/intelliphoto.git
synced 2026-04-13 11:50:31 +02:00
Bug with getting the filetype
This commit is contained in:
@@ -1,16 +1,28 @@
|
||||
#include "IntelliDatamanager.h"
|
||||
#include "Layer/PaintingArea.h"
|
||||
|
||||
IntelliDatamanager::IntelliDatamanager()
|
||||
{
|
||||
|
||||
bool IntelliDatamanager::saveProject(PaintingArea* Canvas, QString filePath){
|
||||
QFile openFile(filePath);
|
||||
|
||||
if(openFile.open(QIODevice::WriteOnly)){
|
||||
qDebug() << "works.";
|
||||
openFile.write("Hahaha");
|
||||
openFile.close();
|
||||
return true;
|
||||
}
|
||||
|
||||
return false;
|
||||
}
|
||||
|
||||
void IntelliDatamanager::saveProject(PaintingArea* Canvas, QString filePath){
|
||||
bool IntelliDatamanager::loadProject(PaintingArea* Canvas, QString filePath){
|
||||
QFile openFile(filePath);
|
||||
|
||||
if(openFile.open(QIODevice::ReadOnly)){
|
||||
qDebug() << openFile.readAll();
|
||||
openFile.close();
|
||||
return true;
|
||||
}
|
||||
|
||||
return;
|
||||
}
|
||||
|
||||
void IntelliDatamanager::loadProject(PaintingArea* Canvas, QString filePath){
|
||||
return;
|
||||
return false;
|
||||
}
|
||||
|
||||
@@ -1,17 +1,16 @@
|
||||
#ifndef INTELLIDATAMANAGER_H
|
||||
#define INTELLIDATAMANAGER_H
|
||||
|
||||
#include "Layer/PaintingArea.h"
|
||||
#include <QFile>
|
||||
#include <QDebug>
|
||||
|
||||
class IntelliDatamanager
|
||||
{
|
||||
private:
|
||||
class PaintingArea;
|
||||
|
||||
public:
|
||||
void loadProject(PaintingArea* Canvas, QString filePath = "unnamed.idf");
|
||||
void saveProject(PaintingArea* Canvas, QString filePath = "unnamed.idf");
|
||||
IntelliDatamanager();
|
||||
};
|
||||
namespace IntelliDatamanager{
|
||||
|
||||
bool loadProject(PaintingArea* Canvas, QString filePath = "unnamed.idf");
|
||||
bool saveProject(PaintingArea* Canvas, QString filePath = "unnamed.idf");
|
||||
|
||||
}
|
||||
|
||||
#endif // INTELLIDATAMANAGER_H
|
||||
|
||||
Reference in New Issue
Block a user