summarylogtreecommitdiffstats
path: root/scim-chewing-libchewing04.patch
blob: 4658f47d132841b604cd68e265911913ea04cc3f (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
Upstream commits: 545279e 1f3c42d 1e12860

--- a/configure.ac
+++ b/configure.ac
@@ -48,7 +48,7 @@ AC_TYPE_SIZE_T
 # Checks for libraries.
 
 SCIM_VERSION=1.0.0
-CHEWING_VERSION=0.3.4
+CHEWING_VERSION=0.4.0
 
 PKG_CHECK_MODULES(SCIM, [scim >= $SCIM_VERSION])
 
@@ -59,7 +59,7 @@ PKG_CHECK_MODULES(SCIM_GTKUTILS,[scim-gtkutils >= $SCIM_VERSION],
 
 AC_SUBST(SCIM_VERSION)
 
-PKG_CHECK_MODULES(CHEWING, [chewing = $CHEWING_VERSION])
+PKG_CHECK_MODULES(CHEWING, [chewing >= $CHEWING_VERSION])
 AC_SUBST(CHEWING_VERSION)
 
 AM_CONDITIONAL(SCIM_BUILD_SETUP, [test "$SCIM_HAS_GTKUTILS" = "yes"])
--- a/src/scim_chewing_imengine.cpp
+++ b/src/scim_chewing_imengine.cpp
@@ -73,8 +73,6 @@ extern "C" {
 	void scim_module_exit()
 	{
 		_scim_config.reset();
-		/* New API introduced in libchewing 0.2.7 */
-		chewing_Terminate();
 	}
 
 	unsigned int scim_imengine_module_init( const ConfigPointer& config )
@@ -122,10 +120,6 @@ ChewingIMEngineFactory::ChewingIMEngineFactory( const ConfigPointer& config )
 
 bool ChewingIMEngineFactory::init()
 {
-	char prefix[] = CHEWING_DATADIR;
-	char hash_postfix[] = "/.chewing/";
-
-	chewing_Init(prefix, (char *)(scim_get_home_dir() + hash_postfix).c_str() );
 	return true;
 }
 
@@ -670,7 +664,7 @@ bool ChewingIMEngineInstance::commit( ChewingContext* ctx )
 
 	// cursor decoration
 	int current_cursor = chewing_cursor_Current( ctx );
-	if( chewing_zuin_Check( ctx ) ) {
+	if( chewing_bopomofo_Check( ctx ) ) {
 		attr.push_back(
 			Attribute(
 				current_cursor,