1. Changed license year
[apps/home/mobileprint.git] / mobileprint / smsc / include / smsc_position.h
1 /*
2 *  Mobileprint
3 *
4 * Copyright 2013  Samsung Electronics Co., Ltd
5
6 * Licensed under the Flora License, Version 1.1 (the "License");
7 * you may not use this file except in compliance with the License.
8 * You may obtain a copy of the License at
9
10 * http://floralicense.org/license/
11
12 * Unless required by applicable law or agreed to in writing, software
13 * distributed under the License is distributed on an "AS IS" BASIS,
14 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
15 * See the License for the specific language governing permissions and
16 * limitations under the License.
17 *
18 */
19
20 #ifndef _SMSC_POSITION_H_INCLUDED_
21 #define _SMSC_POSITION_H_INCLUDED_
22
23 #include <paper_size.h>
24
25 struct smsc_position {
26         int is_configured;
27         struct size_px available_size;
28         struct size_px page_size_px;
29         int page_space;
30         int pages_count;
31         int offset;
32
33         int position_update_event_type;
34 };
35
36
37 struct smsc_position_event {
38         int is_ok; /* STUB */
39 };
40
41
42 int init_smsc_position(struct smsc_position *position);
43 int set_smsc_position_settings(struct smsc_position *position, int pages_count,
44                 const struct size_px *available_size_px,
45                 const struct size_pts *page_size);
46 int get_smsc_position_all_width(const struct smsc_position *position);
47 int get_smsc_position_cur_page(const struct smsc_position *position);
48 int *get_smsc_position_visible_pages(const struct smsc_position *position);
49 int get_smsc_position_page(const struct smsc_position *position,
50                 int page, int *is_ok);
51 int get_smsc_position_cur_page_center_xdiff(
52                 const struct smsc_position *position, int *is_ok);
53 int move_smsc_position(struct smsc_position *position, int xdiff);
54 int set_smsc_position(struct smsc_position *position, int offset);
55
56
57 #endif /* _SMSC_POSITION_H_INCLUDED_ */
58