diff options
Diffstat (limited to 'templatelayout.cpp')
-rw-r--r-- | templatelayout.cpp | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/templatelayout.cpp b/templatelayout.cpp index fec57cb2a..9caf773d0 100644 --- a/templatelayout.cpp +++ b/templatelayout.cpp @@ -4,6 +4,8 @@ #include "helpers.h" #include "display.h" +QList<QString> grantlee_templates; + int getTotalWork(print_options *printOptions) { if (printOptions->print_selected) { @@ -19,6 +21,18 @@ int getTotalWork(print_options *printOptions) return dives; } +void find_all_templates() +{ + QDir dir(getSubsurfaceDataPath("printing_templates")); + QFileInfoList list = dir.entryInfoList(QDir::Files | QDir::NoDotAndDotDot); + foreach (QFileInfo finfo, list) { + QString filename = finfo.fileName(); + if (filename.at(filename.size() - 1) != '~') { + grantlee_templates.append(finfo.fileName()); + } + } +} + TemplateLayout::TemplateLayout(print_options *PrintOptions, template_options *templateOptions) : m_engine(NULL) { |