aboutsummaryrefslogtreecommitdiffstats
path: root/e-util
diff options
context:
space:
mode:
authorJeff Cai <jeff.cai@sun.com>2009-11-30 18:04:18 +0800
committerJeff Cai <jeff.cai@sun.com>2009-11-30 18:11:36 +0800
commit9cd8dede8bd6eac41f7486d95336909051d9b4c2 (patch)
treed5973656d5a1c94fb3ad012f772cc2317e1ea8b2 /e-util
parente3561c50baeaf9d7f24892c3e72cd46eab91d111 (diff)
downloadgsoc2013-evolution-9cd8dede8bd6eac41f7486d95336909051d9b4c2.tar.gz
gsoc2013-evolution-9cd8dede8bd6eac41f7486d95336909051d9b4c2.tar.zst
gsoc2013-evolution-9cd8dede8bd6eac41f7486d95336909051d9b4c2.zip
Fixed bug 364618, solve the chinese character issue.
Diffstat (limited to 'e-util')
-rw-r--r--e-util/e-pilot-util.c18
-rw-r--r--e-util/e-pilot-util.h4
2 files changed, 16 insertions, 6 deletions
diff --git a/e-util/e-pilot-util.c b/e-util/e-pilot-util.c
index 94c86a1084..3ce67c8e7b 100644
--- a/e-util/e-pilot-util.c
+++ b/e-util/e-pilot-util.c
@@ -31,7 +31,7 @@
#include "e-pilot-util.h"
gchar *
-e_pilot_utf8_to_pchar (const gchar *string)
+e_pilot_utf8_to_pchar (const gchar *string, const gchar *pilot_charset)
{
gchar *pstring = NULL;
gint res;
@@ -39,7 +39,12 @@ e_pilot_utf8_to_pchar (const gchar *string)
if (!string)
return NULL;
- res = convert_ToPilotChar ("UTF-8", string, strlen (string), &pstring);
+#ifdef PILOT_LINK_0_12
+ res = convert_ToPilotChar_WithCharset ("UTF-8", string, strlen (string),
+ &pstring, pilot_charset);
+#else
+ res = convert_ToPilotChar ("UTF-8", string, strlen (string), &pstring);
+#endif
if (res != 0)
pstring = strdup (string);
@@ -48,7 +53,7 @@ e_pilot_utf8_to_pchar (const gchar *string)
}
gchar *
-e_pilot_utf8_from_pchar (const gchar *string)
+e_pilot_utf8_from_pchar (const gchar *string, const gchar *pilot_charset)
{
gchar *ustring = NULL;
gint res;
@@ -56,7 +61,12 @@ e_pilot_utf8_from_pchar (const gchar *string)
if (!string)
return NULL;
- res = convert_FromPilotChar ("UTF-8", string, strlen (string), &ustring);
+#ifdef PILOT_LINK_0_12
+ res = convert_FromPilotChar_WithCharset ("UTF-8", string, strlen (string),
+ &ustring, pilot_charset);
+#else
+ res = convert_FromPilotChar ("UTF-8", string, strlen (string), &ustring);
+#endif
if (res != 0)
ustring = strdup (string);
diff --git a/e-util/e-pilot-util.h b/e-util/e-pilot-util.h
index 6b9b0ad884..9def45a8d8 100644
--- a/e-util/e-pilot-util.h
+++ b/e-util/e-pilot-util.h
@@ -29,8 +29,8 @@
#ifndef E_PILOT_UTIL_H
#define E_PILOT_UTIL_H
-gchar *e_pilot_utf8_to_pchar (const gchar *string);
-gchar *e_pilot_utf8_from_pchar (const gchar *string);
+gchar *e_pilot_utf8_to_pchar (const gchar *string, const gchar *pilot_charset);
+gchar *e_pilot_utf8_from_pchar (const gchar *string, const gchar *pilot_charset);
ESource *e_pilot_get_sync_source (ESourceList *source_list);
void e_pilot_set_sync_source (ESourceList *source_list, ESource *source);
a443919aba804ae93e5d90086ce23a0a47c4'>BROKEN: Unfetchablekris2004-07-111-0/+2 * Update to version 0.34krion2004-07-034-199/+147 * Bump PORTREVISION on all ports that depend on gettext to aid with upgrading.marcus2004-02-041-0/+1 * Add SIZE.trevor2004-01-281-0/+1 * unbreak by upgrade to 0.33ijliao2003-05-074-230/+228 * BROKEN: Does not buildkris2003-05-061-0/+2 * De-pkg-comment.knu2003-02-212-1/+1 * fix build on -currentijliao2002-12-222-0/+13 * o Rollback PORTCOMMENT modifications while this feature's implementationlioux2002-11-112-2/+1 * Use PORTCOMMENT in the Makefile, and whack the pkg-comment.adamw2002-11-072-1/+2 * PERL -> REINPLACE_CMDijliao2002-07-081-2/+3 * Install docs and examples.tg2002-06-272-2/+223 * Update to 0.31pat2002-06-122-2/+2 * Respect CXX/CXXFLAGS.petef2002-03-011-0/+7 * add gnucap 0.30ijliao2002-02-07