Hello community,
here is the log from the commit of package fcitx-cloudpinyin for openSUSE:Factory checked in at 2013-01-29 12:07:58
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/fcitx-cloudpinyin (Old)
and /work/SRC/openSUSE:Factory/.fcitx-cloudpinyin.new (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "fcitx-cloudpinyin", Maintainer is ""
Changes:
--------
--- /work/SRC/openSUSE:Factory/fcitx-cloudpinyin/fcitx-cloudpinyin.changes 2012-09-20 15:24:22.000000000 +0200
+++ /work/SRC/openSUSE:Factory/.fcitx-cloudpinyin.new/fcitx-cloudpinyin.changes 2013-01-29 12:08:00.000000000 +0100
@@ -1,0 +2,6 @@
+Sat Jan 26 18:59:30 UTC 2013 - i@marguerite.su
+
+- update version 0.3.1
+ * update to support clean quit.
+
+-------------------------------------------------------------------
Old:
----
fcitx-cloudpinyin-0.3.0.tar.bz2
New:
----
fcitx-cloudpinyin-0.3.1.tar.bz2
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Other differences:
------------------
++++++ fcitx-cloudpinyin.spec ++++++
--- /var/tmp/diff_new_pack.WYptqm/_old 2013-01-29 12:08:01.000000000 +0100
+++ /var/tmp/diff_new_pack.WYptqm/_new 2013-01-29 12:08:01.000000000 +0100
@@ -18,7 +18,7 @@
Name: fcitx-cloudpinyin
-Version: 0.3.0
+Version: 0.3.1
Release: 0
Summary: Cloudpinyin module for fcitx
Group: System/I18n/Chinese
++++++ fcitx-cloudpinyin-0.3.0.tar.bz2 -> fcitx-cloudpinyin-0.3.1.tar.bz2 ++++++
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/fcitx-cloudpinyin-0.3.0/.gitignore new/fcitx-cloudpinyin-0.3.1/.gitignore
--- old/fcitx-cloudpinyin-0.3.0/.gitignore 2012-09-12 16:00:12.000000000 +0200
+++ new/fcitx-cloudpinyin-0.3.1/.gitignore 2013-01-25 18:55:38.000000000 +0100
@@ -1,13 +1,13 @@
*~
-build/*
+build*/
.*
!.git*
.git/
+*.tar.*
*.kdev4
*.kate-swp
*.orig
tags
astyle.sh
cscope.*
-.kdev_include_paths
-.directory
+*.part
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/fcitx-cloudpinyin-0.3.0/CMakeLists.txt new/fcitx-cloudpinyin-0.3.1/CMakeLists.txt
--- old/fcitx-cloudpinyin-0.3.0/CMakeLists.txt 2012-09-12 16:00:12.000000000 +0200
+++ new/fcitx-cloudpinyin-0.3.1/CMakeLists.txt 2013-01-25 18:55:38.000000000 +0100
@@ -2,27 +2,19 @@
cmake_minimum_required(VERSION 2.6)
set(CMAKE_MODULE_PATH "${CMAKE_CURRENT_SOURCE_DIR}/cmake" ${CMAKE_MODULE_PATH})
-find_package(Fcitx 4.2.6 REQUIRED)
+find_package(Fcitx 4.2.7 REQUIRED)
find_package(PkgConfig REQUIRED)
-find_package(Gettext REQUIRED)
find_package(Libintl REQUIRED)
find_package(Libiconv REQUIRED)
find_package(Pthread REQUIRED)
-# uninstall target
-configure_file(
- "${CMAKE_CURRENT_SOURCE_DIR}/cmake/cmake_uninstall.cmake.in"
- "${CMAKE_CURRENT_BINARY_DIR}/cmake_uninstall.cmake"
- IMMEDIATE @ONLY)
+_fcitx_add_uninstall_target()
set(CMAKE_C_FLAGS "-Wall -Wextra -Wno-sign-compare -Wno-unused-parameter -fvisibility=hidden ${CMAKE_C_FLAGS}")
set(CMAKE_CXX_FLAGS "-Wall -Wextra -Wno-sign-compare -Wno-unused-parameter -fvisibility=hidden ${CMAKE_CXX_FLAGS}")
set(CMAKE_SHARED_LINKER_FLAGS "-Wl,--as-needed ${CMAKE_SHARED_LINKER_FLAGS}")
set(CMAKE_MODULE_LINKER_FLAGS "-Wl,--as-needed ${CMAKE_MODULE_LINKER_FLAGS}")
-add_custom_target(uninstall
- COMMAND ${CMAKE_COMMAND} -P ${CMAKE_CURRENT_BINARY_DIR}/cmake_uninstall.cmake)
-
pkg_check_modules(CURL "libcurl" REQUIRED)
set(LOCALEDIR "${CMAKE_INSTALL_PREFIX}/share/locale")
@@ -31,6 +23,6 @@
enable_testing()
-add_subdirectory(src)
add_subdirectory(po)
-add_subdirectory(test)
\ No newline at end of file
+add_subdirectory(src)
+add_subdirectory(test)
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/fcitx-cloudpinyin-0.3.0/COPYING new/fcitx-cloudpinyin-0.3.1/COPYING
--- old/fcitx-cloudpinyin-0.3.0/COPYING 2012-09-12 16:00:12.000000000 +0200
+++ new/fcitx-cloudpinyin-0.3.1/COPYING 2013-01-25 18:55:38.000000000 +0100
@@ -2,7 +2,7 @@
Version 2, June 1991
Copyright (C) 1989, 1991 Free Software Foundation, Inc.
- 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+ 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA.
Everyone is permitted to copy and distribute verbatim copies
of this license document, but changing it is not allowed.
@@ -305,7 +305,7 @@
You should have received a copy of the GNU General Public License
along with this program; if not, write to the Free Software
- Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+ Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA.
Also add information on how to contact you by electronic and paper mail.
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/fcitx-cloudpinyin-0.3.0/README new/fcitx-cloudpinyin-0.3.1/README
--- old/fcitx-cloudpinyin-0.3.0/README 2012-09-12 16:00:12.000000000 +0200
+++ new/fcitx-cloudpinyin-0.3.1/README 2013-01-25 18:55:38.000000000 +0100
@@ -1,4 +1 @@
-this is a standalone module for fcitx, it can use pinyin API on the internet
-to input.
-
-Requires Fcitx 4.1.0 (Currently is not released).
+Fcitx-Cloudpinyin is a standalone module for fcitx that uses web API to provide better pinyin result.
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/fcitx-cloudpinyin-0.3.0/cmake/FindLibintl.cmake new/fcitx-cloudpinyin-0.3.1/cmake/FindLibintl.cmake
--- old/fcitx-cloudpinyin-0.3.0/cmake/FindLibintl.cmake 2012-09-12 16:00:12.000000000 +0200
+++ new/fcitx-cloudpinyin-0.3.1/cmake/FindLibintl.cmake 2013-01-25 18:55:38.000000000 +0100
@@ -9,38 +9,39 @@
# present in libc. Must have more robust system for release, where Gettext
# functionality can also reside in standalone Gettext library, or the one
# embedded within kdelibs (cf. gettext.m4 from Gettext source).
-
+
# Copyright (c) 2006, Chusslove Illich,
# Copyright (c) 2007, Alexander Neundorf,
#
# Redistribution and use is allowed according to the terms of the BSD license.
# For details see the accompanying COPYING-CMAKE-SCRIPTS file.
-
+
if(LIBINTL_INCLUDE_DIR AND LIBINTL_LIB_FOUND)
set(Libintl_FIND_QUIETLY TRUE)
-endif(LIBINTL_INCLUDE_DIR AND LIBINTL_LIB_FOUND)
-
+endif()
+
find_path(LIBINTL_INCLUDE_DIR libintl.h)
-
+
set(LIBINTL_LIB_FOUND FALSE)
-
+
if(LIBINTL_INCLUDE_DIR)
include(CheckFunctionExists)
check_function_exists(dgettext LIBINTL_LIBC_HAS_DGETTEXT)
-
- if (LIBINTL_LIBC_HAS_DGETTEXT)
+
+ if(LIBINTL_LIBC_HAS_DGETTEXT)
set(LIBINTL_LIBRARIES)
set(LIBINTL_LIB_FOUND TRUE)
- else (LIBINTL_LIBC_HAS_DGETTEXT)
- find_library(LIBINTL_LIBRARIES NAMES intl libintl )
+ else()
+ find_library(LIBINTL_LIBRARIES NAMES intl libintl)
if(LIBINTL_LIBRARIES)
set(LIBINTL_LIB_FOUND TRUE)
- endif(LIBINTL_LIBRARIES)
- endif (LIBINTL_LIBC_HAS_DGETTEXT)
-
+ endif()
+ endif()
endif(LIBINTL_INCLUDE_DIR)
-
+
include(FindPackageHandleStandardArgs)
-find_package_handle_standard_args(Libintl DEFAULT_MSG LIBINTL_INCLUDE_DIR LIBINTL_LIB_FOUND)
-
-mark_as_advanced(LIBINTL_INCLUDE_DIR LIBINTL_LIBRARIES LIBINTL_LIBC_HAS_DGETTEXT LIBINTL_LIB_FOUND)
\ No newline at end of file
+find_package_handle_standard_args(Libintl DEFAULT_MSG LIBINTL_INCLUDE_DIR
+ LIBINTL_LIB_FOUND)
+
+mark_as_advanced(LIBINTL_INCLUDE_DIR LIBINTL_LIBRARIES
+ LIBINTL_LIBC_HAS_DGETTEXT LIBINTL_LIB_FOUND)
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/fcitx-cloudpinyin-0.3.0/po/CMakeLists.txt new/fcitx-cloudpinyin-0.3.1/po/CMakeLists.txt
--- old/fcitx-cloudpinyin-0.3.0/po/CMakeLists.txt 2012-09-12 16:00:12.000000000 +0200
+++ new/fcitx-cloudpinyin-0.3.1/po/CMakeLists.txt 2013-01-25 18:55:38.000000000 +0100
@@ -1,23 +1,5 @@
-file(GLOB PO_FILES RELATIVE ${CMAKE_CURRENT_SOURCE_DIR} *.po)
-file(RELATIVE_PATH REL_SOURCE_ROOT ${PROJECT_BINARY_DIR} ${PROJECT_SOURCE_DIR})
-if ("${REL_SOURCE_ROOT}" STREQUAL "")
- set(REL_SOURCE_ROOT ".")
-endif("${REL_SOURCE_ROOT}" STREQUAL "")
-
-set(POT_FILE fcitx-cloudpinyin.pot)
-
-configure_file(POTFILES.in.in ${CMAKE_CURRENT_BINARY_DIR}/POTFILES.in)
-
-extract_fcitx_addon_conf_postring()
-extract_fcitx_desc_file_postring()
-
-add_custom_target(
- pot
- COMMAND INTLTOOL_EXTRACT=${INTLTOOL_EXTRACT} srcdir=${CMAKE_CURRENT_BINARY_DIR} ${INTLTOOL_UPDATE} --gettext-package fcitx-cloudpinyin --pot
- WORKING_DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}
- DEPENDS ${CMAKE_CURRENT_BINARY_DIR}/conf.po ${CMAKE_CURRENT_BINARY_DIR}/desc.po
- )
-
-# Update .po files and compile them to binary .gmo files
-gettext_create_translations(${POT_FILE} ALL ${PO_FILES})
-
+set(PO_LANGS zh_CN zh_TW)
+foreach(lang ${PO_LANGS})
+ fcitx_translate_add_po_file("${lang}" "${lang}.po")
+endforeach()
+fcitx_translate_set_pot_target(pot fcitx-cloudpinyin fcitx-cloudpinyin.pot)
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/fcitx-cloudpinyin-0.3.0/po/POTFILES.in.in new/fcitx-cloudpinyin-0.3.1/po/POTFILES.in.in
--- old/fcitx-cloudpinyin-0.3.0/po/POTFILES.in.in 2012-09-12 16:00:12.000000000 +0200
+++ new/fcitx-cloudpinyin-0.3.1/po/POTFILES.in.in 1970-01-01 01:00:00.000000000 +0100
@@ -1,5 +0,0 @@
-# List of source files which contain translatable strings.
-./po/desc.po
-./po/conf.po
-@REL_SOURCE_ROOT@/src/cloudpinyin.c
-@REL_SOURCE_ROOT@/src/fcitx-cloudpinyin.conf.in
\ No newline at end of file
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/fcitx-cloudpinyin-0.3.0/po/fcitx-cloudpinyin.pot new/fcitx-cloudpinyin-0.3.1/po/fcitx-cloudpinyin.pot
--- old/fcitx-cloudpinyin-0.3.0/po/fcitx-cloudpinyin.pot 2012-09-12 16:00:12.000000000 +0200
+++ new/fcitx-cloudpinyin-0.3.1/po/fcitx-cloudpinyin.pot 2013-01-25 18:55:38.000000000 +0100
@@ -7,60 +7,61 @@
msgid ""
msgstr ""
"Project-Id-Version: PACKAGE VERSION\n"
-"Report-Msgid-Bugs-To: \n"
-"POT-Creation-Date: 2012-08-29 18:07-0400\n"
+"Report-Msgid-Bugs-To: fcitx-dev@googlegroups.com\n"
+"POT-Creation-Date: 2012-12-01 18:57-0500\n"
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
"Last-Translator: FULL NAME \n"
"Language-Team: LANGUAGE \n"
-"Language: \n"
+"Language: LANG\n"
"MIME-Version: 1.0\n"
-"Content-Type: text/plain; charset=CHARSET\n"
+"Content-Type: text/plain; charset=utf-8\n"
"Content-Transfer-Encoding: 8bit\n"
-#: /home/saber/Develop/fcitx-cloudpinyin/src/fcitx-cloudpinyin.desc:5
-msgid "Cloud Pinyin Candidate Word Order"
+#: src/cloudpinyin.c:607
+msgid " (via cloud)"
msgstr ""
-#: /home/saber/Develop/fcitx-cloudpinyin/src/fcitx-cloudpinyin.desc:11
-msgid "Minimum Length of Pinyin To Trigger Cloud Pinyin"
+#: src/fcitx-cloudpinyin.conf.in:3
+msgid "Cloud Pinyin"
msgstr ""
-#: /home/saber/Develop/fcitx-cloudpinyin/src/fcitx-cloudpinyin.desc:16
-msgid "Don't Show the 'via cloud' hint"
+#: src/fcitx-cloudpinyin.conf.in:4
+msgid "Add Cloud Pinyin Support to Pinyin Input Method"
msgstr ""
-#: /home/saber/Develop/fcitx-cloudpinyin/src/fcitx-cloudpinyin.desc:21
-msgid "Cloud Pinyin Source"
+#: src/fcitx-cloudpinyin.desc:1 src/fcitx-cloudpinyin.desc:7
+#: src/fcitx-cloudpinyin.desc:13 src/fcitx-cloudpinyin.desc:18
+msgid "CloudPinyin"
msgstr ""
-# unknown
-msgid "CloudPinyin"
+#: src/fcitx-cloudpinyin.desc:5
+msgid "Cloud Pinyin Candidate Word Order"
msgstr ""
-#: unknown
-msgid "Baidu"
+#: src/fcitx-cloudpinyin.desc:11
+msgid "Minimum Length of Pinyin To Trigger Cloud Pinyin"
msgstr ""
-#: unknown
-msgid "Google"
+#: src/fcitx-cloudpinyin.desc:16
+msgid "Don't Show the 'via cloud' hint"
msgstr ""
-#: unknown
-msgid "QQ"
+#: src/fcitx-cloudpinyin.desc:21
+msgid "Cloud Pinyin Source"
msgstr ""
-#: unknown
+#: src/fcitx-cloudpinyin.desc:23
msgid "Sogou"
msgstr ""
-#: /home/saber/Develop/fcitx-cloudpinyin/build/po/tmp/fcitx-cloudpinyin.conf.in.h:1
-msgid "Cloud Pinyin"
+#: src/fcitx-cloudpinyin.desc:24
+msgid "QQ"
msgstr ""
-#: /home/saber/Develop/fcitx-cloudpinyin/build/po/tmp/fcitx-cloudpinyin.conf.in.h:2
-msgid "Add Cloud Pinyin Support to Pinyin Input Method"
+#: src/fcitx-cloudpinyin.desc:25
+msgid "Google"
msgstr ""
-#: /home/saber/Develop/fcitx-cloudpinyin/build/po/../..//src/cloudpinyin.c:588
-msgid " (via cloud)"
+#: src/fcitx-cloudpinyin.desc:26
+msgid "Baidu"
msgstr ""
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/fcitx-cloudpinyin-0.3.0/po/zh_CN.po new/fcitx-cloudpinyin-0.3.1/po/zh_CN.po
--- old/fcitx-cloudpinyin-0.3.0/po/zh_CN.po 2012-09-12 16:00:12.000000000 +0200
+++ new/fcitx-cloudpinyin-0.3.1/po/zh_CN.po 2013-01-25 18:55:38.000000000 +0100
@@ -1,70 +1,69 @@
# SOME DESCRIPTIVE TITLE.
# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER
# This file is distributed under the same license as the PACKAGE package.
-#
+#
# Translators:
+# Christopher Meng , 2012.
# Weng Xuetian , 2011.
msgid ""
msgstr ""
"Project-Id-Version: fcitx\n"
-"Report-Msgid-Bugs-To: \n"
-"POT-Creation-Date: 2012-08-29 18:07-0400\n"
-"PO-Revision-Date: 2012-08-29 20:00-0400\n"
-"Last-Translator: Yichao Yu \n"
+"Report-Msgid-Bugs-To: fcitx-dev@googlegroups.com\n"
+"POT-Creation-Date: 2012-12-01 18:57-0500\n"
+"PO-Revision-Date: 2012-09-02 06:46+0000\n"
+"Last-Translator: Xuetian Weng \n"
"Language-Team: Chinese (China) \n"
-"Language: zh_CN\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
-"Plural-Forms: nplurals=1; plural=0\n"
+"Language: zh_CN\n"
+"Plural-Forms: nplurals=1; plural=0;\n"
-#: /home/saber/Develop/fcitx-cloudpinyin/build/po/../..//src/cloudpinyin.c:588
+#: src/cloudpinyin.c:607
msgid " (via cloud)"
msgstr " (来自云)"
-#: /home/saber/Develop/fcitx-cloudpinyin/build/po/tmp/fcitx-cloudpinyin.conf.in.h:2
+#: src/fcitx-cloudpinyin.conf.in:3
+msgid "Cloud Pinyin"
+msgstr "云拼音"
+
+#: src/fcitx-cloudpinyin.conf.in:4
msgid "Add Cloud Pinyin Support to Pinyin Input Method"
msgstr "为拼音输入法加入云拼音支持"
-#: unknown
-msgid "Baidu"
-msgstr "百度"
-
-#: /home/saber/Develop/fcitx-cloudpinyin/build/po/tmp/fcitx-cloudpinyin.conf.in.h:1
-msgid "Cloud Pinyin"
+#: src/fcitx-cloudpinyin.desc:1 src/fcitx-cloudpinyin.desc:7
+#: src/fcitx-cloudpinyin.desc:13 src/fcitx-cloudpinyin.desc:18
+msgid "CloudPinyin"
msgstr "云拼音"
-#: /home/saber/Develop/fcitx-cloudpinyin/src/fcitx-cloudpinyin.desc:5
+#: src/fcitx-cloudpinyin.desc:5
msgid "Cloud Pinyin Candidate Word Order"
msgstr "云拼音候选词顺序"
-#: /home/saber/Develop/fcitx-cloudpinyin/src/fcitx-cloudpinyin.desc:21
-msgid "Cloud Pinyin Source"
-msgstr "云拼音来源"
-
-# unknown
-msgid "CloudPinyin"
-msgstr "云拼音"
+#: src/fcitx-cloudpinyin.desc:11
+msgid "Minimum Length of Pinyin To Trigger Cloud Pinyin"
+msgstr "最小触发云拼音的拼音长度"
-#: /home/saber/Develop/fcitx-cloudpinyin/src/fcitx-cloudpinyin.desc:16
+#: src/fcitx-cloudpinyin.desc:16
msgid "Don't Show the 'via cloud' hint"
msgstr "不显示‘来自云’提示"
-#: unknown
-msgid "Google"
-msgstr "Google"
+#: src/fcitx-cloudpinyin.desc:21
+msgid "Cloud Pinyin Source"
+msgstr "云拼音来源"
-#: /home/saber/Develop/fcitx-cloudpinyin/src/fcitx-cloudpinyin.desc:11
-msgid "Minimum Length of Pinyin To Trigger Cloud Pinyin"
-msgstr "最小触发云拼音的拼音长度"
+#: src/fcitx-cloudpinyin.desc:23
+msgid "Sogou"
+msgstr "搜狗"
-#: unknown
+#: src/fcitx-cloudpinyin.desc:24
msgid "QQ"
msgstr "QQ"
-#: unknown
-msgid "Sogou"
-msgstr "搜狗"
+#: src/fcitx-cloudpinyin.desc:25
+msgid "Google"
+msgstr "Google"
-#~ msgid "Only use origin Pinyin to query the result"
-#~ msgstr "只使用原始拼音查询结果"
+#: src/fcitx-cloudpinyin.desc:26
+msgid "Baidu"
+msgstr "百度"
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/fcitx-cloudpinyin-0.3.0/po/zh_TW.po new/fcitx-cloudpinyin-0.3.1/po/zh_TW.po
--- old/fcitx-cloudpinyin-0.3.0/po/zh_TW.po 2012-09-12 16:00:12.000000000 +0200
+++ new/fcitx-cloudpinyin-0.3.1/po/zh_TW.po 2013-01-25 18:55:38.000000000 +0100
@@ -1,71 +1,69 @@
# SOME DESCRIPTIVE TITLE.
# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER
# This file is distributed under the same license as the PACKAGE package.
-#
+#
# Translators:
+# , 2012.
# Alisha , 2012.
msgid ""
msgstr ""
"Project-Id-Version: fcitx\n"
-"Report-Msgid-Bugs-To: \n"
-"POT-Creation-Date: 2012-08-29 18:07-0400\n"
-"PO-Revision-Date: 2012-01-26 16:05+0000\n"
+"Report-Msgid-Bugs-To: fcitx-dev@googlegroups.com\n"
+"POT-Creation-Date: 2012-12-01 18:57-0500\n"
+"PO-Revision-Date: 2012-09-11 00:12+0000\n"
"Last-Translator: Alisha \n"
-"Language-Team: Chinese (Taiwan) (http://www.transifex.net/projects/p/fcitx/"
-"language/zh_TW/)\n"
-"Language: zh_TW\n"
+"Language-Team: Chinese (Taiwan) (http://www.transifex.com/projects/p/fcitx/language/zh_TW/)\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
-"Plural-Forms: nplurals=1; plural=0\n"
+"Language: zh_TW\n"
+"Plural-Forms: nplurals=1; plural=0;\n"
-#: /home/saber/Develop/fcitx-cloudpinyin/build/po/../..//src/cloudpinyin.c:588
+#: src/cloudpinyin.c:607
msgid " (via cloud)"
msgstr "(來自雲)"
-#: /home/saber/Develop/fcitx-cloudpinyin/build/po/tmp/fcitx-cloudpinyin.conf.in.h:2
+#: src/fcitx-cloudpinyin.conf.in:3
+msgid "Cloud Pinyin"
+msgstr "雲拼音"
+
+#: src/fcitx-cloudpinyin.conf.in:4
msgid "Add Cloud Pinyin Support to Pinyin Input Method"
msgstr "為拼音輸入法加入雲拼音支援"
-#: unknown
-msgid "Baidu"
-msgstr ""
-
-#: /home/saber/Develop/fcitx-cloudpinyin/build/po/tmp/fcitx-cloudpinyin.conf.in.h:1
-msgid "Cloud Pinyin"
+#: src/fcitx-cloudpinyin.desc:1 src/fcitx-cloudpinyin.desc:7
+#: src/fcitx-cloudpinyin.desc:13 src/fcitx-cloudpinyin.desc:18
+msgid "CloudPinyin"
msgstr "雲拼音"
-#: /home/saber/Develop/fcitx-cloudpinyin/src/fcitx-cloudpinyin.desc:5
+#: src/fcitx-cloudpinyin.desc:5
msgid "Cloud Pinyin Candidate Word Order"
msgstr "雲拼音候選字順序"
-#: /home/saber/Develop/fcitx-cloudpinyin/src/fcitx-cloudpinyin.desc:21
-msgid "Cloud Pinyin Source"
-msgstr "雲拼音來源"
-
-# unknown
-msgid "CloudPinyin"
-msgstr "雲拼音"
+#: src/fcitx-cloudpinyin.desc:11
+msgid "Minimum Length of Pinyin To Trigger Cloud Pinyin"
+msgstr "最小觸發雲拼音的拼音長度"
-#: /home/saber/Develop/fcitx-cloudpinyin/src/fcitx-cloudpinyin.desc:16
+#: src/fcitx-cloudpinyin.desc:16
msgid "Don't Show the 'via cloud' hint"
msgstr "不顯示「來自雲」提示"
-#: unknown
-msgid "Google"
-msgstr "Google"
+#: src/fcitx-cloudpinyin.desc:21
+msgid "Cloud Pinyin Source"
+msgstr "雲拼音來源"
-#: /home/saber/Develop/fcitx-cloudpinyin/src/fcitx-cloudpinyin.desc:11
-msgid "Minimum Length of Pinyin To Trigger Cloud Pinyin"
-msgstr "最小觸發雲拼音的拼音長度"
+#: src/fcitx-cloudpinyin.desc:23
+msgid "Sogou"
+msgstr "搜狗"
-#: unknown
+#: src/fcitx-cloudpinyin.desc:24
msgid "QQ"
msgstr "QQ"
-#: unknown
-msgid "Sogou"
-msgstr "搜狗"
+#: src/fcitx-cloudpinyin.desc:25
+msgid "Google"
+msgstr "Google"
-#~ msgid "Only use origin Pinyin to query the result"
-#~ msgstr "只使用原始拼音查詢結果"
+#: src/fcitx-cloudpinyin.desc:26
+msgid "Baidu"
+msgstr "百度"
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/fcitx-cloudpinyin-0.3.0/src/CMakeLists.txt new/fcitx-cloudpinyin-0.3.1/src/CMakeLists.txt
--- old/fcitx-cloudpinyin-0.3.0/src/CMakeLists.txt 2012-09-12 16:00:12.000000000 +0200
+++ new/fcitx-cloudpinyin-0.3.1/src/CMakeLists.txt 2013-01-25 18:55:38.000000000 +0100
@@ -1,31 +1,27 @@
include_directories(
- ${PROJECT_BINARY_DIR}
- ${CMAKE_CURRENT_SOURCE_DIR}
- ${CURL_INCLUDE_DIRS}
- ${PTHREAD_INCLUDE_DIR}
- ${FCITX4_FCITX_INCLUDE_DIRS}
- ${FCITX4_FCITX_CONFIG_INCLUDE_DIRS}
- ${FCITX4_FCITX_UTILS_INCLUDE_DIRS}
- ${LIBINTL_INCLUDE_DIR}
-)
+ ${PROJECT_BINARY_DIR}
+ ${CMAKE_CURRENT_SOURCE_DIR}
+ ${CURL_INCLUDE_DIRS}
+ ${PTHREAD_INCLUDE_DIR}
+ ${FCITX4_FCITX_INCLUDE_DIRS}
+ ${FCITX4_FCITX_CONFIG_INCLUDE_DIRS}
+ ${FCITX4_FCITX_UTILS_INCLUDE_DIRS}
+ ${LIBINTL_INCLUDE_DIR}
+ )
link_directories(
- ${CURL_LIBRARY_DIRS}
-)
+ ${CURL_LIBRARY_DIRS}
+ )
set(FCITX_CLOUDPINYIN_SRCS
- cloudpinyin.c
- cloudpinyinconifg.c
- fetch.c
- parse.c
-)
+ cloudpinyin.c
+ cloudpinyinconifg.c
+ fetch.c
+ parse.c
+ )
-fcitx_add_addon(fcitx-cloudpinyin ${FCITX_CLOUDPINYIN_SRCS})
-target_link_libraries( fcitx-cloudpinyin
- ${CURL_LIBRARIES}
- ${LIBINTL_LIBRARIES}
- ${PTHREAD_LIBRARIES}
- )
-
-fcitx_add_addon_conf_file(fcitx-cloudpinyin.conf)
-fcitx_add_configdesc_file(fcitx-cloudpinyin.desc)
+fcitx_add_addon_full(cloudpinyin DESC
+ SOURCES ${FCITX_CLOUDPINYIN_SRCS}
+ LINK_LIBS ${CURL_LIBRARIES}
+ ${LIBINTL_LIBRARIES}
+ ${PTHREAD_LIBRARIES})
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/fcitx-cloudpinyin-0.3.0/src/cloudpinyin.c new/fcitx-cloudpinyin-0.3.1/src/cloudpinyin.c
--- old/fcitx-cloudpinyin-0.3.0/src/cloudpinyin.c 2012-09-12 16:00:12.000000000 +0200
+++ new/fcitx-cloudpinyin-0.3.1/src/cloudpinyin.c 2013-01-25 18:55:38.000000000 +0100
@@ -33,13 +33,23 @@
#include
#include
#include
-#include
+#include
#include "cloudpinyin.h"
#include "fetch.h"
#include "parse.h"
-#define CHECK_VALID_IM (im && \
+DEFINE_GET_ADDON("fcitx-sunpinyin", SunPinyin)
+DEFINE_GET_ADDON("fcitx-libpinyin", LibPinyin)
+DEFINE_GET_ADDON("fcitx-sogoupinyin", SogouPinyin)
+DEFINE_GET_AND_INVOKE_FUNC(SunPinyin, GetFullPinyin, 0)
+DEFINE_GET_AND_INVOKE_FUNC(SunPinyin, AddWord, 1)
+
+// Maybe not the right name, but doesn't matter....
+DEFINE_GET_AND_INVOKE_FUNC(LibPinyin, AddWord, 0)
+DEFINE_GET_AND_INVOKE_FUNC(SogouPinyin, AddWord, 0)
+
+#define CHECK_VALID_IM (im && \
strcmp(im->langCode, "zh_CN") == 0 && \
(strcmp(im->uniqueName, "pinyin") == 0 || \
strcmp(im->uniqueName, "pinyin-libpinyin") == 0 || \
@@ -51,8 +61,6 @@
#define CLOUDPINYIN_CHECK_PAGE_NUMBER 3
-#define LOGLEVEL DEBUG
-
typedef struct _CloudCandWord {
boolean filled;
uint64_t timestamp;
@@ -151,8 +159,7 @@
} else {
FcitxMessagesAddMessageAtLast(message, MSG_INPUT, "%s", str);
}
- if (string)
- free(string);
+ fcitx_utils_free(string);
FcitxInstanceUpdateClientSideUI(
cloudpinyin->owner, FcitxInstanceGetCurrentIC(cloudpinyin->owner));
}
@@ -279,7 +286,7 @@
if (inputString) {
CloudPinyinCache* cacheEntry = CloudPinyinCacheLookup(cloudpinyin, inputString);
- FcitxLog(LOGLEVEL, "%s", inputString);
+ FcitxLog(DEBUG, "%s", inputString);
if (cacheEntry == NULL)
CloudPinyinAddInputRequest(cloudpinyin, inputString);
_CloudPinyinAddCandidateWord(cloudpinyin, inputString);
@@ -347,13 +354,19 @@
void CloudPinyinProcessEvent(void* arg)
{
FcitxCloudPinyin* cloudpinyin = (FcitxCloudPinyin*) arg;
+ FcitxInstance* instance = cloudpinyin->owner;
+ if (!FD_ISSET(cloudpinyin->pipeRecv, FcitxInstanceGetReadFDSet(instance)))
+ return;
+
char c;
while (read(cloudpinyin->pipeRecv, &c, sizeof(char)) > 0);
pthread_mutex_lock(&cloudpinyin->finishQueueLock);
CurlQueue* queue;
queue = cloudpinyin->finishQueue;
+ /* this queue header is empty, so the check condition is "next" not null */
while (queue->next != NULL)
{
+ /* remove pivot from queue, thus pivot need to be free'd in HandleRequest */
CurlQueue* pivot = queue->next;
queue->next = queue->next->next;
CloudPinyinHandleRequest(cloudpinyin, pivot);
@@ -363,7 +376,48 @@
void CloudPinyinDestroy(void* arg)
{
+ FcitxCloudPinyin* cloudpinyin = (FcitxCloudPinyin*) arg;
+ char c = 1;
+ write(cloudpinyin->pipeNotify, &c, sizeof(char));
+ pthread_join(cloudpinyin->pid, NULL);
+ pthread_mutex_destroy(&cloudpinyin->pendingQueueLock);
+ pthread_mutex_destroy(&cloudpinyin->finishQueueLock);
+ while (cloudpinyin->cache)
+ {
+ CloudPinyinCache* head = cloudpinyin->cache;
+ HASH_DEL(cloudpinyin->cache, cloudpinyin->cache);
+ free(head->pinyin);
+ free(head->str);
+ free(head);
+ }
+ close(cloudpinyin->pipeRecv);
+ close(cloudpinyin->pipeNotify);
+
+ close(cloudpinyin->fetch->pipeRecv);
+ close(cloudpinyin->fetch->pipeNotify);
+ int i = 0;
+ for (i = 0; i < MAX_HANDLE; i ++) {
+ if (cloudpinyin->freeList[i].curl) {
+ curl_easy_cleanup(cloudpinyin->freeList[i].curl);
+ }
+ }
+
+ curl_multi_cleanup(cloudpinyin->fetch->curlm);
+#define _FREE_QUEUE(NAME) \
+ while(NAME) { \
+ CurlQueue* queue = NAME; \
+ NAME = NAME->next; \
+ fcitx_utils_free(queue->str); \
+ fcitx_utils_free(queue->pinyin); \
+ free(queue); \
+ }
+ _FREE_QUEUE(cloudpinyin->pendingQueue)
+ _FREE_QUEUE(cloudpinyin->finishQueue)
+ _FREE_QUEUE(cloudpinyin->fetch->queue)
+ FcitxConfigFree(&cloudpinyin->config.config);
+ free(cloudpinyin->fetch);
+ free(cloudpinyin);
}
void CloudPinyinReloadConfig(void* arg)
@@ -445,7 +499,7 @@
strToFree = GetCurrentString(cloudpinyin, &inputString);
if (inputString) {
- FcitxLog(LOGLEVEL, "fill: %s %s", inputString, queue->pinyin);
+ FcitxLog(DEBUG, "fill: %s %s", inputString, queue->pinyin);
if (strcmp(inputString, queue->pinyin) == 0)
{
if (CHECK_VALID_IM)
@@ -472,10 +526,8 @@
}
}
CloudPinyinReleaseCurlHandle(cloudpinyin, queue->curl);
- if (queue->str)
- free(queue->str);
- if (queue->pinyin)
- free(queue->pinyin);
+ fcitx_utils_free(queue->str);
+ fcitx_utils_free(queue->pinyin);
free(queue);
}
@@ -692,25 +744,25 @@
if (py) {
*py = 0;
- snprintf(FcitxInputStateGetOutputString(input), MAX_USER_INPUT, "%s%s", string, candWord->strWord);
+ snprintf(FcitxInputStateGetOutputString(input),
+ MAX_USER_INPUT, "%s%s", string, candWord->strWord);
FcitxIM* im = FcitxInstanceGetCurrentIM(cloudpinyin->owner);
- FcitxModuleFunctionArg args;
- args.args[0] = FcitxInputStateGetOutputString(input);
- if (im)
- {
- if (strcmp(im->uniqueName, "sunpinyin") == 0)
- FcitxModuleInvokeFunctionByName(cloudpinyin->owner, "fcitx-sunpinyin", 1, args);
- else if (strcmp(im->uniqueName, "shuangpin") == 0 || strcmp(im->uniqueName, "pinyin") == 0)
- FcitxModuleInvokeFunctionByName(cloudpinyin->owner, "fcitx-pinyin", 7, args);
- else if (strcmp(im->uniqueName, "pinyin-libpinyin") == 0 ||
- strcmp(im->uniqueName, "shuangpin-libpinyin") == 0)
- {
- FcitxModuleInvokeFunctionByName(cloudpinyin->owner, "fcitx-libpinyin", 0, args);
+ if (im) {
+ char *output_string = FcitxInputStateGetOutputString(input);
+ FCITX_DEF_MODULE_ARGS(args, output_string);
+ if (strcmp(im->uniqueName, "sunpinyin") == 0) {
+ FcitxSunPinyinInvokeAddWord(cloudpinyin->owner, args);
+ } else if (strcmp(im->uniqueName, "shuangpin") == 0 ||
+ strcmp(im->uniqueName, "pinyin") == 0) {
+ FcitxPinyinInvokeAddUserPhrase(cloudpinyin->owner, args);
+ } else if (strcmp(im->uniqueName, "pinyin-libpinyin") == 0 ||
+ strcmp(im->uniqueName, "shuangpin-libpinyin") == 0) {
+ FcitxLibPinyinInvokeAddWord(cloudpinyin->owner, args);
}
else if (strcmp(im->uniqueName, "sogou-pinyin") == 0)
{
- FcitxModuleInvokeFunctionByName(cloudpinyin->owner, "fcitx-sogoupinyin", 0, args);
+ FcitxSogouPinyinInvokeAddWord(cloudpinyin->owner, args);
}
}
}
@@ -789,17 +841,14 @@
if (*lastpos != '\0') {
char* result = NULL;
- FcitxModuleFunctionArg arg;
- arg.args[0] = lastpos;
boolean isshuangpin = false;
if (strcmp(im->uniqueName, "sunpinyin") == 0) {
- boolean issp = false;
- arg.args[1] = &issp;
- result = FcitxModuleInvokeFunctionByName(cloudpinyin->owner, "fcitx-sunpinyin", 0, arg);
- isshuangpin = issp;
+ FCITX_DEF_MODULE_ARGS(args, lastpos, &isshuangpin);
+ result = FcitxSunPinyinInvokeGetFullPinyin(
+ cloudpinyin->owner, args);
} else if (strcmp(im->uniqueName, "shuangpin") == 0) {
isshuangpin = true;
- result = InvokeFunction(cloudpinyin->owner, FCITX_PINYIN, SP2QP, arg);
+ result = FcitxPinyinSP2QP(cloudpinyin->owner, lastpos);
}
if (isshuangpin) {
if (result) {
@@ -822,11 +871,9 @@
}
}
}
-
lastpos = pinyin + 1;
}
pinyin ++;
-
} while(endflag);
free(string);
/* no pinyin append, return NULL for off it */
@@ -846,10 +893,8 @@
const char* ime_patch_key = "ime_patch_key = \"";
size_t len = strlen(str);
if (len == SOGOU_KEY_LENGTH + strlen(ime_patch_key) + 1
- && strncmp(str, ime_patch_key, strlen(ime_patch_key)) == 0
- && str[len - 1] == '\"'
- )
- {
+ && strncmp(str, ime_patch_key, strlen(ime_patch_key)) == 0
+ && str[len - 1] == '\"') {
sscanf(str,"ime_patch_key = \"%s\"", cloudpinyin->key);
cloudpinyin->initialized = true;
cloudpinyin->key[SOGOU_KEY_LENGTH] = '\0';
@@ -861,8 +906,7 @@
void CloudPinyinHookForNewRequest(void* arg)
{
FcitxCloudPinyin* cloudpinyin = (FcitxCloudPinyin*) arg;
- if (!cloudpinyin->initialized && !cloudpinyin->isrequestkey)
- {
+ if (!cloudpinyin->initialized && !cloudpinyin->isrequestkey) {
CloudPinyinRequestKey(cloudpinyin);
}
}
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/fcitx-cloudpinyin-0.3.0/src/fetch.c new/fcitx-cloudpinyin-0.3.1/src/fetch.c
--- old/fcitx-cloudpinyin-0.3.0/src/fetch.c 2012-09-12 16:00:12.000000000 +0200
+++ new/fcitx-cloudpinyin-0.3.1/src/fetch.c 2013-01-25 18:55:38.000000000 +0100
@@ -43,9 +43,14 @@
curl_multi_setopt(fetch->curlm, CURLMOPT_MAXCONNECTS, MAX_HANDLE);
while (true) {
-
+ boolean endflag = false;
char c;
- while (read(fetch->pipeRecv, &c, sizeof(char)) > 0);
+ while (read(fetch->pipeRecv, &c, sizeof(char)) > 0) {
+ if (c == 1)
+ endflag = true;
+ }
+ if (endflag)
+ break;
FetchProcessPendingRequest(fetch);
FetchProcessEvent(fetch);
--
To unsubscribe, e-mail: opensuse-commit+unsubscribe@opensuse.org
For additional commands, e-mail: opensuse-commit+help@opensuse.org