Merge lp:~mzanetti/reminders-app/store-local-resources-in-infofile into lp:reminders-app

Proposed by Michael Zanetti
Status: Merged
Approved by: Riccardo Padovani
Approved revision: 449
Merged at revision: 449
Proposed branch: lp:~mzanetti/reminders-app/store-local-resources-in-infofile
Merge into: lp:reminders-app
Diff against target: 18 lines (+9/-0)
1 file modified
src/libqtevernote/note.cpp (+9/-0)
To merge this branch: bzr merge lp:~mzanetti/reminders-app/store-local-resources-in-infofile
Reviewer Review Type Date Requested Status
Riccardo Padovani Approve
Ubuntu Phone Apps Jenkins Bot continuous-integration Approve
Review via email: mp+260990@code.launchpad.net

Commit message

Store locally attached resources into the info file

To post a comment you must log in.
Revision history for this message
Ubuntu Phone Apps Jenkins Bot (ubuntu-phone-apps-jenkins-bot) wrote :
review: Approve (continuous-integration)
Revision history for this message
Riccardo Padovani (rpadovani) wrote :

lgtm

review: Approve

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'src/libqtevernote/note.cpp'
2--- src/libqtevernote/note.cpp 2015-03-15 20:00:21 +0000
3+++ src/libqtevernote/note.cpp 2015-06-03 17:47:24 +0000
4@@ -540,6 +540,15 @@
5 Resource *resource = new Resource(fileName.path(), this);
6 m_resources.insert(resource->hash(), resource);
7 m_content.attachFile(position, resource->hash(), resource->type());
8+
9+ QSettings infoFile(m_infoFile, QSettings::IniFormat);
10+ infoFile.beginGroup("resources");
11+ infoFile.beginGroup(resource->hash());
12+ infoFile.setValue("fileName", resource->fileName());
13+ infoFile.setValue("type", resource->type());
14+ infoFile.endGroup();
15+ infoFile.endGroup();
16+
17 emit resourcesChanged();
18 emit contentChanged();
19

Subscribers

People subscribed via source and target branches