imageEditor is working and preview of images works

This commit is contained in:
Chris Cochrun 2022-04-08 17:31:44 -05:00
parent 0cee5db60d
commit 818b57cef7
4 changed files with 6 additions and 3 deletions

View file

@ -4,6 +4,8 @@
:END:
* Inbox
** TODO Images stored in sql need to have aspect saved and applied dynamically here
[[file:~/dev/church-presenter/src/qml/presenter/Slide.qml::fillMode: Image.PreserveAspectCrop]]
** TODO Make an image sql model
[[file:~/dev/church-presenter/src/videosqlmodel.h::ifndef VIDEOSQLMODEL_H]]
** TODO Build out a slide preview system so we can see each slide in the song or image slideshow

View file

@ -37,10 +37,10 @@ static void createImageTable()
qDebug() << query.lastQuery();
qDebug() << "inserting into images";
query.exec("INSERT INTO images (title, filePath) VALUES ('Dec 180', '/home/chris/nextcloud/tfc/openlp/180-dec.png')");
query.exec("INSERT INTO images (title, filePath) VALUES ('Dec 180', 'file:///home/chris/nextcloud/tfc/openlp/180-dec.png')");
qDebug() << query.lastQuery();
query.exec("INSERT INTO images (title, filePath) VALUES ('No TFC', "
"'/home/chris/nextcloud/tfc/openlp/No TFC.png')");
"'file:///home/chris/nextcloud/tfc/openlp/No TFC.png')");
query.exec("select * from images");
qDebug() << query.lastQuery();

View file

@ -163,7 +163,7 @@ Item {
Layout.preferredHeight: Layout.preferredWidth / 16 * 9
Layout.alignment: Qt.AlignCenter
fillMode: Image.PreserveAspectFit
source: "file://" + image.toString()
source: image
}
Item {
id: botEmpty

View file

@ -175,6 +175,7 @@ Controls.Page {
videoEditor.visible = false;
videoEditor.stop();
songEditor.visible = false;
imageEditor.visible = false;
presentation.visible = true;
editMode = false;
}