X-Git-Url: https://main.carlh.net/gitweb/?p=dcpomatic.git;a=blobdiff_plain;f=src%2Flib%2Femailer.h;h=89993ca48f4923cd6668e29aa923370102c13a9f;hp=4b4d1f6f77d4013905d2609decbb2bd9ef430c57;hb=aeb835a18c8df347e0ed68fb24631b320abeb611;hpb=fa8bdd16e1b3742e921b928708614613b6a21036 diff --git a/src/lib/emailer.h b/src/lib/emailer.h index 4b4d1f6f7..89993ca48 100644 --- a/src/lib/emailer.h +++ b/src/lib/emailer.h @@ -27,13 +27,16 @@ public: void add_cc (std::string cc); void add_bcc (std::string bcc); - void add_attachment (boost::filesystem::path attachment, std::string); + void add_attachment (boost::filesystem::path file, std::string name, std::string mime_type); void send (boost::shared_ptr job); - std::string notes () const; + std::string notes () const { + return _notes; + } size_t get_data (void* ptr, size_t size, size_t nmemb); + int debug (CURL* curl, curl_infotype type, char* data, size_t size); private: static std::string address_list (std::list addresses); @@ -44,8 +47,15 @@ private: std::string _body; std::list _cc; std::list _bcc; - std::list > _attachments; + + struct Attachment { + boost::filesystem::path file; + std::string name; + std::string mime_type; + }; + + std::list _attachments; std::string _email; size_t _offset; - boost::scoped_array _notes_buffer; + std::string _notes; };