summaryrefslogtreecommitdiffstats
path: root/doxygen/latex/class_javascript_interface.tex
blob: d21fb313429d2941e0a293f08e0f28c5a20d402d (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
\hypertarget{class_javascript_interface}{
\section{JavascriptInterface Class Reference}
\label{class_javascript_interface}\index{JavascriptInterface@{JavascriptInterface}}
}


{\ttfamily \#include $<$javascriptinterface.h$>$}

\subsection*{Public Slots}
\begin{DoxyCompactItemize}
\item 
void \hyperlink{class_javascript_interface_a31a97a62ca25da9282892c5aa498b988}{attachToDOM} ()
\item 
void \hyperlink{class_javascript_interface_a1c694b7dea80043f98492aa79011cef8}{startDownload} (const QString \&filename)
\item 
void \hyperlink{class_javascript_interface_a191733bdc7c0a52263ee2e4512078d60}{setCallbackOnFinished} (const QString \&function)
\item 
const QString \hyperlink{class_javascript_interface_a2d230282a975bf0a6e52ca0abb3699f5}{getSysInfo} (const QString \&info)
\item 
void \hyperlink{class_javascript_interface_a6d7549013046231a486c32935a7e5199}{quit} ()
\item 
void \hyperlink{class_javascript_interface_a5c641761dee8bd022a22da1cedf00e72}{shutDown} ()
\item 
void \hyperlink{class_javascript_interface_acbc3154b7f9559fa70140f6eed83c55b}{reboot} ()
\item 
void \hyperlink{class_javascript_interface_a7080fe5a88242cad71aa6b6c30e3d452}{callbackOnFinished} ()
\item 
void \hyperlink{class_javascript_interface_aca4e27242499abf22f6f38e69ba98bf0}{updateProgressBar} (const int \&percent, const double \&speed, const QString \&unit)
\item 
void \hyperlink{class_javascript_interface_a153e4b79fd6709ea2e3e844f06cf1c98}{downloadInfo} (const QString \&filename, const double \&filesize)
\item 
void \hyperlink{class_javascript_interface_a664939fd000ac0b342841dfff8640466}{notify} (const QString \&msg)
\item 
void \hyperlink{class_javascript_interface_a89ad0da59f6494aacd62a18be21dd780}{trigger} ()
\end{DoxyCompactItemize}
\subsection*{Signals}
\begin{DoxyCompactItemize}
\item 
void \hyperlink{class_javascript_interface_a3c7025b29fb18de496ca0cef211ef17b}{requestFile} (const QString \&filename)
\item 
void \hyperlink{class_javascript_interface_a7d14cbe58b36a24620428b1b6daa6ee4}{quitFbgui} ()
\item 
void \hyperlink{class_javascript_interface_a16dbd5474d3a356a1e92bdf9b6c6f519}{shutDownClient} ()
\item 
void \hyperlink{class_javascript_interface_a76c7813e3c89fb841d6f3bb1c38479f6}{rebootClient} ()
\end{DoxyCompactItemize}
\subsection*{Public Member Functions}
\begin{DoxyCompactItemize}
\item 
\hyperlink{class_javascript_interface_acbfd4c0a48c944f2eca15ca02517f503}{JavascriptInterface} (QWebFrame $\ast$parent)
\item 
\hyperlink{class_javascript_interface_a1dfae69ba64e8c279ce57949ba92ef0c}{$\sim$JavascriptInterface} ()
\end{DoxyCompactItemize}


\subsection{Constructor \& Destructor Documentation}
\hypertarget{class_javascript_interface_acbfd4c0a48c944f2eca15ca02517f503}{
\index{JavascriptInterface@{JavascriptInterface}!JavascriptInterface@{JavascriptInterface}}
\index{JavascriptInterface@{JavascriptInterface}!JavascriptInterface@{JavascriptInterface}}
\subsubsection[{JavascriptInterface}]{\setlength{\rightskip}{0pt plus 5cm}JavascriptInterface::JavascriptInterface (
\begin{DoxyParamCaption}
\item[{QWebFrame $\ast$}]{parent}
\end{DoxyParamCaption}
)}}
\label{class_javascript_interface_acbfd4c0a48c944f2eca15ca02517f503}
A constructor.


\begin{DoxyParams}{Parameters}
{\em parent} & Is of type QWebFrame. \\
\hline
\end{DoxyParams}
\hypertarget{class_javascript_interface_a1dfae69ba64e8c279ce57949ba92ef0c}{
\index{JavascriptInterface@{JavascriptInterface}!$\sim$JavascriptInterface@{$\sim$JavascriptInterface}}
\index{$\sim$JavascriptInterface@{$\sim$JavascriptInterface}!JavascriptInterface@{JavascriptInterface}}
\subsubsection[{$\sim$JavascriptInterface}]{\setlength{\rightskip}{0pt plus 5cm}JavascriptInterface::$\sim$JavascriptInterface (
\begin{DoxyParamCaption}
{}
\end{DoxyParamCaption}
)}}
\label{class_javascript_interface_a1dfae69ba64e8c279ce57949ba92ef0c}
An empty destructor. 

\subsection{Member Function Documentation}
\hypertarget{class_javascript_interface_a31a97a62ca25da9282892c5aa498b988}{
\index{JavascriptInterface@{JavascriptInterface}!attachToDOM@{attachToDOM}}
\index{attachToDOM@{attachToDOM}!JavascriptInterface@{JavascriptInterface}}
\subsubsection[{attachToDOM}]{\setlength{\rightskip}{0pt plus 5cm}void JavascriptInterface::attachToDOM (
\begin{DoxyParamCaption}
{}
\end{DoxyParamCaption}
)\hspace{0.3cm}{\ttfamily  \mbox{[}slot\mbox{]}}}}
\label{class_javascript_interface_a31a97a62ca25da9282892c5aa498b988}
Attaches an instance of this class to the DOM of the HTML page.

Attaches an instance of this class to the DOM of the HTML page. This enables the possibility to call slots/methods of this class in JavaScript functions of HTML page. It also calls the JavascriptInterface::loadJQuery() method.

\begin{DoxySeeAlso}{See also}
JavascriptInterface::loadJQuery() 
\end{DoxySeeAlso}
\hypertarget{class_javascript_interface_a7080fe5a88242cad71aa6b6c30e3d452}{
\index{JavascriptInterface@{JavascriptInterface}!callbackOnFinished@{callbackOnFinished}}
\index{callbackOnFinished@{callbackOnFinished}!JavascriptInterface@{JavascriptInterface}}
\subsubsection[{callbackOnFinished}]{\setlength{\rightskip}{0pt plus 5cm}void JavascriptInterface::callbackOnFinished (
\begin{DoxyParamCaption}
{}
\end{DoxyParamCaption}
)\hspace{0.3cm}{\ttfamily  \mbox{[}slot\mbox{]}}}}
\label{class_javascript_interface_a7080fe5a88242cad71aa6b6c30e3d452}
Sets a callback function for when downloads are finished (will be called when the queue is empty). \hypertarget{class_javascript_interface_a153e4b79fd6709ea2e3e844f06cf1c98}{
\index{JavascriptInterface@{JavascriptInterface}!downloadInfo@{downloadInfo}}
\index{downloadInfo@{downloadInfo}!JavascriptInterface@{JavascriptInterface}}
\subsubsection[{downloadInfo}]{\setlength{\rightskip}{0pt plus 5cm}void JavascriptInterface::downloadInfo (
\begin{DoxyParamCaption}
\item[{const QString \&}]{filename, }
\item[{const double \&}]{filesize}
\end{DoxyParamCaption}
)\hspace{0.3cm}{\ttfamily  \mbox{[}slot\mbox{]}}}}
\label{class_javascript_interface_a153e4b79fd6709ea2e3e844f06cf1c98}
This method delivers some informations about the downloading file.

This method delivers some informations about the downloading file.

\begin{Desc}
\item[\hyperlink{todo__todo000002}{Todo}]add some more informations \end{Desc}
\hypertarget{class_javascript_interface_a2d230282a975bf0a6e52ca0abb3699f5}{
\index{JavascriptInterface@{JavascriptInterface}!getSysInfo@{getSysInfo}}
\index{getSysInfo@{getSysInfo}!JavascriptInterface@{JavascriptInterface}}
\subsubsection[{getSysInfo}]{\setlength{\rightskip}{0pt plus 5cm}const QString JavascriptInterface::getSysInfo (
\begin{DoxyParamCaption}
\item[{const QString \&}]{info}
\end{DoxyParamCaption}
)\hspace{0.3cm}{\ttfamily  \mbox{[}slot\mbox{]}}}}
\label{class_javascript_interface_a2d230282a975bf0a6e52ca0abb3699f5}
This method delivers system informations.

This method delivers system informations. Type of informations, are defined by the parameter. The output of this method depends on the parameter. Can be called from inside a JavaScript function of the HTML page.


\begin{DoxyParams}{Parameters}
{\em infoName} & Is of type QString. Defines which method will be called. Possible values are:
\begin{DoxyItemize}
\item mac
\item ip
\item mbserial
\item usb
\end{DoxyItemize}\\
\hline
\end{DoxyParams}
\begin{DoxyReturn}{Returns}
QString the output of the called method or \char`\"{}info\_\-error\char`\"{} if an error occurred (e. g. invalid parameter).
\end{DoxyReturn}
\begin{DoxySeeAlso}{See also}
\hyperlink{class_sys_info_a0309806bf95c06b6744cbd367a038ccb}{SysInfo::getInfo(const QString\& infoName)} 
\end{DoxySeeAlso}


Here is the call graph for this function:\nopagebreak
\begin{figure}[H]
\begin{center}
\leavevmode
\includegraphics[width=356pt]{class_javascript_interface_a2d230282a975bf0a6e52ca0abb3699f5_cgraph}
\end{center}
\end{figure}


\hypertarget{class_javascript_interface_a664939fd000ac0b342841dfff8640466}{
\index{JavascriptInterface@{JavascriptInterface}!notify@{notify}}
\index{notify@{notify}!JavascriptInterface@{JavascriptInterface}}
\subsubsection[{notify}]{\setlength{\rightskip}{0pt plus 5cm}void JavascriptInterface::notify (
\begin{DoxyParamCaption}
\item[{const QString \&}]{msg}
\end{DoxyParamCaption}
)\hspace{0.3cm}{\ttfamily  \mbox{[}slot\mbox{]}}}}
\label{class_javascript_interface_a664939fd000ac0b342841dfff8640466}
This method sends out messages to Javascript. A corresponding function must be implemented on the webpage to receive these. \hypertarget{class_javascript_interface_a6d7549013046231a486c32935a7e5199}{
\index{JavascriptInterface@{JavascriptInterface}!quit@{quit}}
\index{quit@{quit}!JavascriptInterface@{JavascriptInterface}}
\subsubsection[{quit}]{\setlength{\rightskip}{0pt plus 5cm}void JavascriptInterface::quit (
\begin{DoxyParamCaption}
{}
\end{DoxyParamCaption}
)\hspace{0.3cm}{\ttfamily  \mbox{[}slot\mbox{]}}}}
\label{class_javascript_interface_a6d7549013046231a486c32935a7e5199}
This method quits the whole program.

This method quits the whole program. Can be called from inside a JavaScript function of the HTML page. Emits \hyperlink{class_javascript_interface_a7d14cbe58b36a24620428b1b6daa6ee4}{JavascriptInterface::quitFbgui()} signal 

Here is the call graph for this function:\nopagebreak
\begin{figure}[H]
\begin{center}
\leavevmode
\includegraphics[width=384pt]{class_javascript_interface_a6d7549013046231a486c32935a7e5199_cgraph}
\end{center}
\end{figure}


\hypertarget{class_javascript_interface_a7d14cbe58b36a24620428b1b6daa6ee4}{
\index{JavascriptInterface@{JavascriptInterface}!quitFbgui@{quitFbgui}}
\index{quitFbgui@{quitFbgui}!JavascriptInterface@{JavascriptInterface}}
\subsubsection[{quitFbgui}]{\setlength{\rightskip}{0pt plus 5cm}void JavascriptInterface::quitFbgui (
\begin{DoxyParamCaption}
{}
\end{DoxyParamCaption}
)\hspace{0.3cm}{\ttfamily  \mbox{[}signal\mbox{]}}}}
\label{class_javascript_interface_a7d14cbe58b36a24620428b1b6daa6ee4}


Here is the caller graph for this function:\nopagebreak
\begin{figure}[H]
\begin{center}
\leavevmode
\includegraphics[width=384pt]{class_javascript_interface_a7d14cbe58b36a24620428b1b6daa6ee4_icgraph}
\end{center}
\end{figure}


\hypertarget{class_javascript_interface_acbc3154b7f9559fa70140f6eed83c55b}{
\index{JavascriptInterface@{JavascriptInterface}!reboot@{reboot}}
\index{reboot@{reboot}!JavascriptInterface@{JavascriptInterface}}
\subsubsection[{reboot}]{\setlength{\rightskip}{0pt plus 5cm}void JavascriptInterface::reboot (
\begin{DoxyParamCaption}
{}
\end{DoxyParamCaption}
)\hspace{0.3cm}{\ttfamily  \mbox{[}slot\mbox{]}}}}
\label{class_javascript_interface_acbc3154b7f9559fa70140f6eed83c55b}
This method performs a reboot of the client.

This method performs a reboot of the client. Emits the \hyperlink{class_javascript_interface_a76c7813e3c89fb841d6f3bb1c38479f6}{JavascriptInterface::rebootClient()} signal. It is connected with the fbgui::performReboot() method.

\begin{DoxySeeAlso}{See also}
fbgui::performReboot() 
\end{DoxySeeAlso}


Here is the call graph for this function:\nopagebreak
\begin{figure}[H]
\begin{center}
\leavevmode
\includegraphics[width=400pt]{class_javascript_interface_acbc3154b7f9559fa70140f6eed83c55b_cgraph}
\end{center}
\end{figure}


\hypertarget{class_javascript_interface_a76c7813e3c89fb841d6f3bb1c38479f6}{
\index{JavascriptInterface@{JavascriptInterface}!rebootClient@{rebootClient}}
\index{rebootClient@{rebootClient}!JavascriptInterface@{JavascriptInterface}}
\subsubsection[{rebootClient}]{\setlength{\rightskip}{0pt plus 5cm}void JavascriptInterface::rebootClient (
\begin{DoxyParamCaption}
{}
\end{DoxyParamCaption}
)\hspace{0.3cm}{\ttfamily  \mbox{[}signal\mbox{]}}}}
\label{class_javascript_interface_a76c7813e3c89fb841d6f3bb1c38479f6}


Here is the caller graph for this function:\nopagebreak
\begin{figure}[H]
\begin{center}
\leavevmode
\includegraphics[width=400pt]{class_javascript_interface_a76c7813e3c89fb841d6f3bb1c38479f6_icgraph}
\end{center}
\end{figure}


\hypertarget{class_javascript_interface_a3c7025b29fb18de496ca0cef211ef17b}{
\index{JavascriptInterface@{JavascriptInterface}!requestFile@{requestFile}}
\index{requestFile@{requestFile}!JavascriptInterface@{JavascriptInterface}}
\subsubsection[{requestFile}]{\setlength{\rightskip}{0pt plus 5cm}void JavascriptInterface::requestFile (
\begin{DoxyParamCaption}
\item[{const QString \&}]{filename}
\end{DoxyParamCaption}
)\hspace{0.3cm}{\ttfamily  \mbox{[}signal\mbox{]}}}}
\label{class_javascript_interface_a3c7025b29fb18de496ca0cef211ef17b}


Here is the caller graph for this function:\nopagebreak
\begin{figure}[H]
\begin{center}
\leavevmode
\includegraphics[width=400pt]{class_javascript_interface_a3c7025b29fb18de496ca0cef211ef17b_icgraph}
\end{center}
\end{figure}


\hypertarget{class_javascript_interface_a191733bdc7c0a52263ee2e4512078d60}{
\index{JavascriptInterface@{JavascriptInterface}!setCallbackOnFinished@{setCallbackOnFinished}}
\index{setCallbackOnFinished@{setCallbackOnFinished}!JavascriptInterface@{JavascriptInterface}}
\subsubsection[{setCallbackOnFinished}]{\setlength{\rightskip}{0pt plus 5cm}void JavascriptInterface::setCallbackOnFinished (
\begin{DoxyParamCaption}
\item[{const QString \&}]{function}
\end{DoxyParamCaption}
)\hspace{0.3cm}{\ttfamily  \mbox{[}slot\mbox{]}}}}
\label{class_javascript_interface_a191733bdc7c0a52263ee2e4512078d60}
This method start a download.

This method start a download. Can be called from inside a JavaScript function of the HTML page.

\begin{Desc}
\item[\hyperlink{todo__todo000001}{Todo}]add some more informations \end{Desc}
\hypertarget{class_javascript_interface_a5c641761dee8bd022a22da1cedf00e72}{
\index{JavascriptInterface@{JavascriptInterface}!shutDown@{shutDown}}
\index{shutDown@{shutDown}!JavascriptInterface@{JavascriptInterface}}
\subsubsection[{shutDown}]{\setlength{\rightskip}{0pt plus 5cm}void JavascriptInterface::shutDown (
\begin{DoxyParamCaption}
{}
\end{DoxyParamCaption}
)\hspace{0.3cm}{\ttfamily  \mbox{[}slot\mbox{]}}}}
\label{class_javascript_interface_a5c641761dee8bd022a22da1cedf00e72}
This method performs a shutdown of the client.

This method performs a shutdown of the client. Emits the \hyperlink{class_javascript_interface_a16dbd5474d3a356a1e92bdf9b6c6f519}{JavascriptInterface::shutDownClient()} signal.It is connected with the fbgui::performShutDown() method.

\begin{DoxySeeAlso}{See also}
fbgui::performShutDown() 
\end{DoxySeeAlso}


Here is the call graph for this function:\nopagebreak
\begin{figure}[H]
\begin{center}
\leavevmode
\includegraphics[width=400pt]{class_javascript_interface_a5c641761dee8bd022a22da1cedf00e72_cgraph}
\end{center}
\end{figure}


\hypertarget{class_javascript_interface_a16dbd5474d3a356a1e92bdf9b6c6f519}{
\index{JavascriptInterface@{JavascriptInterface}!shutDownClient@{shutDownClient}}
\index{shutDownClient@{shutDownClient}!JavascriptInterface@{JavascriptInterface}}
\subsubsection[{shutDownClient}]{\setlength{\rightskip}{0pt plus 5cm}void JavascriptInterface::shutDownClient (
\begin{DoxyParamCaption}
{}
\end{DoxyParamCaption}
)\hspace{0.3cm}{\ttfamily  \mbox{[}signal\mbox{]}}}}
\label{class_javascript_interface_a16dbd5474d3a356a1e92bdf9b6c6f519}


Here is the caller graph for this function:\nopagebreak
\begin{figure}[H]
\begin{center}
\leavevmode
\includegraphics[width=400pt]{class_javascript_interface_a16dbd5474d3a356a1e92bdf9b6c6f519_icgraph}
\end{center}
\end{figure}


\hypertarget{class_javascript_interface_a1c694b7dea80043f98492aa79011cef8}{
\index{JavascriptInterface@{JavascriptInterface}!startDownload@{startDownload}}
\index{startDownload@{startDownload}!JavascriptInterface@{JavascriptInterface}}
\subsubsection[{startDownload}]{\setlength{\rightskip}{0pt plus 5cm}void JavascriptInterface::startDownload (
\begin{DoxyParamCaption}
\item[{const QString \&}]{filename}
\end{DoxyParamCaption}
)\hspace{0.3cm}{\ttfamily  \mbox{[}slot\mbox{]}}}}
\label{class_javascript_interface_a1c694b7dea80043f98492aa79011cef8}
This method start a download.

This method start a download. Can be called from inside a JavaScript function of the HTML page. Emits the JavascriptInterface::requestFile(const QString) signal. 

Here is the call graph for this function:\nopagebreak
\begin{figure}[H]
\begin{center}
\leavevmode
\includegraphics[width=400pt]{class_javascript_interface_a1c694b7dea80043f98492aa79011cef8_cgraph}
\end{center}
\end{figure}


\hypertarget{class_javascript_interface_a89ad0da59f6494aacd62a18be21dd780}{
\index{JavascriptInterface@{JavascriptInterface}!trigger@{trigger}}
\index{trigger@{trigger}!JavascriptInterface@{JavascriptInterface}}
\subsubsection[{trigger}]{\setlength{\rightskip}{0pt plus 5cm}void JavascriptInterface::trigger (
\begin{DoxyParamCaption}
{}
\end{DoxyParamCaption}
)\hspace{0.3cm}{\ttfamily  \mbox{[}slot\mbox{]}}}}
\label{class_javascript_interface_a89ad0da59f6494aacd62a18be21dd780}
This method triggers the URL load $\ast$FOR DEBUGGING/TESTING PURPOSES$\ast$ \hypertarget{class_javascript_interface_aca4e27242499abf22f6f38e69ba98bf0}{
\index{JavascriptInterface@{JavascriptInterface}!updateProgressBar@{updateProgressBar}}
\index{updateProgressBar@{updateProgressBar}!JavascriptInterface@{JavascriptInterface}}
\subsubsection[{updateProgressBar}]{\setlength{\rightskip}{0pt plus 5cm}void JavascriptInterface::updateProgressBar (
\begin{DoxyParamCaption}
\item[{const int \&}]{percent, }
\item[{const double \&}]{speed, }
\item[{const QString \&}]{unit}
\end{DoxyParamCaption}
)\hspace{0.3cm}{\ttfamily  \mbox{[}slot\mbox{]}}}}
\label{class_javascript_interface_aca4e27242499abf22f6f38e69ba98bf0}
This method updates the progress bar.

This method calls a Javascript function to update the progress bar of the download. Javascript must have a function called \char`\"{}updateProgress\char`\"{} to receive this information.

\begin{Desc}
\item[\hyperlink{todo__todo000003}{Todo}]add some more informations \end{Desc}


The documentation for this class was generated from the following files:\begin{DoxyCompactItemize}
\item 
/home/niklas/workspace/fbgui/src/\hyperlink{javascriptinterface_8h}{javascriptinterface.h}\item 
/home/niklas/workspace/fbgui/src/\hyperlink{javascriptinterface_8cpp}{javascriptinterface.cpp}\end{DoxyCompactItemize}