diff options
author | Marco Pesenti Gritti <marco@it.gnome.org> | 2003-03-15 07:19:40 +0800 |
---|---|---|
committer | Marco Pesenti Gritti <mpeseng@src.gnome.org> | 2003-03-15 07:19:40 +0800 |
commit | 95302a30a839e654d2dd0a574063a00c8437d97d (patch) | |
tree | ef304eb3c98ad0034e067bfed058eb34c32b6512 /embed/mozilla | |
parent | d52ebda480bfc31dc585fb7789ba33c7aa92899d (diff) | |
download | gsoc2013-epiphany-95302a30a839e654d2dd0a574063a00c8437d97d.tar gsoc2013-epiphany-95302a30a839e654d2dd0a574063a00c8437d97d.tar.gz gsoc2013-epiphany-95302a30a839e654d2dd0a574063a00c8437d97d.tar.bz2 gsoc2013-epiphany-95302a30a839e654d2dd0a574063a00c8437d97d.tar.lz gsoc2013-epiphany-95302a30a839e654d2dd0a574063a00c8437d97d.tar.xz gsoc2013-epiphany-95302a30a839e654d2dd0a574063a00c8437d97d.tar.zst gsoc2013-epiphany-95302a30a839e654d2dd0a574063a00c8437d97d.zip |
Reload embed when changing charset
2003-03-15 Marco Pesenti Gritti <marco@it.gnome.org>
* embed/mozilla/EphyWrapper.cpp:
* embed/mozilla/EphyWrapper.h:
* embed/mozilla/mozilla-embed.cpp:
Reload embed when changing charset
* embed/print-dialog.c: (print_get_info):
Correct colors flag
Diffstat (limited to 'embed/mozilla')
-rw-r--r-- | embed/mozilla/EphyWrapper.cpp | 2 | ||||
-rw-r--r-- | embed/mozilla/EphyWrapper.h | 2 | ||||
-rw-r--r-- | embed/mozilla/mozilla-embed.cpp | 11 |
3 files changed, 7 insertions, 8 deletions
diff --git a/embed/mozilla/EphyWrapper.cpp b/embed/mozilla/EphyWrapper.cpp index 3635b3649..fcde13437 100644 --- a/embed/mozilla/EphyWrapper.cpp +++ b/embed/mozilla/EphyWrapper.cpp @@ -726,7 +726,7 @@ nsresult EphyWrapper::CopyHistoryTo (EphyWrapper *dest) return NS_OK; } -nsresult EphyWrapper::ForceCharacterSet (char *charset) +nsresult EphyWrapper::ForceCharacterSet (const char *charset) { nsresult result; diff --git a/embed/mozilla/EphyWrapper.h b/embed/mozilla/EphyWrapper.h index 8f6a3672a..d083da44a 100644 --- a/embed/mozilla/EphyWrapper.h +++ b/embed/mozilla/EphyWrapper.h @@ -75,7 +75,7 @@ public: nsresult GoToHistoryIndex (PRInt16 index); - nsresult ForceCharacterSet (char *charset); + nsresult ForceCharacterSet (const char *charset); nsresult CanCutSelection(PRBool *result); diff --git a/embed/mozilla/mozilla-embed.cpp b/embed/mozilla/mozilla-embed.cpp index fe79c0ae9..467fcbfa1 100644 --- a/embed/mozilla/mozilla-embed.cpp +++ b/embed/mozilla/mozilla-embed.cpp @@ -1169,16 +1169,15 @@ impl_set_charset (EphyEmbed *embed, { nsresult result = NS_OK; EphyWrapper *wrapper; - char *cset; - - cset = g_strdup (charset); wrapper = MOZILLA_EMBED(embed)->priv->wrapper; g_return_val_if_fail (wrapper != NULL, G_FAILED); - wrapper->ForceCharacterSet (cset); - - g_free (cset); + result = wrapper->ForceCharacterSet (charset); + if (NS_FAILED (result)) return G_FAILED; + + gtk_moz_embed_reload (GTK_MOZ_EMBED (embed), + GTK_MOZ_EMBED_FLAG_RELOADCHARSETCHANGE); return NS_SUCCEEDED(result) ? G_OK : G_FAILED; } |