Panda3D
 All Classes Functions Variables Enumerations
awWebViewListener.cxx
1 // Filename: awWebView.cxx
2 // Created by: rurbino (12Oct09)
3 //
4 ////////////////////////////////////////////////////////////////////
5 //
6 // PANDA 3D SOFTWARE
7 // Copyright (c) Carnegie Mellon University. All rights reserved.
8 //
9 // All use of this software is subject to the terms of the revised BSD
10 // license. You should have received a copy of this license along
11 // with this source code in a file named "LICENSE."
12 //
13 ////////////////////////////////////////////////////////////////////
14 
15 #include "config_awesomium.h"
16 #include "awWebViewListener.h"
17 
18 TypeHandle AwWebViewListener::_type_handle;
19 
20 AwWebViewListener::
21 AwWebViewListener() {
22  awesomium_cat.info() << "constructing WebViewListner" ;
23 }
24 
25 void AwWebViewListener::onBeginNavigation(const std::string& url, const std::wstring& frameName){
26 }
27 
28 void AwWebViewListener::onBeginLoading(const std::string& url, const std::wstring& frameName, int statusCode, const std::wstring& mimeType) {
29  awesomium_cat.info() << "onBeginLoading" ;
30 }
31 
32  /**
33  * This event is fired when all loads have finished for a WebView.
34  */
36 }
37 
38  /**
39  * This event is fired when a Client callback has been invoked via Javascript from a page.
40  *
41  * @param name The name of the client callback that was invoked (specifically, "Client._this_name_here_(...)").
42  *
43  * @param args The arguments passed to the callback.
44  */
45 void AwWebViewListener::onCallback(const std::string& name, const Awesomium::JSArguments& args) {
46 }
47 
48  /**
49  * This event is fired when a page title is received.
50  *
51  * @param title The page title.
52  *
53  * @param frameName The name of the frame that this event originated from.
54  */
55 void AwWebViewListener::onReceiveTitle(const std::wstring& title, const std::wstring& frameName) {
56 }
57 
58  /**
59  * This event is fired when a tooltip has changed state.
60  *
61  * @param tooltip The tooltip text (or, is an empty string when the tooltip should disappear).
62  */
63 void AwWebViewListener::onChangeTooltip(const std::wstring& tooltip) {
64 }
65 
66  /**
67  * This event is fired when keyboard focus has changed.
68  *
69  * @param isFocused Whether or not the keyboard is currently focused.
70  */
72 }
73 
74  /**
75  * This event is fired when the target URL has changed. This is usually the result of
76  * hovering over a link on the page.
77  *
78  * @param url The updated target URL (or empty if the target URL is cleared).
79  */
80 void AwWebViewListener::onChangeTargetURL(const std::string& url) {
81 }
void onBeginLoading(const std::string &url, const std::wstring &frameName, int statusCode, const std::wstring &mimeType)
This event is fired when a WebView begins to actually receive data from a server. ...
void onChangeKeyboardFocus(bool isFocused)
This event is fired when keyboard focus has changed.
void onChangeTooltip(const std::wstring &tooltip)
This event is fired when a tooltip has changed state.
void onCallback(const std::string &name, const Awesomium::JSArguments &args)
This event is fired when a Client callback has been invoked via Javascript from a page...
void onChangeTargetURL(const std::string &url)
This event is fired when the target URL has changed.
void onBeginNavigation(const std::string &url, const std::wstring &frameName)
This event is fired when a WebView begins navigating to a new URL.
TypeHandle is the identifier used to differentiate C++ class types.
Definition: typeHandle.h:85
void onFinishLoading()
This event is fired when all loads have finished for a WebView.
void onReceiveTitle(const std::wstring &title, const std::wstring &frameName)
This event is fired when a page title is received.