aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorChristian Persch <chpe@cvs.gnome.org>2003-11-26 04:56:58 +0800
committerChristian Persch <chpe@src.gnome.org>2003-11-26 04:56:58 +0800
commit812571437fe45da173d0cc9414c14b2a8131c427 (patch)
tree779465cdd8eff9a1d91ab7bebe353036f3b5a0bb
parent6d59637c20fcc7b24c87257a195230c4fbb284b5 (diff)
downloadgsoc2013-epiphany-812571437fe45da173d0cc9414c14b2a8131c427.tar
gsoc2013-epiphany-812571437fe45da173d0cc9414c14b2a8131c427.tar.gz
gsoc2013-epiphany-812571437fe45da173d0cc9414c14b2a8131c427.tar.bz2
gsoc2013-epiphany-812571437fe45da173d0cc9414c14b2a8131c427.tar.lz
gsoc2013-epiphany-812571437fe45da173d0cc9414c14b2a8131c427.tar.xz
gsoc2013-epiphany-812571437fe45da173d0cc9414c14b2a8131c427.tar.zst
gsoc2013-epiphany-812571437fe45da173d0cc9414c14b2a8131c427.zip
Change signal names to be unique for interfaces on the same object.
2003-11-25 Christian Persch <chpe@cvs.gnome.org> * embed/ephy-cookie-manager.c: (ephy_cookie_manager_base_init): * embed/ephy-cookie-manager.h: * embed/ephy-permission-manager.c: (ephy_permission_manager_base_init): * embed/mozilla/EphySingle.cpp: Change signal names to be unique for interfaces on the same object.
-rw-r--r--ChangeLog10
-rw-r--r--embed/ephy-cookie-manager.c32
-rw-r--r--embed/ephy-cookie-manager.h2
-rw-r--r--embed/ephy-permission-manager.c31
-rw-r--r--embed/mozilla/EphySingle.cpp28
5 files changed, 57 insertions, 46 deletions
diff --git a/ChangeLog b/ChangeLog
index 7842fd690..dd9b4a25e 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,6 +1,16 @@
2003-11-25 Christian Persch <chpe@cvs.gnome.org>
* embed/ephy-cookie-manager.c: (ephy_cookie_manager_base_init):
+ * embed/ephy-cookie-manager.h:
+ * embed/ephy-permission-manager.c:
+ (ephy_permission_manager_base_init):
+ * embed/mozilla/EphySingle.cpp:
+
+ Change signal names to be unique for interfaces on the same object.
+
+2003-11-25 Christian Persch <chpe@cvs.gnome.org>
+
+ * embed/ephy-cookie-manager.c: (ephy_cookie_manager_base_init):
Fix marshaller type.
diff --git a/embed/ephy-cookie-manager.c b/embed/ephy-cookie-manager.c
index bc3590a58..df079bddf 100644
--- a/embed/ephy-cookie-manager.c
+++ b/embed/ephy-cookie-manager.c
@@ -131,13 +131,13 @@ ephy_cookie_manager_base_init (gpointer base_iface)
if (initialised == FALSE)
{
/**
- * EphyCookieManager::added
+ * EphyCookieManager::cookie-added
* @manager: the #EphyCookieManager
* @cookie: the added #EphyCookie
*
- * The added signal is emitted when a cookie has been added.
+ * The cookie-added signal is emitted when a cookie has been added.
**/
- g_signal_new ("added",
+ g_signal_new ("cookie-added",
EPHY_TYPE_COOKIE_MANAGER,
G_SIGNAL_RUN_FIRST,
G_STRUCT_OFFSET (EphyCookieManagerIFace, added),
@@ -148,13 +148,13 @@ ephy_cookie_manager_base_init (gpointer base_iface)
EPHY_TYPE_COOKIE);
/**
- * EphyCookieManager::changed
+ * EphyCookieManager::cookie-changed
* @manager: the #EphyCookieManager
* @cookie: the changed #EphyCookie
*
- * The changed signal is emitted when a cookie has been changed.
+ * The cookie-changed signal is emitted when a cookie has been changed.
**/
- g_signal_new ("changed",
+ g_signal_new ("cookie-changed",
EPHY_TYPE_COOKIE_MANAGER,
G_SIGNAL_RUN_FIRST,
G_STRUCT_OFFSET (EphyCookieManagerIFace, changed),
@@ -165,13 +165,13 @@ ephy_cookie_manager_base_init (gpointer base_iface)
EPHY_TYPE_COOKIE);
/**
- * EphyCookieManager::deleted
+ * EphyCookieManager::cookie-deleted
* @manager: the #EphyCookieManager
* @cookie: the deleted #EphyCookie
*
- * The deleted signal is emitted when a cookie has been deleted.
+ * The cookie-deleted signal is emitted when a cookie has been deleted.
**/
- g_signal_new ("deleted",
+ g_signal_new ("cookie-deleted",
EPHY_TYPE_COOKIE_MANAGER,
G_SIGNAL_RUN_FIRST,
G_STRUCT_OFFSET (EphyCookieManagerIFace, deleted),
@@ -182,13 +182,13 @@ ephy_cookie_manager_base_init (gpointer base_iface)
EPHY_TYPE_COOKIE);
/**
- * EphyCookieManager::rejected
+ * EphyCookieManager::cookie-rejected
* @manager: the #EphyCookieManager
* @address: the address of the page that wanted to set the cookie
*
- * The rejected signal is emitted when a cookie has been rejected.
+ * The cookie-rejected signal is emitted when a cookie has been rejected.
**/
- g_signal_new ("rejected",
+ g_signal_new ("cookie-rejected",
EPHY_TYPE_COOKIE_MANAGER,
G_SIGNAL_RUN_FIRST,
G_STRUCT_OFFSET (EphyCookieManagerIFace, rejected),
@@ -199,13 +199,13 @@ ephy_cookie_manager_base_init (gpointer base_iface)
G_TYPE_STRING);
/**
- * EphyCookieManager::cleared
+ * EphyCookieManager::cookies-cleared
* @manager: the #EphyCookieManager
*
- * The cleared signal is emitted when the cookie database has been
- * cleared.
+ * The cookies-cleared signal is emitted when the cookie database has
+ * been cleared.
**/
- g_signal_new ("cleared",
+ g_signal_new ("cookies-cleared",
EPHY_TYPE_COOKIE_MANAGER,
G_SIGNAL_RUN_FIRST,
G_STRUCT_OFFSET (EphyCookieManagerIFace, cleared),
diff --git a/embed/ephy-cookie-manager.h b/embed/ephy-cookie-manager.h
index f4782d2cf..c82ace19e 100644
--- a/embed/ephy-cookie-manager.h
+++ b/embed/ephy-cookie-manager.h
@@ -108,8 +108,6 @@ void ephy_cookie_free (EphyCookie *cookie);
GType ephy_cookie_manager_get_type (void);
-void ephy_cookie_free (EphyCookie *cookie);
-
GList * ephy_cookie_manager_list_cookies (EphyCookieManager *manager);
void ephy_cookie_manager_remove_cookie (EphyCookieManager *manager,
diff --git a/embed/ephy-permission-manager.c b/embed/ephy-permission-manager.c
index 878ead738..c2518b94c 100644
--- a/embed/ephy-permission-manager.c
+++ b/embed/ephy-permission-manager.c
@@ -135,13 +135,14 @@ ephy_permission_manager_base_init (gpointer g_class)
if (initialised == FALSE)
{
/**
- * EphyPermissionManager::added
+ * EphyPermissionManager::permission-added
* @manager: the #EphyPermissionManager
* @info: a #EphyPermissionInfo
*
- * The added signal is emitted when a permission entry has been added.
+ * The permission-added signal is emitted when a permission entry has
+ * been added.
*/
- g_signal_new ("added",
+ g_signal_new ("permission-added",
EPHY_TYPE_PERMISSION_MANAGER,
G_SIGNAL_RUN_FIRST,
G_STRUCT_OFFSET (EphyPermissionManagerIFace, added),
@@ -152,14 +153,14 @@ ephy_permission_manager_base_init (gpointer g_class)
EPHY_TYPE_PERMISSION_INFO);
/**
- * EphyPermissionManager::changed
+ * EphyPermissionManager::permission-changed
* @manager: the #EphyPermissionManager
* @info: a #EphyPermissionInfo
*
- * The changed signal is emitted when a permission entry has been
- * changed.
+ * The permission-changed signal is emitted when a permission entry has
+ * been changed.
*/
- g_signal_new ("changed",
+ g_signal_new ("permission-changed",
EPHY_TYPE_PERMISSION_MANAGER,
G_SIGNAL_RUN_FIRST,
G_STRUCT_OFFSET (EphyPermissionManagerIFace, changed),
@@ -170,14 +171,14 @@ ephy_permission_manager_base_init (gpointer g_class)
EPHY_TYPE_PERMISSION_INFO);
/**
- * EphyPermissionManager::deleted
+ * EphyPermissionManager::permission-deleted
* @manager: the #EphyPermissionManager
* @info: a #EphyPermissionInfo
*
- * The deleted signal is emitted when a permission entry has been
- * deleted.
+ * The permission-deleted signal is emitted when a permission entry has
+ * been deleted.
*/
- g_signal_new ("deleted",
+ g_signal_new ("permission-deleted",
EPHY_TYPE_PERMISSION_MANAGER,
G_SIGNAL_RUN_FIRST,
G_STRUCT_OFFSET (EphyPermissionManagerIFace, deleted),
@@ -188,13 +189,13 @@ ephy_permission_manager_base_init (gpointer g_class)
EPHY_TYPE_PERMISSION_INFO);
/**
- * EphyPermissionManager::cleared
+ * EphyPermissionManager::permissions-cleared
* @manager: the #EphyPermissionManager
*
- * The cleared signal is emitted when the permissions database has
- * been cleared.
+ * The permissions-cleared signal is emitted when the permissions
+ * database has been cleared.
*/
- g_signal_new ("cleared",
+ g_signal_new ("permissions-cleared",
EPHY_TYPE_PERMISSION_MANAGER,
G_SIGNAL_RUN_FIRST,
G_STRUCT_OFFSET (EphyPermissionManagerIFace, cleared),
diff --git a/embed/mozilla/EphySingle.cpp b/embed/mozilla/EphySingle.cpp
index 2707f939d..1762b2e18 100644
--- a/embed/mozilla/EphySingle.cpp
+++ b/embed/mozilla/EphySingle.cpp
@@ -85,7 +85,8 @@ EphySingle::~EphySingle()
}
nsresult
-EphySingle::EmitCookieNotification (const char *name, nsISupports *aSubject)
+EphySingle::EmitCookieNotification (const char *name,
+ nsISupports *aSubject)
{
LOG ("EmitCookieNotification %s", name)
@@ -102,7 +103,8 @@ EphySingle::EmitCookieNotification (const char *name, nsISupports *aSubject)
}
nsresult
-EphySingle::EmitPermissionNotification (const char *name, nsISupports *aSubject)
+EphySingle::EmitPermissionNotification (const char *name,
+ nsISupports *aSubject)
{
LOG ("EmitPermissionNotification %s", name)
@@ -122,8 +124,8 @@ EphySingle::EmitPermissionNotification (const char *name, nsISupports *aSubject)
/* void observe (in nsISupports aSubject, in string aTopic, in wstring aData); */
NS_IMETHODIMP EphySingle::Observe(nsISupports *aSubject,
- const char *aTopic,
- const PRUnichar *aData)
+ const char *aTopic,
+ const PRUnichar *aData)
{
nsresult rv = NS_OK;
@@ -132,24 +134,24 @@ NS_IMETHODIMP EphySingle::Observe(nsISupports *aSubject,
/* "added" */
if (aData[0] == 'a')
{
- rv = EmitCookieNotification ("added", aSubject);
+ rv = EmitCookieNotification ("cookie-added", aSubject);
}
/* "deleted" */
else if (aData[0] == 'd')
{
- rv = EmitCookieNotification ("deleted", aSubject);
+ rv = EmitCookieNotification ("cookie-deleted", aSubject);
}
/* "changed" */
else if (aData[0] == 'c' && aData[1] == 'h')
{
- rv = EmitCookieNotification ("changed", aSubject);
+ rv = EmitCookieNotification ("cookie-changed", aSubject);
}
/* "cleared" */
else if (aData[0] == 'c' && aData[2] == 'l')
{
LOG ("EphySingle::cookie-changed::cleared")
- g_signal_emit_by_name (EPHY_COOKIE_MANAGER (mOwner), "cleared");
+ g_signal_emit_by_name (EPHY_COOKIE_MANAGER (mOwner), "cookies-cleared");
}
else
{
@@ -167,7 +169,7 @@ NS_IMETHODIMP EphySingle::Observe(nsISupports *aSubject,
nsCAutoString spec;
uri->GetSpec (spec);
- g_signal_emit_by_name (EPHY_COOKIE_MANAGER (mOwner), "rejected", spec.get());
+ g_signal_emit_by_name (EPHY_COOKIE_MANAGER (mOwner), "cookie-rejected", spec.get());
}
else
{
@@ -179,24 +181,24 @@ NS_IMETHODIMP EphySingle::Observe(nsISupports *aSubject,
/* "added" */
if (aData[0] == 'a')
{
- rv = EmitPermissionNotification ("added", aSubject);
+ rv = EmitPermissionNotification ("permission-added", aSubject);
}
/* "deleted" */
else if (aData[0] == 'd')
{
- rv = EmitPermissionNotification ("deleted", aSubject);
+ rv = EmitPermissionNotification ("permission-deleted", aSubject);
}
/* "changed" */
else if (aData[0] == 'c' && aData[1] == 'h')
{
- rv = EmitPermissionNotification ("changed", aSubject);
+ rv = EmitPermissionNotification ("permission-changed", aSubject);
}
/* "cleared" */
else if (aData[0] == 'c' && aData[1] == 'l')
{
LOG ("EphySingle::perm-changed::cleared")
- g_signal_emit_by_name (EPHY_PERMISSION_MANAGER (mOwner), "cleared");
+ g_signal_emit_by_name (EPHY_PERMISSION_MANAGER (mOwner), "permissions-cleared");
}
else
{