2 * Copyright 2012 Samsung Electronics Co., Ltd
4 * Licensed under the Flora License, Version 1.0 (the "License");
5 * you may not use this file except in compliance with the License.
6 * You may obtain a copy of the License at
8 * http://www.tizenopensource.org/license
10 * Unless required by applicable law or agreed to in writing, software
11 * distributed under the License is distributed on an "AS IS" BASIS,
12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 * See the License for the specific language governing permissions and
14 * limitations under the License.
17 #ifndef __DEF_email_viewer_logic_H__
18 #define __DEF_email_viewer_logic_H__
20 #include <Elementary.h>
23 #include "email-api.h"
24 #include "email-types.h"
26 #define ATTACH_MAX 65536
27 #define CONCAT_FORMAT(x, y, z) ((x<<16) | (y<<8) | z)
29 typedef struct _EmailViewerPrivate EmailViewerPrivate;
30 struct _EmailViewerPrivate {
34 gboolean download_mail;
38 gboolean b_all_att_save;
44 int download_all_email_handle[ATTACH_MAX];
45 unsigned int download_all_cnt;
46 unsigned int download_all_fail_cnt;
47 email_mail_data_t *mail_info;
48 email_attachment_data_t *attachment_info;
49 email_address_info_list_t *addrs_info_list;
53 typedef struct _EmailViewerProp EmailViewerProp;
54 struct _EmailViewerProp {
59 email_mail_status_t status2;
60 email_mail_priority_t priority;
66 char *sender_display_name;
70 char *from_contact_name;
71 char *to_contact_name;
72 char *cc_contact_name;
73 char *bcc_contact_name;
83 gint64 total_att_size;
86 gboolean has_attachment;
90 gboolean request_report;
94 typedef struct _EmailAttachmentType EmailAttachmentType;
95 struct _EmailAttachmentType {
101 gboolean download_yn;
103 gboolean inline_content;
106 gboolean viewer_get_internal_mail_info(EmailViewerProp *prop, EmailViewerPrivate *email_data);
107 void viewer_make_internal_mail(EmailViewerProp *prop, EmailViewerPrivate *email_data);
108 void viewer_set_mail_seen(EmailViewerProp *prop, email_mail_data_t * mail_info);
110 #endif /* __DEF_email_viewer_logic_H__ */