diff options
author | Adam Hooper <adamh@src.gnome.org> | 2004-03-26 03:09:44 +0800 |
---|---|---|
committer | Adam Hooper <adamh@src.gnome.org> | 2004-03-26 03:09:44 +0800 |
commit | 1a84ef9f76056a2805a837bb45209a3746cdb521 (patch) | |
tree | d0638c70653ae50d2ec4fae814d7fd4e2353e4f6 /embed/mozilla | |
parent | 867777faceb7b4eba5b58b4e8edb23edfeeb8287 (diff) | |
download | gsoc2013-epiphany-1a84ef9f76056a2805a837bb45209a3746cdb521.tar gsoc2013-epiphany-1a84ef9f76056a2805a837bb45209a3746cdb521.tar.gz gsoc2013-epiphany-1a84ef9f76056a2805a837bb45209a3746cdb521.tar.bz2 gsoc2013-epiphany-1a84ef9f76056a2805a837bb45209a3746cdb521.tar.lz gsoc2013-epiphany-1a84ef9f76056a2805a837bb45209a3746cdb521.tar.xz gsoc2013-epiphany-1a84ef9f76056a2805a837bb45209a3746cdb521.tar.zst gsoc2013-epiphany-1a84ef9f76056a2805a837bb45209a3746cdb521.zip |
Documented EphyEmbed
Diffstat (limited to 'embed/mozilla')
-rw-r--r-- | embed/mozilla/EphyBrowser.cpp | 29 | ||||
-rw-r--r-- | embed/mozilla/EphyBrowser.h | 7 | ||||
-rw-r--r-- | embed/mozilla/mozilla-embed.cpp | 10 |
3 files changed, 5 insertions, 41 deletions
diff --git a/embed/mozilla/EphyBrowser.cpp b/embed/mozilla/EphyBrowser.cpp index c04183247..d09bfca5e 100644 --- a/embed/mozilla/EphyBrowser.cpp +++ b/embed/mozilla/EphyBrowser.cpp @@ -59,7 +59,6 @@ #include "nsIDOMEventTarget.h" #include "nsIDOMNode.h" #include "nsIDOMElement.h" -#include "nsIDOMPopupBlockedEvent.h" #include "nsIDocShellTreeItem.h" #include "nsIDocShellTreeNode.h" #include "nsIDocShellTreeOwner.h" @@ -170,23 +169,9 @@ EphyFaviconEventListener::HandleEvent(nsIDOMEvent* aDOMEvent) return NS_OK; } -NS_IMETHODIMP -EphyPopupEventListener::HandleEvent(nsIDOMEvent* aDOMEvent) -{ - nsCOMPtr<nsIDOMPopupBlockedEvent> popupEvent = - do_QueryInterface(aDOMEvent); - if (popupEvent) - { - g_signal_emit_by_name (mOwner, "ge_popup_blocked"); - } - - return NS_OK; -} - EphyBrowser::EphyBrowser () { mFaviconEventListener = nsnull; - mPopupEventListener = nsnull; mEventReceiver = nsnull; mInitialized = PR_FALSE; } @@ -216,15 +201,9 @@ nsresult EphyBrowser::Init (GtkMozEmbed *mozembed) mFaviconEventListener = new EphyFaviconEventListener(); if (!mFaviconEventListener) return NS_ERROR_OUT_OF_MEMORY; - mPopupEventListener = new EphyPopupEventListener(); - if (!mPopupEventListener) return NS_ERROR_OUT_OF_MEMORY; - rv = mFaviconEventListener->Init (EPHY_EMBED (mozembed)); NS_ENSURE_SUCCESS (rv, NS_ERROR_FAILURE); - rv = mPopupEventListener->Init (EPHY_EMBED (mozembed)); - NS_ENSURE_SUCCESS (rv, NS_ERROR_FAILURE); - rv = GetListener(); NS_ENSURE_SUCCESS (rv, NS_ERROR_FAILURE); @@ -270,10 +249,6 @@ EphyBrowser::AttachListeners(void) mFaviconEventListener, PR_FALSE); NS_ENSURE_SUCCESS (rv, NS_ERROR_FAILURE); - rv = target->AddEventListener(NS_LITERAL_STRING("DOMPopupBlocked"), - mPopupEventListener, PR_FALSE); - NS_ENSURE_SUCCESS (rv, NS_ERROR_FAILURE); - return NS_OK; } @@ -291,10 +266,6 @@ EphyBrowser::DetachListeners(void) mFaviconEventListener, PR_FALSE); NS_ENSURE_SUCCESS (rv, NS_ERROR_FAILURE); - rv = target->RemoveEventListener(NS_LITERAL_STRING("DOMPopupBlocked"), - mPopupEventListener, PR_FALSE); - NS_ENSURE_SUCCESS (rv, NS_ERROR_FAILURE); - return NS_OK; } diff --git a/embed/mozilla/EphyBrowser.h b/embed/mozilla/EphyBrowser.h index 0e4d7815d..6569cd502 100644 --- a/embed/mozilla/EphyBrowser.h +++ b/embed/mozilla/EphyBrowser.h @@ -67,12 +67,6 @@ private: nsresult HandleFaviconLink (nsIDOMNode *node); }; -class EphyPopupEventListener : public EphyEventListener -{ -public: - NS_IMETHOD HandleEvent(nsIDOMEvent* aEvent); -}; - class EphyBrowser { public: @@ -129,7 +123,6 @@ private: nsCOMPtr<nsIDOMEventReceiver> mEventReceiver; nsCOMPtr<nsIDOMWindow> mDOMWindow; EphyFaviconEventListener *mFaviconEventListener; - EphyPopupEventListener *mPopupEventListener; PRBool mInitialized; nsresult GetListener (void); diff --git a/embed/mozilla/mozilla-embed.cpp b/embed/mozilla/mozilla-embed.cpp index 70a17bbb6..e02abad73 100644 --- a/embed/mozilla/mozilla-embed.cpp +++ b/embed/mozilla/mozilla-embed.cpp @@ -190,7 +190,7 @@ impl_activate (EphyEmbed *embed) static void impl_find_set_properties (EphyEmbed *embed, - char *search_string, + const char *search_string, gboolean case_sensitive, gboolean wrap_around) { @@ -521,7 +521,7 @@ impl_reload (EphyEmbed *embed, } static void -impl_zoom_set (EphyEmbed *embed, +impl_set_zoom (EphyEmbed *embed, float zoom, gboolean reflow) { @@ -542,7 +542,7 @@ impl_zoom_set (EphyEmbed *embed, } static float -impl_zoom_get (EphyEmbed *embed) +impl_get_zoom (EphyEmbed *embed) { MozillaEmbedPrivate *mpriv = MOZILLA_EMBED(embed)->priv; float f; @@ -1089,8 +1089,8 @@ ephy_embed_iface_init (EphyEmbedIface *iface) iface->get_link_message = impl_get_link_message; iface->get_js_status = impl_get_js_status; iface->reload = impl_reload; - iface->zoom_set = impl_zoom_set; - iface->zoom_get = impl_zoom_get; + iface->set_zoom = impl_set_zoom; + iface->get_zoom = impl_get_zoom; iface->shistory_n_items = impl_shistory_n_items; iface->shistory_get_nth = impl_shistory_get_nth; iface->shistory_get_pos = impl_shistory_get_pos; |