1 \hypertarget{homescreen_8cpp}{}\section{src/homescreen.cpp File Reference}
2 \label{homescreen_8cpp}\index{src/homescreen.\+cpp@{src/homescreen.\+cpp}}
3 {\ttfamily \#include $<$memory$>$}\\*
4 {\ttfamily \#include $<$algorithm$>$}\\*
5 {\ttfamily \#include \char`\"{}hs-\/helper.\+h\char`\"{}}\\*
6 {\ttfamily \#include \char`\"{}hmi-\/debug.\+h\char`\"{}}\\*
7 {\ttfamily \#include \char`\"{}hs-\/clientmanager.\+h\char`\"{}}\\*
9 \begin{DoxyCompactItemize}
11 \#define \hyperlink{homescreen_8cpp_a369266c24eacffb87046522897a570d5}{\+\_\+\+G\+N\+U\+\_\+\+S\+O\+U\+R\+CE}
12 \end{DoxyCompactItemize}
13 \subsection*{Functions}
14 \begin{DoxyCompactItemize}
16 static void \hyperlink{homescreen_8cpp_ace65cfe6008848a3cd66581f536cc4c9}{ping\+Sample} (afb\+\_\+req\+\_\+t request)
18 static void \hyperlink{homescreen_8cpp_ab8abb667377924d5c073611738febbd3}{tap\+\_\+shortcut} (afb\+\_\+req\+\_\+t request)
20 static void \hyperlink{homescreen_8cpp_a0df2b60ff6cd56b53dc87b36bfee2b91}{on\+\_\+screen\+\_\+message} (afb\+\_\+req\+\_\+t request)
22 static void \hyperlink{homescreen_8cpp_a7443596f6ddf459824ecd8138c681532}{on\+\_\+screen\+\_\+reply} (afb\+\_\+req\+\_\+t request)
24 static void \hyperlink{homescreen_8cpp_a6e942ab2b7207d2aef9adce71a4574e8}{subscribe} (afb\+\_\+req\+\_\+t request)
26 static void \hyperlink{homescreen_8cpp_a3b162ab1856a8fa4284cb2c5c35ea748}{unsubscribe} (afb\+\_\+req\+\_\+t request)
28 static void \hyperlink{homescreen_8cpp_ae475c69e7ca2a539ae0fb40a82963ac1}{show\+Window} (afb\+\_\+req\+\_\+t request)
30 static void \hyperlink{homescreen_8cpp_a057c380ea38cfba4e2fbccc40fc21798}{hide\+Window} (afb\+\_\+req\+\_\+t request)
32 static void \hyperlink{homescreen_8cpp_a710bcc84a61e11dbd4517def2764ff95}{reply\+Show\+Window} (afb\+\_\+req\+\_\+t request)
34 static void \hyperlink{homescreen_8cpp_ad96a84455e8676abb4486e48ef67b1ad}{show\+Notification} (afb\+\_\+req\+\_\+t request)
36 static void \hyperlink{homescreen_8cpp_a916c8dd31373222ee2b6ef89aca91978}{show\+Information} (afb\+\_\+req\+\_\+t request)
38 static int \hyperlink{homescreen_8cpp_ab3b1914acb53dcc038c1cf86c2975785}{preinit} (afb\+\_\+api\+\_\+t api)
40 static int \hyperlink{homescreen_8cpp_a5d7de3437d5dcb79fa035959d95878db}{init} (afb\+\_\+api\+\_\+t api)
42 static void \hyperlink{homescreen_8cpp_a60665935681c76d38b3833912109cdd3}{onevent} (afb\+\_\+api\+\_\+t api, const char $\ast$event, struct json\+\_\+object $\ast$object)
43 \end{DoxyCompactItemize}
44 \subsection*{Variables}
45 \begin{DoxyCompactItemize}
47 const char \hyperlink{homescreen_8cpp_aed1c5296a2e6d34945507a0fca17a376}{\+\_\+error} \mbox{[}$\,$\mbox{]} = \char`\"{}error\char`\"{}
49 const char \hyperlink{homescreen_8cpp_a6a0e1db2562b442f8131ddf64b61d1ba}{\+\_\+application\+\_\+id} \mbox{[}$\,$\mbox{]} = \char`\"{}application\+\_\+id\char`\"{}
51 const char \hyperlink{homescreen_8cpp_abfd6c1d6f316fa952b11553f8f275e92}{\+\_\+display\+\_\+message} \mbox{[}$\,$\mbox{]} = \char`\"{}display\+\_\+message\char`\"{}
53 const char \hyperlink{homescreen_8cpp_a79b0f0b481161527ccb80e83da143219}{\+\_\+reply\+\_\+message} \mbox{[}$\,$\mbox{]} = \char`\"{}reply\+\_\+message\char`\"{}
55 static \hyperlink{class_h_s___client_manager}{H\+S\+\_\+\+Client\+Manager} $\ast$ \hyperlink{homescreen_8cpp_a501f5bca8425de3171d46e0723f466ec}{g\+\_\+client\+\_\+manager} = \hyperlink{class_h_s___client_manager_ad86c1fea7d107d52cbf0466fb7a2658b}{H\+S\+\_\+\+Client\+Manager\+::instance}()
57 static const afb\+\_\+verb\+\_\+t \hyperlink{homescreen_8cpp_a01e06b6317acebc1d5686386b15f0872}{verbs} \mbox{[}$\,$\mbox{]}
59 const afb\+\_\+binding\+\_\+t \hyperlink{homescreen_8cpp_a970e7864dba290a0371534ad4961bcc5}{afb\+Binding\+Export}
60 \end{DoxyCompactItemize}
63 \subsection{Macro Definition Documentation}
64 \index{homescreen.\+cpp@{homescreen.\+cpp}!\+\_\+\+G\+N\+U\+\_\+\+S\+O\+U\+R\+CE@{\+\_\+\+G\+N\+U\+\_\+\+S\+O\+U\+R\+CE}}
65 \index{\+\_\+\+G\+N\+U\+\_\+\+S\+O\+U\+R\+CE@{\+\_\+\+G\+N\+U\+\_\+\+S\+O\+U\+R\+CE}!homescreen.\+cpp@{homescreen.\+cpp}}
66 \subsubsection[{\texorpdfstring{\+\_\+\+G\+N\+U\+\_\+\+S\+O\+U\+R\+CE}{_GNU_SOURCE}}]{\setlength{\rightskip}{0pt plus 5cm}\#define \+\_\+\+G\+N\+U\+\_\+\+S\+O\+U\+R\+CE}\hypertarget{homescreen_8cpp_a369266c24eacffb87046522897a570d5}{}\label{homescreen_8cpp_a369266c24eacffb87046522897a570d5}
69 Definition at line 18 of file homescreen.\+cpp.
73 \subsection{Function Documentation}
74 \index{homescreen.\+cpp@{homescreen.\+cpp}!hide\+Window@{hide\+Window}}
75 \index{hide\+Window@{hide\+Window}!homescreen.\+cpp@{homescreen.\+cpp}}
76 \subsubsection[{\texorpdfstring{hide\+Window(afb\+\_\+req\+\_\+t request)}{hideWindow(afb_req_t request)}}]{\setlength{\rightskip}{0pt plus 5cm}static void hide\+Window (
77 \begin{DoxyParamCaption}
78 \item[{afb\+\_\+req\+\_\+t}]{request}
79 \end{DoxyParamCaption}
80 )\hspace{0.3cm}{\ttfamily [static]}}\hypertarget{homescreen_8cpp_a057c380ea38cfba4e2fbccc40fc21798}{}\label{homescreen_8cpp_a057c380ea38cfba4e2fbccc40fc21798}
83 \subparagraph*{Parameters}
87 \item request \+: the request
90 \subparagraph*{Return}
94 Definition at line 221 of file homescreen.\+cpp.
99 223 \hyperlink{include_2hmi-debug_8h_abc0d6e0760017d8ae48b836925b2ef15}{HMI\_NOTICE}(\textcolor{stringliteral}{"homescreen-service"},\textcolor{stringliteral}{"called."});
101 225 \textcolor{keywordtype}{int} ret = \hyperlink{homescreen_8cpp_a501f5bca8425de3171d46e0723f466ec}{g\_client\_manager}->\hyperlink{class_h_s___client_manager_a6195694d281a3b97b0345b96c0add1fd}{hideWindow}(request);
102 226 \textcolor{keywordflow}{if} (ret != 0) \{
103 227 afb\_req\_fail\_f(request, \textcolor{stringliteral}{"failed"}, \textcolor{stringliteral}{"called %s, Unknown parameter"}, \_\_FUNCTION\_\_);
104 228 \textcolor{keywordflow}{return};
107 231 \textcolor{comment}{// response to HomeScreen}
108 232 \textcolor{keyword}{struct }json\_object *res = json\_object\_new\_object();
109 233 \hyperlink{hs-helper_8cpp_ae83604a37134e7bdee3ce4f10bb0b47a}{hs\_add\_object\_to\_json\_object\_func}(res, \_\_FUNCTION\_\_, 2,
110 234 \hyperlink{homescreen_8cpp_aed1c5296a2e6d34945507a0fca17a376}{\_error}, ret);
111 235 afb\_req\_success(request, res, \textcolor{stringliteral}{"afb\_event\_push event [hideWindow]"});
114 \index{homescreen.\+cpp@{homescreen.\+cpp}!init@{init}}
115 \index{init@{init}!homescreen.\+cpp@{homescreen.\+cpp}}
116 \subsubsection[{\texorpdfstring{init(afb\+\_\+api\+\_\+t api)}{init(afb_api_t api)}}]{\setlength{\rightskip}{0pt plus 5cm}static int init (
117 \begin{DoxyParamCaption}
118 \item[{afb\+\_\+api\+\_\+t}]{api}
119 \end{DoxyParamCaption}
120 )\hspace{0.3cm}{\ttfamily [static]}}\hypertarget{homescreen_8cpp_a5d7de3437d5dcb79fa035959d95878db}{}\label{homescreen_8cpp_a5d7de3437d5dcb79fa035959d95878db}
121 homescreen binding init function
123 \subparagraph*{Parameters}
127 \item api \+: the api serving the request
130 \subparagraph*{Return}
134 Definition at line 368 of file homescreen.\+cpp.
139 370 \hyperlink{include_2hmi-debug_8h_abc0d6e0760017d8ae48b836925b2ef15}{HMI\_NOTICE}(\textcolor{stringliteral}{"homescreen-service"},\textcolor{stringliteral}{"binding init"});
141 372 \hyperlink{homescreen_8cpp_a501f5bca8425de3171d46e0723f466ec}{g\_client\_manager}->\hyperlink{class_h_s___client_manager_ae0b9b18adeffca7822b060ad4ea8a7a1}{init}();
143 374 \textcolor{keywordflow}{return} 0;
146 \index{homescreen.\+cpp@{homescreen.\+cpp}!on\+\_\+screen\+\_\+message@{on\+\_\+screen\+\_\+message}}
147 \index{on\+\_\+screen\+\_\+message@{on\+\_\+screen\+\_\+message}!homescreen.\+cpp@{homescreen.\+cpp}}
148 \subsubsection[{\texorpdfstring{on\+\_\+screen\+\_\+message(afb\+\_\+req\+\_\+t request)}{on_screen_message(afb_req_t request)}}]{\setlength{\rightskip}{0pt plus 5cm}static void on\+\_\+screen\+\_\+message (
149 \begin{DoxyParamCaption}
150 \item[{afb\+\_\+req\+\_\+t}]{request}
151 \end{DoxyParamCaption}
152 )\hspace{0.3cm}{\ttfamily [static]}}\hypertarget{homescreen_8cpp_a0df2b60ff6cd56b53dc87b36bfee2b91}{}\label{homescreen_8cpp_a0df2b60ff6cd56b53dc87b36bfee2b91}
153 Home\+Screen On\+Screen message
155 \subparagraph*{Parameters}
159 \item display\+\_\+message \+: message for display
162 \subparagraph*{Return}
166 Definition at line 85 of file homescreen.\+cpp.
171 87 \hyperlink{include_2hmi-debug_8h_abc0d6e0760017d8ae48b836925b2ef15}{HMI\_NOTICE}(\textcolor{stringliteral}{"homescreen-service"},\textcolor{stringliteral}{"called."});
173 89 \textcolor{keywordtype}{int} ret = \hyperlink{homescreen_8cpp_a501f5bca8425de3171d46e0723f466ec}{g\_client\_manager}->\hyperlink{class_h_s___client_manager_a58ce4a013d3694265dd69f481bf88510}{on\_screen\_message}(request);
174 90 \textcolor{keywordflow}{if} (ret != 0) \{
175 91 afb\_req\_fail\_f(request, \textcolor{stringliteral}{"failed"}, \textcolor{stringliteral}{"called %s, Unknown parameter"}, \_\_FUNCTION\_\_);
176 92 \textcolor{keywordflow}{return};
179 95 \textcolor{comment}{// response to HomeScreen}
180 96 \textcolor{keyword}{struct }json\_object *res = json\_object\_new\_object();
181 97 \hyperlink{hs-helper_8cpp_ae83604a37134e7bdee3ce4f10bb0b47a}{hs\_add\_object\_to\_json\_object\_func}(res, \_\_FUNCTION\_\_, 2,
182 98 \hyperlink{homescreen_8cpp_aed1c5296a2e6d34945507a0fca17a376}{\_error}, ret);
183 99 afb\_req\_success(request, res, \textcolor{stringliteral}{"afb\_event\_push event [on\_screen\_message]"});
186 \index{homescreen.\+cpp@{homescreen.\+cpp}!on\+\_\+screen\+\_\+reply@{on\+\_\+screen\+\_\+reply}}
187 \index{on\+\_\+screen\+\_\+reply@{on\+\_\+screen\+\_\+reply}!homescreen.\+cpp@{homescreen.\+cpp}}
188 \subsubsection[{\texorpdfstring{on\+\_\+screen\+\_\+reply(afb\+\_\+req\+\_\+t request)}{on_screen_reply(afb_req_t request)}}]{\setlength{\rightskip}{0pt plus 5cm}static void on\+\_\+screen\+\_\+reply (
189 \begin{DoxyParamCaption}
190 \item[{afb\+\_\+req\+\_\+t}]{request}
191 \end{DoxyParamCaption}
192 )\hspace{0.3cm}{\ttfamily [static]}}\hypertarget{homescreen_8cpp_a7443596f6ddf459824ecd8138c681532}{}\label{homescreen_8cpp_a7443596f6ddf459824ecd8138c681532}
193 Home\+Screen On\+Screen Reply
195 \subparagraph*{Parameters}
199 \item reply\+\_\+message \+: message for reply
202 \subparagraph*{Return}
206 Definition at line 113 of file homescreen.\+cpp.
211 115 \hyperlink{include_2hmi-debug_8h_abc0d6e0760017d8ae48b836925b2ef15}{HMI\_NOTICE}(\textcolor{stringliteral}{"homescreen-service"},\textcolor{stringliteral}{"called."});
213 117 \textcolor{keywordtype}{int} ret = \hyperlink{homescreen_8cpp_a501f5bca8425de3171d46e0723f466ec}{g\_client\_manager}->\hyperlink{class_h_s___client_manager_aa78f992287e3b8fe93422b331dc9edc5}{on\_screen\_reply}(request);
214 118 \textcolor{keywordflow}{if} (ret != 0) \{
215 119 afb\_req\_fail\_f(request, \textcolor{stringliteral}{"failed"}, \textcolor{stringliteral}{"called %s, Unknown parameter"}, \_\_FUNCTION\_\_);
216 120 \textcolor{keywordflow}{return};
219 123 \textcolor{comment}{// response to HomeScreen}
220 124 \textcolor{keyword}{struct }json\_object *res = json\_object\_new\_object();
221 125 \hyperlink{hs-helper_8cpp_ae83604a37134e7bdee3ce4f10bb0b47a}{hs\_add\_object\_to\_json\_object\_func}(res, \_\_FUNCTION\_\_, 2,
222 126 \hyperlink{homescreen_8cpp_aed1c5296a2e6d34945507a0fca17a376}{\_error}, ret);
223 127 afb\_req\_success(request, res, \textcolor{stringliteral}{"afb\_event\_push event [on\_screen\_reply]"});
226 \index{homescreen.\+cpp@{homescreen.\+cpp}!onevent@{onevent}}
227 \index{onevent@{onevent}!homescreen.\+cpp@{homescreen.\+cpp}}
228 \subsubsection[{\texorpdfstring{onevent(afb\+\_\+api\+\_\+t api, const char $\ast$event, struct json\+\_\+object $\ast$object)}{onevent(afb_api_t api, const char *event, struct json_object *object)}}]{\setlength{\rightskip}{0pt plus 5cm}static void onevent (
229 \begin{DoxyParamCaption}
230 \item[{afb\+\_\+api\+\_\+t}]{api, }
231 \item[{const char $\ast$}]{event, }
232 \item[{struct json\+\_\+object $\ast$}]{object}
233 \end{DoxyParamCaption}
234 )\hspace{0.3cm}{\ttfamily [static]}}\hypertarget{homescreen_8cpp_a60665935681c76d38b3833912109cdd3}{}\label{homescreen_8cpp_a60665935681c76d38b3833912109cdd3}
235 homescreen binding event function
237 \subparagraph*{Parameters}
241 \item api \+: the api serving the request
242 \item event \+: event name
243 \item object \+: event json object
246 \subparagraph*{Return}
250 Definition at line 389 of file homescreen.\+cpp.
255 391 \hyperlink{include_2hmi-debug_8h_abc0d6e0760017d8ae48b836925b2ef15}{HMI\_NOTICE}(\textcolor{stringliteral}{"homescreen-service"},\textcolor{stringliteral}{"on\_event %s"}, event);
258 \index{homescreen.\+cpp@{homescreen.\+cpp}!ping\+Sample@{ping\+Sample}}
259 \index{ping\+Sample@{ping\+Sample}!homescreen.\+cpp@{homescreen.\+cpp}}
260 \subsubsection[{\texorpdfstring{ping\+Sample(afb\+\_\+req\+\_\+t request)}{pingSample(afb_req_t request)}}]{\setlength{\rightskip}{0pt plus 5cm}static void ping\+Sample (
261 \begin{DoxyParamCaption}
262 \item[{afb\+\_\+req\+\_\+t}]{request}
263 \end{DoxyParamCaption}
264 )\hspace{0.3cm}{\ttfamily [static]}}\hypertarget{homescreen_8cpp_ace65cfe6008848a3cd66581f536cc4c9}{}\label{homescreen_8cpp_ace65cfe6008848a3cd66581f536cc4c9}
267 Definition at line 38 of file homescreen.\+cpp.
272 40 \textcolor{keyword}{static} \textcolor{keywordtype}{int} pingcount = 0;
273 41 afb\_req\_success\_f(request, json\_object\_new\_int(pingcount), \textcolor{stringliteral}{"Ping count = %d"}, pingcount);
274 42 \hyperlink{include_2hmi-debug_8h_abc0d6e0760017d8ae48b836925b2ef15}{HMI\_NOTICE}(\textcolor{stringliteral}{"homescreen-service"},\textcolor{stringliteral}{"Verbosity macro at level notice invoked at ping invocation
275 count = %d"}, pingcount);
279 \index{homescreen.\+cpp@{homescreen.\+cpp}!preinit@{preinit}}
280 \index{preinit@{preinit}!homescreen.\+cpp@{homescreen.\+cpp}}
281 \subsubsection[{\texorpdfstring{preinit(afb\+\_\+api\+\_\+t api)}{preinit(afb_api_t api)}}]{\setlength{\rightskip}{0pt plus 5cm}static int preinit (
282 \begin{DoxyParamCaption}
283 \item[{afb\+\_\+api\+\_\+t}]{api}
284 \end{DoxyParamCaption}
285 )\hspace{0.3cm}{\ttfamily [static]}}\hypertarget{homescreen_8cpp_ab3b1914acb53dcc038c1cf86c2975785}{}\label{homescreen_8cpp_ab3b1914acb53dcc038c1cf86c2975785}
286 homescreen binding preinit function
288 \subparagraph*{Parameters}
292 \item api \+: the api serving the request
295 \subparagraph*{Return}
299 Definition at line 352 of file homescreen.\+cpp.
304 354 \hyperlink{include_2hmi-debug_8h_abc0d6e0760017d8ae48b836925b2ef15}{HMI\_NOTICE}(\textcolor{stringliteral}{"homescreen-service"},\textcolor{stringliteral}{"binding preinit (was register)"});
305 355 \textcolor{keywordflow}{return} 0;
308 \index{homescreen.\+cpp@{homescreen.\+cpp}!reply\+Show\+Window@{reply\+Show\+Window}}
309 \index{reply\+Show\+Window@{reply\+Show\+Window}!homescreen.\+cpp@{homescreen.\+cpp}}
310 \subsubsection[{\texorpdfstring{reply\+Show\+Window(afb\+\_\+req\+\_\+t request)}{replyShowWindow(afb_req_t request)}}]{\setlength{\rightskip}{0pt plus 5cm}static void reply\+Show\+Window (
311 \begin{DoxyParamCaption}
312 \item[{afb\+\_\+req\+\_\+t}]{request}
313 \end{DoxyParamCaption}
314 )\hspace{0.3cm}{\ttfamily [static]}}\hypertarget{homescreen_8cpp_a710bcc84a61e11dbd4517def2764ff95}{}\label{homescreen_8cpp_a710bcc84a61e11dbd4517def2764ff95}
315 reply\+Show\+Window event
317 \subparagraph*{Parameters}
321 \item request \+: the request
324 \subparagraph*{Return}
328 Definition at line 248 of file homescreen.\+cpp.
333 250 \hyperlink{include_2hmi-debug_8h_abc0d6e0760017d8ae48b836925b2ef15}{HMI\_NOTICE}(\textcolor{stringliteral}{"homescreen-service"},\textcolor{stringliteral}{"called."});
335 252 \textcolor{keywordtype}{int} ret = \hyperlink{homescreen_8cpp_a501f5bca8425de3171d46e0723f466ec}{g\_client\_manager}->\hyperlink{class_h_s___client_manager_a59b1c1e115b5a257a585c41f854f5fdd}{replyShowWindow}(request);
336 253 \textcolor{keywordflow}{if} (ret != 0) \{
337 254 afb\_req\_fail\_f(request, \textcolor{stringliteral}{"failed"}, \textcolor{stringliteral}{"called %s, Unknown parameter"}, \_\_FUNCTION\_\_);
338 255 \textcolor{keywordflow}{return};
341 258 \textcolor{comment}{// response to HomeScreen}
342 259 \textcolor{keyword}{struct }json\_object *res = json\_object\_new\_object();
343 260 \hyperlink{hs-helper_8cpp_ae83604a37134e7bdee3ce4f10bb0b47a}{hs\_add\_object\_to\_json\_object\_func}(res, \_\_FUNCTION\_\_, 2,
344 261 \hyperlink{homescreen_8cpp_aed1c5296a2e6d34945507a0fca17a376}{\_error}, ret);
345 262 afb\_req\_success(request, res, \textcolor{stringliteral}{"afb\_event\_push event [replyShowWindow]"});
348 \index{homescreen.\+cpp@{homescreen.\+cpp}!show\+Information@{show\+Information}}
349 \index{show\+Information@{show\+Information}!homescreen.\+cpp@{homescreen.\+cpp}}
350 \subsubsection[{\texorpdfstring{show\+Information(afb\+\_\+req\+\_\+t request)}{showInformation(afb_req_t request)}}]{\setlength{\rightskip}{0pt plus 5cm}static void show\+Information (
351 \begin{DoxyParamCaption}
352 \item[{afb\+\_\+req\+\_\+t}]{request}
353 \end{DoxyParamCaption}
354 )\hspace{0.3cm}{\ttfamily [static]}}\hypertarget{homescreen_8cpp_a916c8dd31373222ee2b6ef89aca91978}{}\label{homescreen_8cpp_a916c8dd31373222ee2b6ef89aca91978}
355 show\+Information event
357 the contents to homescreen which display at bottom area.
359 \subparagraph*{Parameters}
363 \item request \+: the request
366 \subparagraph*{Return}
370 Definition at line 306 of file homescreen.\+cpp.
375 308 \hyperlink{include_2hmi-debug_8h_abc0d6e0760017d8ae48b836925b2ef15}{HMI\_NOTICE}(\textcolor{stringliteral}{"homescreen-service"},\textcolor{stringliteral}{"called."});
377 310 \textcolor{keywordtype}{int} ret = \hyperlink{homescreen_8cpp_a501f5bca8425de3171d46e0723f466ec}{g\_client\_manager}->\hyperlink{class_h_s___client_manager_a0645294f89c67fd3c9b0cce62a900f69}{showInformation}(request);
378 311 \textcolor{keywordflow}{if} (ret != 0) \{
379 312 afb\_req\_fail\_f(request, \textcolor{stringliteral}{"failed"}, \textcolor{stringliteral}{"called %s, Unknown parameter"}, \_\_FUNCTION\_\_);
380 313 \textcolor{keywordflow}{return};
383 316 \textcolor{comment}{// response to Application}
384 317 \textcolor{keyword}{struct }json\_object *res = json\_object\_new\_object();
385 318 \hyperlink{hs-helper_8cpp_ae83604a37134e7bdee3ce4f10bb0b47a}{hs\_add\_object\_to\_json\_object\_func}(res, \_\_FUNCTION\_\_, 2,
386 319 \hyperlink{homescreen_8cpp_aed1c5296a2e6d34945507a0fca17a376}{\_error}, ret);
387 320 afb\_req\_success(request, res, \textcolor{stringliteral}{"afb\_event\_push event [showInformation]"});
390 \index{homescreen.\+cpp@{homescreen.\+cpp}!show\+Notification@{show\+Notification}}
391 \index{show\+Notification@{show\+Notification}!homescreen.\+cpp@{homescreen.\+cpp}}
392 \subsubsection[{\texorpdfstring{show\+Notification(afb\+\_\+req\+\_\+t request)}{showNotification(afb_req_t request)}}]{\setlength{\rightskip}{0pt plus 5cm}static void show\+Notification (
393 \begin{DoxyParamCaption}
394 \item[{afb\+\_\+req\+\_\+t}]{request}
395 \end{DoxyParamCaption}
396 )\hspace{0.3cm}{\ttfamily [static]}}\hypertarget{homescreen_8cpp_ad96a84455e8676abb4486e48ef67b1ad}{}\label{homescreen_8cpp_ad96a84455e8676abb4486e48ef67b1ad}
397 show\+Notification event
399 the contents to homescreen which display at top area.
401 \subparagraph*{Parameters}
405 \item request \+: the request
408 \subparagraph*{Return}
412 Definition at line 277 of file homescreen.\+cpp.
417 279 \hyperlink{include_2hmi-debug_8h_abc0d6e0760017d8ae48b836925b2ef15}{HMI\_NOTICE}(\textcolor{stringliteral}{"homescreen-service"},\textcolor{stringliteral}{"called."});
419 281 \textcolor{keywordtype}{int} ret = \hyperlink{homescreen_8cpp_a501f5bca8425de3171d46e0723f466ec}{g\_client\_manager}->\hyperlink{class_h_s___client_manager_a857934af280081ca6ac61d9f2cac37c5}{showNotification}(request);
420 282 \textcolor{keywordflow}{if} (ret != 0) \{
421 283 afb\_req\_fail\_f(request, \textcolor{stringliteral}{"failed"}, \textcolor{stringliteral}{"called %s, Unknown parameter"}, \_\_FUNCTION\_\_);
422 284 \textcolor{keywordflow}{return};
425 287 \textcolor{comment}{// response to Application}
426 288 \textcolor{keyword}{struct }json\_object *res = json\_object\_new\_object();
427 289 \hyperlink{hs-helper_8cpp_ae83604a37134e7bdee3ce4f10bb0b47a}{hs\_add\_object\_to\_json\_object\_func}(res, \_\_FUNCTION\_\_, 2,
428 290 \hyperlink{homescreen_8cpp_aed1c5296a2e6d34945507a0fca17a376}{\_error}, ret);
429 291 afb\_req\_success(request, res, \textcolor{stringliteral}{"afb\_event\_push event [showNotification]"});
432 \index{homescreen.\+cpp@{homescreen.\+cpp}!show\+Window@{show\+Window}}
433 \index{show\+Window@{show\+Window}!homescreen.\+cpp@{homescreen.\+cpp}}
434 \subsubsection[{\texorpdfstring{show\+Window(afb\+\_\+req\+\_\+t request)}{showWindow(afb_req_t request)}}]{\setlength{\rightskip}{0pt plus 5cm}static void show\+Window (
435 \begin{DoxyParamCaption}
436 \item[{afb\+\_\+req\+\_\+t}]{request}
437 \end{DoxyParamCaption}
438 )\hspace{0.3cm}{\ttfamily [static]}}\hypertarget{homescreen_8cpp_ae475c69e7ca2a539ae0fb40a82963ac1}{}\label{homescreen_8cpp_ae475c69e7ca2a539ae0fb40a82963ac1}
441 \subparagraph*{Parameters}
445 \item request \+: the request
448 \subparagraph*{Return}
452 Definition at line 194 of file homescreen.\+cpp.
457 196 \hyperlink{include_2hmi-debug_8h_abc0d6e0760017d8ae48b836925b2ef15}{HMI\_NOTICE}(\textcolor{stringliteral}{"homescreen-service"},\textcolor{stringliteral}{"called."});
459 198 \textcolor{keywordtype}{int} ret = \hyperlink{homescreen_8cpp_a501f5bca8425de3171d46e0723f466ec}{g\_client\_manager}->\hyperlink{class_h_s___client_manager_afed8158f276d1d22c32b0d89e970d442}{showWindow}(request);
460 199 \textcolor{keywordflow}{if} (ret != 0) \{
461 200 afb\_req\_fail\_f(request, \textcolor{stringliteral}{"failed"}, \textcolor{stringliteral}{"called %s, Unknown parameter"}, \_\_FUNCTION\_\_);
462 201 \textcolor{keywordflow}{return};
465 204 \textcolor{comment}{// response to HomeScreen}
466 205 \textcolor{keyword}{struct }json\_object *res = json\_object\_new\_object();
467 206 \hyperlink{hs-helper_8cpp_ae83604a37134e7bdee3ce4f10bb0b47a}{hs\_add\_object\_to\_json\_object\_func}(res, \_\_FUNCTION\_\_, 2,
468 207 \hyperlink{homescreen_8cpp_aed1c5296a2e6d34945507a0fca17a376}{\_error}, ret);
469 208 afb\_req\_success(request, res, \textcolor{stringliteral}{"afb\_event\_push event [showWindow]"});
472 \index{homescreen.\+cpp@{homescreen.\+cpp}!subscribe@{subscribe}}
473 \index{subscribe@{subscribe}!homescreen.\+cpp@{homescreen.\+cpp}}
474 \subsubsection[{\texorpdfstring{subscribe(afb\+\_\+req\+\_\+t request)}{subscribe(afb_req_t request)}}]{\setlength{\rightskip}{0pt plus 5cm}static void subscribe (
475 \begin{DoxyParamCaption}
476 \item[{afb\+\_\+req\+\_\+t}]{request}
477 \end{DoxyParamCaption}
478 )\hspace{0.3cm}{\ttfamily [static]}}\hypertarget{homescreen_8cpp_a6e942ab2b7207d2aef9adce71a4574e8}{}\label{homescreen_8cpp_a6e942ab2b7207d2aef9adce71a4574e8}
481 \subparagraph*{Parameters}
485 \item event \+: Event name. Event list is written in \hyperlink{libhomescreen_8cpp}{libhomescreen.\+cpp}
488 \subparagraph*{Return}
492 Definition at line 140 of file homescreen.\+cpp.
497 142 \hyperlink{include_2hmi-debug_8h_abc0d6e0760017d8ae48b836925b2ef15}{HMI\_NOTICE}(\textcolor{stringliteral}{"homescreen-service"},\textcolor{stringliteral}{"called."});
499 144 \textcolor{keywordtype}{int} ret = \hyperlink{homescreen_8cpp_a501f5bca8425de3171d46e0723f466ec}{g\_client\_manager}->\hyperlink{class_h_s___client_manager_a1b8a4e42342c4bcdc4e7dc4934e02469}{subscribe}(request);
500 145 \textcolor{keywordflow}{if}(ret) \{
501 146 afb\_req\_fail\_f(request, \textcolor{stringliteral}{"afb\_req\_subscribe failed"}, \textcolor{stringliteral}{"called %s."}, \_\_FUNCTION\_\_);
502 147 \textcolor{keywordflow}{return};
505 150 \textcolor{comment}{/*create response json object*/}
506 151 \textcolor{keyword}{struct }json\_object *res = json\_object\_new\_object();
507 152 \hyperlink{hs-helper_8cpp_ae83604a37134e7bdee3ce4f10bb0b47a}{hs\_add\_object\_to\_json\_object\_func}(res, \_\_FUNCTION\_\_, 2,
508 153 \hyperlink{homescreen_8cpp_aed1c5296a2e6d34945507a0fca17a376}{\_error}, ret);
509 154 afb\_req\_success\_f(request, res, \textcolor{stringliteral}{"homescreen binder subscribe."});
512 \index{homescreen.\+cpp@{homescreen.\+cpp}!tap\+\_\+shortcut@{tap\+\_\+shortcut}}
513 \index{tap\+\_\+shortcut@{tap\+\_\+shortcut}!homescreen.\+cpp@{homescreen.\+cpp}}
514 \subsubsection[{\texorpdfstring{tap\+\_\+shortcut(afb\+\_\+req\+\_\+t request)}{tap_shortcut(afb_req_t request)}}]{\setlength{\rightskip}{0pt plus 5cm}static void tap\+\_\+shortcut (
515 \begin{DoxyParamCaption}
516 \item[{afb\+\_\+req\+\_\+t}]{request}
517 \end{DoxyParamCaption}
518 )\hspace{0.3cm}{\ttfamily [static]}}\hypertarget{homescreen_8cpp_ab8abb667377924d5c073611738febbd3}{}\label{homescreen_8cpp_ab8abb667377924d5c073611738febbd3}
519 tap\+\_\+shortcut notify for homescreen When Shortcut area is tapped, notify these applciations
521 \subparagraph*{Parameters}
525 \item application\+\_\+id \+: application id
528 \subparagraph*{Return}
532 Definition at line 58 of file homescreen.\+cpp.
537 60 \hyperlink{include_2hmi-debug_8h_abc0d6e0760017d8ae48b836925b2ef15}{HMI\_NOTICE}(\textcolor{stringliteral}{"homescreen-service"},\textcolor{stringliteral}{"called."});
538 61 \textcolor{keywordtype}{int} ret = \hyperlink{homescreen_8cpp_a501f5bca8425de3171d46e0723f466ec}{g\_client\_manager}->\hyperlink{class_h_s___client_manager_a9910fc27c412530b5b9854b00bd16c07}{tap\_shortcut}(request);
539 62 \textcolor{keywordflow}{if} (ret != 0) \{
540 63 afb\_req\_fail\_f(request, \textcolor{stringliteral}{"failed"}, \textcolor{stringliteral}{"called %s, Unknown parameter"}, \_\_FUNCTION\_\_);
541 64 \textcolor{keywordflow}{return};
544 67 \textcolor{comment}{// response to HomeScreen}
545 68 \textcolor{keyword}{struct }json\_object *res = json\_object\_new\_object();
546 69 \hyperlink{hs-helper_8cpp_ae83604a37134e7bdee3ce4f10bb0b47a}{hs\_add\_object\_to\_json\_object\_func}(res, \_\_FUNCTION\_\_, 2,
547 70 \hyperlink{homescreen_8cpp_aed1c5296a2e6d34945507a0fca17a376}{\_error}, ret);
548 71 afb\_req\_success(request, res, \textcolor{stringliteral}{"afb\_event\_push event [tap\_shortcut]"});
551 \index{homescreen.\+cpp@{homescreen.\+cpp}!unsubscribe@{unsubscribe}}
552 \index{unsubscribe@{unsubscribe}!homescreen.\+cpp@{homescreen.\+cpp}}
553 \subsubsection[{\texorpdfstring{unsubscribe(afb\+\_\+req\+\_\+t request)}{unsubscribe(afb_req_t request)}}]{\setlength{\rightskip}{0pt plus 5cm}static void unsubscribe (
554 \begin{DoxyParamCaption}
555 \item[{afb\+\_\+req\+\_\+t}]{request}
556 \end{DoxyParamCaption}
557 )\hspace{0.3cm}{\ttfamily [static]}}\hypertarget{homescreen_8cpp_a3b162ab1856a8fa4284cb2c5c35ea748}{}\label{homescreen_8cpp_a3b162ab1856a8fa4284cb2c5c35ea748}
560 \subparagraph*{Parameters}
564 \item event \+: Event name. Event list is written in \hyperlink{libhomescreen_8cpp}{libhomescreen.\+cpp}
567 \subparagraph*{Return}
571 Definition at line 167 of file homescreen.\+cpp.
576 169 \hyperlink{include_2hmi-debug_8h_abc0d6e0760017d8ae48b836925b2ef15}{HMI\_NOTICE}(\textcolor{stringliteral}{"homescreen-service"},\textcolor{stringliteral}{"called."});
578 171 \textcolor{keywordtype}{int} ret = \hyperlink{homescreen_8cpp_a501f5bca8425de3171d46e0723f466ec}{g\_client\_manager}->\hyperlink{class_h_s___client_manager_ac86314afbb90116e2f02ce071166226e}{unsubscribe}(request);
579 172 \textcolor{keywordflow}{if}(ret) \{
580 173 afb\_req\_fail\_f(request, \textcolor{stringliteral}{"afb\_req\_unsubscribe failed"}, \textcolor{stringliteral}{"called %s."}, \_\_FUNCTION\_\_);
581 174 \textcolor{keywordflow}{return};
584 177 \textcolor{comment}{/*create response json object*/}
585 178 \textcolor{keyword}{struct }json\_object *res = json\_object\_new\_object();
586 179 \hyperlink{hs-helper_8cpp_ae83604a37134e7bdee3ce4f10bb0b47a}{hs\_add\_object\_to\_json\_object\_func}(res, \_\_FUNCTION\_\_, 2,
587 180 \hyperlink{homescreen_8cpp_aed1c5296a2e6d34945507a0fca17a376}{\_error}, ret);
588 181 afb\_req\_success\_f(request, res, \textcolor{stringliteral}{"homescreen binder unsubscribe success."});
593 \subsection{Variable Documentation}
594 \index{homescreen.\+cpp@{homescreen.\+cpp}!\+\_\+application\+\_\+id@{\+\_\+application\+\_\+id}}
595 \index{\+\_\+application\+\_\+id@{\+\_\+application\+\_\+id}!homescreen.\+cpp@{homescreen.\+cpp}}
596 \subsubsection[{\texorpdfstring{\+\_\+application\+\_\+id}{_application_id}}]{\setlength{\rightskip}{0pt plus 5cm}const char \+\_\+application\+\_\+id\mbox{[}$\,$\mbox{]} = \char`\"{}application\+\_\+id\char`\"{}}\hypertarget{homescreen_8cpp_a6a0e1db2562b442f8131ddf64b61d1ba}{}\label{homescreen_8cpp_a6a0e1db2562b442f8131ddf64b61d1ba}
599 Definition at line 28 of file homescreen.\+cpp.
601 \index{homescreen.\+cpp@{homescreen.\+cpp}!\+\_\+display\+\_\+message@{\+\_\+display\+\_\+message}}
602 \index{\+\_\+display\+\_\+message@{\+\_\+display\+\_\+message}!homescreen.\+cpp@{homescreen.\+cpp}}
603 \subsubsection[{\texorpdfstring{\+\_\+display\+\_\+message}{_display_message}}]{\setlength{\rightskip}{0pt plus 5cm}const char \+\_\+display\+\_\+message\mbox{[}$\,$\mbox{]} = \char`\"{}display\+\_\+message\char`\"{}}\hypertarget{homescreen_8cpp_abfd6c1d6f316fa952b11553f8f275e92}{}\label{homescreen_8cpp_abfd6c1d6f316fa952b11553f8f275e92}
606 Definition at line 29 of file homescreen.\+cpp.
608 \index{homescreen.\+cpp@{homescreen.\+cpp}!\+\_\+error@{\+\_\+error}}
609 \index{\+\_\+error@{\+\_\+error}!homescreen.\+cpp@{homescreen.\+cpp}}
610 \subsubsection[{\texorpdfstring{\+\_\+error}{_error}}]{\setlength{\rightskip}{0pt plus 5cm}const char \+\_\+error\mbox{[}$\,$\mbox{]} = \char`\"{}error\char`\"{}}\hypertarget{homescreen_8cpp_aed1c5296a2e6d34945507a0fca17a376}{}\label{homescreen_8cpp_aed1c5296a2e6d34945507a0fca17a376}
613 Definition at line 27 of file homescreen.\+cpp.
615 \index{homescreen.\+cpp@{homescreen.\+cpp}!\+\_\+reply\+\_\+message@{\+\_\+reply\+\_\+message}}
616 \index{\+\_\+reply\+\_\+message@{\+\_\+reply\+\_\+message}!homescreen.\+cpp@{homescreen.\+cpp}}
617 \subsubsection[{\texorpdfstring{\+\_\+reply\+\_\+message}{_reply_message}}]{\setlength{\rightskip}{0pt plus 5cm}const char \+\_\+reply\+\_\+message\mbox{[}$\,$\mbox{]} = \char`\"{}reply\+\_\+message\char`\"{}}\hypertarget{homescreen_8cpp_a79b0f0b481161527ccb80e83da143219}{}\label{homescreen_8cpp_a79b0f0b481161527ccb80e83da143219}
620 Definition at line 30 of file homescreen.\+cpp.
622 \index{homescreen.\+cpp@{homescreen.\+cpp}!afb\+Binding\+Export@{afb\+Binding\+Export}}
623 \index{afb\+Binding\+Export@{afb\+Binding\+Export}!homescreen.\+cpp@{homescreen.\+cpp}}
624 \subsubsection[{\texorpdfstring{afb\+Binding\+Export}{afbBindingExport}}]{\setlength{\rightskip}{0pt plus 5cm}const afb\+\_\+binding\+\_\+t afb\+Binding\+Export}\hypertarget{homescreen_8cpp_a970e7864dba290a0371534ad4961bcc5}{}\label{homescreen_8cpp_a970e7864dba290a0371534ad4961bcc5}
625 {\bfseries Initial value\+:}
628 .api = \textcolor{stringliteral}{"homescreen"},
629 .specification = NULL,
631 .verbs = \hyperlink{homescreen_8cpp_a01e06b6317acebc1d5686386b15f0872}{verbs},
632 .preinit = \hyperlink{homescreen_8cpp_ab3b1914acb53dcc038c1cf86c2975785}{preinit},
633 .init = \hyperlink{homescreen_8cpp_a5d7de3437d5dcb79fa035959d95878db}{init},
634 .onevent = \hyperlink{homescreen_8cpp_a60665935681c76d38b3833912109cdd3}{onevent}
639 Definition at line 394 of file homescreen.\+cpp.
641 \index{homescreen.\+cpp@{homescreen.\+cpp}!g\+\_\+client\+\_\+manager@{g\+\_\+client\+\_\+manager}}
642 \index{g\+\_\+client\+\_\+manager@{g\+\_\+client\+\_\+manager}!homescreen.\+cpp@{homescreen.\+cpp}}
643 \subsubsection[{\texorpdfstring{g\+\_\+client\+\_\+manager}{g_client_manager}}]{\setlength{\rightskip}{0pt plus 5cm}{\bf H\+S\+\_\+\+Client\+Manager}$\ast$ g\+\_\+client\+\_\+manager = {\bf H\+S\+\_\+\+Client\+Manager\+::instance}()\hspace{0.3cm}{\ttfamily [static]}}\hypertarget{homescreen_8cpp_a501f5bca8425de3171d46e0723f466ec}{}\label{homescreen_8cpp_a501f5bca8425de3171d46e0723f466ec}
646 Definition at line 32 of file homescreen.\+cpp.
648 \index{homescreen.\+cpp@{homescreen.\+cpp}!verbs@{verbs}}
649 \index{verbs@{verbs}!homescreen.\+cpp@{homescreen.\+cpp}}
650 \subsubsection[{\texorpdfstring{verbs}{verbs}}]{\setlength{\rightskip}{0pt plus 5cm}const afb\+\_\+verb\+\_\+t verbs\mbox{[}$\,$\mbox{]}\hspace{0.3cm}{\ttfamily [static]}}\hypertarget{homescreen_8cpp_a01e06b6317acebc1d5686386b15f0872}{}\label{homescreen_8cpp_a01e06b6317acebc1d5686386b15f0872}
651 {\bfseries Initial value\+:}
655 \{ .verb=\textcolor{stringliteral}{"ping"}, .callback=\hyperlink{homescreen_8cpp_ace65cfe6008848a3cd66581f536cc4c9}{pingSample} \},
656 \{ .verb=\textcolor{stringliteral}{"tap\_shortcut"}, .callback=\hyperlink{homescreen_8cpp_ab8abb667377924d5c073611738febbd3}{tap\_shortcut} \},
657 \{ .verb=\textcolor{stringliteral}{"showWindow"}, .callback=\hyperlink{homescreen_8cpp_ae475c69e7ca2a539ae0fb40a82963ac1}{showWindow} \},
658 \{ .verb=\textcolor{stringliteral}{"hideWindow"}, .callback=\hyperlink{homescreen_8cpp_a057c380ea38cfba4e2fbccc40fc21798}{hideWindow} \},
659 \{ .verb=\textcolor{stringliteral}{"replyShowWindow"}, .callback=\hyperlink{homescreen_8cpp_a710bcc84a61e11dbd4517def2764ff95}{replyShowWindow} \},
660 \{ .verb=\textcolor{stringliteral}{"on\_screen\_message"}, .callback=\hyperlink{homescreen_8cpp_a0df2b60ff6cd56b53dc87b36bfee2b91}{on\_screen\_message} \},
661 \{ .verb=\textcolor{stringliteral}{"on\_screen\_reply"}, .callback=\hyperlink{homescreen_8cpp_a7443596f6ddf459824ecd8138c681532}{on\_screen\_reply} \},
662 \{ .verb=\textcolor{stringliteral}{"subscribe"}, .callback=\hyperlink{homescreen_8cpp_a6e942ab2b7207d2aef9adce71a4574e8}{subscribe} \},
663 \{ .verb=\textcolor{stringliteral}{"unsubscribe"}, .callback=\hyperlink{homescreen_8cpp_a3b162ab1856a8fa4284cb2c5c35ea748}{unsubscribe} \},
664 \{ .verb=\textcolor{stringliteral}{"showNotification"}, .callback=\hyperlink{homescreen_8cpp_ad96a84455e8676abb4486e48ef67b1ad}{showNotification} \},
665 \{ .verb=\textcolor{stringliteral}{"showInformation"}, .callback=\hyperlink{homescreen_8cpp_a916c8dd31373222ee2b6ef89aca91978}{showInformation} \},
671 Definition at line 326 of file homescreen.\+cpp.