X-Git-Url: https://gerrit.automotivelinux.org/gerrit/gitweb?a=blobdiff_plain;f=doc%2Fapi-ref%2Flatex%2Fdf%2Fdac%2Ftest_8cpp.tex;h=92ef1dff3e73ff0ec0a640e5d1cdd700b9584b5c;hb=599de8d3f35cb0fe56c7e27591862d61944b456b;hp=cbc5bcedadddf942d505f35f3a8fa18237883c7b;hpb=26ec25e2f9271396328c208ae1a256fdf1a92c91;p=apps%2Fagl-service-homescreen.git diff --git a/doc/api-ref/latex/df/dac/test_8cpp.tex b/doc/api-ref/latex/df/dac/test_8cpp.tex index cbc5bce..92ef1df 100644 --- a/doc/api-ref/latex/df/dac/test_8cpp.tex +++ b/doc/api-ref/latex/df/dac/test_8cpp.tex @@ -1,6 +1,6 @@ \hypertarget{test_8cpp}{}\section{libhomescreen/test.cpp File Reference} \label{test_8cpp}\index{libhomescreen/test.\+cpp@{libhomescreen/test.\+cpp}} -{\ttfamily \#include $<$libhomescreen/libhomescreen.\+hpp$>$}\newline +{\ttfamily \#include $<$libhomescreen.\+hpp$>$}\newline {\ttfamily \#include $<$iostream$>$}\newline {\ttfamily \#include $<$glib-\/2.\+0/glib.\+h$>$}\newline {\ttfamily \#include $<$fcntl.\+h$>$}\newline @@ -143,26 +143,35 @@ Definition at line 117 of file test.\+cpp. 160 \textcolor{comment}{// hs->subscribe(event\_list[1]);} 161 162 \hyperlink{test_8cpp_a529acbd1fed9d98a587edfa62309fa8d}{hs}->\hyperlink{class_lib_home_screen_ab1b0e08bf35415de9064afed899e9f85}{set\_event\_handler}(\hyperlink{class_lib_home_screen_a82616c91ac211d2ad08e709b524bf154a4b0a82d501e4db5fbfe25c254c92896f}{LibHomeScreen::Event\_TapShortcut} - , [](\textcolor{keyword}{const} \textcolor{keywordtype}{char}* application\_name)\{ -163 cout << \textcolor{stringliteral}{"set\_event\_handler Event\_TapShortcut application\_name = "} << application\_name << endl; -164 \}); -165 -166 \hyperlink{test_8cpp_a529acbd1fed9d98a587edfa62309fa8d}{hs}->\hyperlink{class_lib_home_screen_ab1b0e08bf35415de9064afed899e9f85}{set\_event\_handler}(\hyperlink{class_lib_home_screen_a82616c91ac211d2ad08e709b524bf154aea56fa32a124a8ddcbea127755280a1d}{LibHomeScreen::Event\_OnScreenMessage} - , [](\textcolor{keyword}{const} \textcolor{keywordtype}{char}* display\_message)\{ -167 cout << \textcolor{stringliteral}{"set\_event\_handler Event\_OnScreenMessage display\_message = "} << display\_message << endl; -168 \}); -169 -170 -171 \textcolor{keywordflow}{if} (ret < 0) \{ -172 printf(\textcolor{stringliteral}{"failed to create event loop"}); -173 \textcolor{keywordflow}{return} -1; -174 \} -175 \hyperlink{test_8cpp_a529acbd1fed9d98a587edfa62309fa8d}{hs}->\hyperlink{class_lib_home_screen_a32d3282898d0f04151c24b4103511e00}{runEventloop}(); -176 -177 \hyperlink{test_8cpp_aa9b3c43c212b49edee82ac30a11aa255}{call\_test}(); -178 -179 \textcolor{keywordflow}{return} 0; -180 \} + , [](json\_object *\textcolor{keywordtype}{object})\{ +163 \textcolor{keyword}{const} \textcolor{keywordtype}{char} *application\_name = json\_object\_get\_string( +164 json\_object\_object\_get(\textcolor{keywordtype}{object}, \textcolor{stringliteral}{"application\_name"})); +165 cout << \textcolor{stringliteral}{"set\_event\_handler Event\_TapShortcut application\_name = "} << application\_name << endl; +166 \}); +167 +168 \hyperlink{test_8cpp_a529acbd1fed9d98a587edfa62309fa8d}{hs}->\hyperlink{class_lib_home_screen_ab1b0e08bf35415de9064afed899e9f85}{set\_event\_handler}(\hyperlink{class_lib_home_screen_a82616c91ac211d2ad08e709b524bf154aea56fa32a124a8ddcbea127755280a1d}{LibHomeScreen::Event\_OnScreenMessage} + , [](json\_object *\textcolor{keywordtype}{object})\{ +169 \textcolor{keyword}{const} \textcolor{keywordtype}{char} *display\_message = json\_object\_get\_string( +170 json\_object\_object\_get(\textcolor{keywordtype}{object}, \textcolor{stringliteral}{"display\_message"})); +171 cout << \textcolor{stringliteral}{"set\_event\_handler Event\_OnScreenMessage display\_message = "} << display\_message << endl; +172 \}); +173 +174 \hyperlink{test_8cpp_a529acbd1fed9d98a587edfa62309fa8d}{hs}->\hyperlink{class_lib_home_screen_ab1b0e08bf35415de9064afed899e9f85}{set\_event\_handler}(\hyperlink{class_lib_home_screen_a82616c91ac211d2ad08e709b524bf154acae91db4efc2394fd701f581d277a3fd}{LibHomeScreen::Event\_OnScreenReply} + , [](json\_object *\textcolor{keywordtype}{object})\{ +175 \textcolor{keyword}{const} \textcolor{keywordtype}{char} *reply\_message = json\_object\_get\_string( +176 json\_object\_object\_get(\textcolor{keywordtype}{object}, \textcolor{stringliteral}{"reply\_message"})); +177 cout << \textcolor{stringliteral}{"set\_event\_handler Event\_OnScreenReply reply\_message = "} << reply\_message << endl; +178 \}); +179 +180 \textcolor{keywordflow}{if} (ret < 0) \{ +181 printf(\textcolor{stringliteral}{"failed to create event loop"}); +182 \textcolor{keywordflow}{return} -1; +183 \} +184 +185 \hyperlink{test_8cpp_aa9b3c43c212b49edee82ac30a11aa255}{call\_test}(); +186 +187 \textcolor{keywordflow}{return} 0; +188 \} \end{DoxyCode} \mbox{\Hypertarget{test_8cpp_a6a2874c419fe5936fcccadc7e6cf268e}\label{test_8cpp_a6a2874c419fe5936fcccadc7e6cf268e}} \index{test.\+cpp@{test.\+cpp}!on\+Ev@{on\+Ev}}