aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorXan Lopez <xan@src.gnome.org>2008-06-30 02:16:16 +0800
committerXan Lopez <xan@src.gnome.org>2008-06-30 02:16:16 +0800
commit8cad69642ad84471f9c80b47cba5ec3697a4e56a (patch)
tree6d6e94c879ba349dee25e088e8bdfddf6e977dac
parent69481e1a7b0835dcc595320af2195fe4c8c35fb3 (diff)
downloadgsoc2013-epiphany-8cad69642ad84471f9c80b47cba5ec3697a4e56a.tar
gsoc2013-epiphany-8cad69642ad84471f9c80b47cba5ec3697a4e56a.tar.gz
gsoc2013-epiphany-8cad69642ad84471f9c80b47cba5ec3697a4e56a.tar.bz2
gsoc2013-epiphany-8cad69642ad84471f9c80b47cba5ec3697a4e56a.tar.lz
gsoc2013-epiphany-8cad69642ad84471f9c80b47cba5ec3697a4e56a.tar.xz
gsoc2013-epiphany-8cad69642ad84471f9c80b47cba5ec3697a4e56a.tar.zst
gsoc2013-epiphany-8cad69642ad84471f9c80b47cba5ec3697a4e56a.zip
embed: remove ephy_embed_print.
And use the WebKit API directly. svn path=/trunk/; revision=8309
-rw-r--r--doc/reference/epiphany-sections.txt1
-rw-r--r--doc/reference/tmpl/ephy-embed.sgml9
-rw-r--r--embed/ephy-embed.c14
-rw-r--r--embed/ephy-embed.h3
-rw-r--r--embed/webkit/webkit-embed.c7
-rw-r--r--src/epiphany.defs6
-rw-r--r--src/window-commands.c2
7 files changed, 1 insertions, 41 deletions
diff --git a/doc/reference/epiphany-sections.txt b/doc/reference/epiphany-sections.txt
index ea440e83b..f9ce0b6a7 100644
--- a/doc/reference/epiphany-sections.txt
+++ b/doc/reference/epiphany-sections.txt
@@ -82,7 +82,6 @@ ephy_embed_find_set_properties
ephy_embed_find_next
ephy_embed_set_encoding
ephy_embed_get_encoding_info
-ephy_embed_print
ephy_embed_print_preview_close
ephy_embed_print_preview_n_pages
ephy_embed_print_preview_navigate
diff --git a/doc/reference/tmpl/ephy-embed.sgml b/doc/reference/tmpl/ephy-embed.sgml
index 30b41a4e9..4a17ca675 100644
--- a/doc/reference/tmpl/ephy-embed.sgml
+++ b/doc/reference/tmpl/ephy-embed.sgml
@@ -309,7 +309,6 @@ be done by casting).
@get_encoding:
@has_automatic_encoding:
@set_encoding:
-@print:
@set_print_preview_mode:
@print_preview_n_pages:
@print_preview_navigate:
@@ -468,14 +467,6 @@ windows opened with JavaScript often use a nonstandard chrome.
@encoding:
-<!-- ##### FUNCTION ephy_embed_print ##### -->
-<para>
-
-</para>
-
-@embed:
-
-
<!-- ##### FUNCTION ephy_embed_print_preview_n_pages ##### -->
<para>
diff --git a/embed/ephy-embed.c b/embed/ephy-embed.c
index f6bc66987..29d7a0859 100644
--- a/embed/ephy-embed.c
+++ b/embed/ephy-embed.c
@@ -724,20 +724,6 @@ ephy_embed_has_automatic_encoding (EphyEmbed *embed)
}
/**
- * ephy_embed_print:
- * @embed: an #EphyEmbed
- *
- * Sends a document to the printer.
- *
- **/
-void
-ephy_embed_print (EphyEmbed *embed)
-{
- EphyEmbedIface *iface = EPHY_EMBED_GET_IFACE (embed);
- iface->print (embed);
-}
-
-/**
* ephy_embed_set_print_preview_mode:
* @embed: an #EphyEmbed
* @preview_mode: Whether the print preview mode is enabled.
diff --git a/embed/ephy-embed.h b/embed/ephy-embed.h
index 2dddb985d..ec8b4db65 100644
--- a/embed/ephy-embed.h
+++ b/embed/ephy-embed.h
@@ -201,7 +201,6 @@ struct _EphyEmbedIface
gboolean (* has_automatic_encoding) (EphyEmbed *embed);
void (* set_encoding) (EphyEmbed *embed,
const char *encoding);
- void (* print) (EphyEmbed *embed);
void (* set_print_preview_mode) (EphyEmbed *embed,
gboolean mode);
int (* print_preview_n_pages) (EphyEmbed *embed);
@@ -340,8 +339,6 @@ void ephy_embed_set_encoding (EphyEmbed *embed,
const char *encoding);
/* Print */
-void ephy_embed_print (EphyEmbed *embed);
-
void ephy_embed_set_print_preview_mode (EphyEmbed *embed,
gboolean preview_mode);
diff --git a/embed/webkit/webkit-embed.c b/embed/webkit/webkit-embed.c
index 304273412..7e48c56c2 100644
--- a/embed/webkit/webkit-embed.c
+++ b/embed/webkit/webkit-embed.c
@@ -465,12 +465,6 @@ impl_show_page_certificate (EphyEmbed *embed)
}
static void
-impl_print (EphyEmbed *embed)
-{
- webkit_web_view_execute_script (WEBKIT_EMBED (embed)->priv->web_view, "print();");
-}
-
-static void
impl_set_print_preview_mode (EphyEmbed *embed, gboolean preview_mode)
{
}
@@ -570,7 +564,6 @@ ephy_embed_iface_init (EphyEmbedIface *iface)
iface->set_encoding = impl_set_encoding;
iface->get_encoding = impl_get_encoding;
iface->has_automatic_encoding = impl_has_automatic_encoding;
- iface->print = impl_print;
iface->set_print_preview_mode = impl_set_print_preview_mode;
iface->print_preview_n_pages = impl_print_preview_n_pages;
iface->print_preview_navigate = impl_print_preview_navigate;
diff --git a/src/epiphany.defs b/src/epiphany.defs
index b4b1da526..682dc8c54 100644
--- a/src/epiphany.defs
+++ b/src/epiphany.defs
@@ -1198,12 +1198,6 @@
)
)
-(define-method print
- (of-object "EphyEmbed")
- (c-name "ephy_embed_print")
- (return-type "none")
-)
-
(define-method set_print_preview_mode
(of-object "EphyEmbed")
(c-name "ephy_embed_set_print_preview_mode")
diff --git a/src/window-commands.c b/src/window-commands.c
index de5c9ec40..1609ed0b8 100644
--- a/src/window-commands.c
+++ b/src/window-commands.c
@@ -109,7 +109,7 @@ window_cmd_file_print (GtkAction *action,
(EPHY_EMBED_CONTAINER (window));
g_return_if_fail (EPHY_IS_EMBED (embed));
- ephy_embed_print (embed);
+ webkit_web_view_execute_script (EPHY_GET_WEBKIT_WEB_VIEW_FROM_EMBED (embed), "print();");
}
void