summaryrefslogtreecommitdiffstats
path: root/src/PYPPhoneticEditor.cc
diff options
context:
space:
mode:
authorPeng Wu <alexepico@gmail.com>2014-05-21 09:46:16 +0800
committerPeng Wu <alexepico@gmail.com>2014-05-21 09:46:16 +0800
commit7a98868d07581655b7a11c84005ec9cef7d50539 (patch)
treeba2f8ad45139916ebc2882a820d165a31e5a2765 /src/PYPPhoneticEditor.cc
parent7813d0b1711f08b0164242499c6ac02d30fab966 (diff)
downloadibus-libpinyin-7a98868d07581655b7a11c84005ec9cef7d50539.tar.gz
ibus-libpinyin-7a98868d07581655b7a11c84005ec9cef7d50539.tar.xz
ibus-libpinyin-7a98868d07581655b7a11c84005ec9cef7d50539.zip
remove LibPinyin* class prefix
Diffstat (limited to 'src/PYPPhoneticEditor.cc')
-rw-r--r--src/PYPPhoneticEditor.cc64
1 files changed, 32 insertions, 32 deletions
diff --git a/src/PYPPhoneticEditor.cc b/src/PYPPhoneticEditor.cc
index dd18166..0be3a7b 100644
--- a/src/PYPPhoneticEditor.cc
+++ b/src/PYPPhoneticEditor.cc
@@ -26,7 +26,7 @@
using namespace PY;
/* init static members */
-LibPinyinPhoneticEditor::LibPinyinPhoneticEditor (PinyinProperties &props,
+PhoneticEditor::PhoneticEditor (PinyinProperties &props,
Config &config):
Editor (props, config),
m_pinyin_len (0),
@@ -34,11 +34,11 @@ LibPinyinPhoneticEditor::LibPinyinPhoneticEditor (PinyinProperties &props,
{
}
-LibPinyinPhoneticEditor::~LibPinyinPhoneticEditor (){
+PhoneticEditor::~PhoneticEditor (){
}
gboolean
-LibPinyinPhoneticEditor::processSpace (guint keyval, guint keycode,
+PhoneticEditor::processSpace (guint keyval, guint keycode,
guint modifiers)
{
if (!m_text)
@@ -58,7 +58,7 @@ LibPinyinPhoneticEditor::processSpace (guint keyval, guint keycode,
}
gboolean
-LibPinyinPhoneticEditor::processFunctionKey (guint keyval, guint keycode, guint modifiers)
+PhoneticEditor::processFunctionKey (guint keyval, guint keycode, guint modifiers)
{
if (m_text.empty ())
return FALSE;
@@ -163,19 +163,19 @@ LibPinyinPhoneticEditor::processFunctionKey (guint keyval, guint keycode, guint
}
gboolean
-LibPinyinPhoneticEditor::processKeyEvent (guint keyval, guint keycode, guint modifiers)
+PhoneticEditor::processKeyEvent (guint keyval, guint keycode, guint modifiers)
{
return FALSE;
}
void
-LibPinyinPhoneticEditor::updateLookupTableFast (void)
+PhoneticEditor::updateLookupTableFast (void)
{
Editor::updateLookupTableFast (m_lookup_table, TRUE);
}
void
-LibPinyinPhoneticEditor::updateLookupTable (void)
+PhoneticEditor::updateLookupTable (void)
{
m_lookup_table.clear ();
@@ -188,7 +188,7 @@ LibPinyinPhoneticEditor::updateLookupTable (void)
}
gboolean
-LibPinyinPhoneticEditor::fillLookupTableByPage (void)
+PhoneticEditor::fillLookupTableByPage (void)
{
guint len = 0;
pinyin_get_n_candidate (m_instance, &len);
@@ -229,7 +229,7 @@ LibPinyinPhoneticEditor::fillLookupTableByPage (void)
}
void
-LibPinyinPhoneticEditor::pageUp (void)
+PhoneticEditor::pageUp (void)
{
if (G_LIKELY (m_lookup_table.pageUp ())) {
updateLookupTableFast ();
@@ -239,7 +239,7 @@ LibPinyinPhoneticEditor::pageUp (void)
}
void
-LibPinyinPhoneticEditor::pageDown (void)
+PhoneticEditor::pageDown (void)
{
if (G_LIKELY((m_lookup_table.pageDown ()) ||
(fillLookupTableByPage () && m_lookup_table.pageDown()))) {
@@ -250,7 +250,7 @@ LibPinyinPhoneticEditor::pageDown (void)
}
void
-LibPinyinPhoneticEditor::cursorUp (void)
+PhoneticEditor::cursorUp (void)
{
if (G_LIKELY (m_lookup_table.cursorUp ())) {
updateLookupTableFast ();
@@ -260,7 +260,7 @@ LibPinyinPhoneticEditor::cursorUp (void)
}
void
-LibPinyinPhoneticEditor::cursorDown (void)
+PhoneticEditor::cursorDown (void)
{
if (G_LIKELY ((m_lookup_table.cursorPos () == m_lookup_table.size() - 1) &&
(fillLookupTableByPage () == FALSE))) {
@@ -275,13 +275,13 @@ LibPinyinPhoneticEditor::cursorDown (void)
}
void
-LibPinyinPhoneticEditor::candidateClicked (guint index, guint button, guint state)
+PhoneticEditor::candidateClicked (guint index, guint button, guint state)
{
selectCandidateInPage (index);
}
void
-LibPinyinPhoneticEditor::reset (void)
+PhoneticEditor::reset (void)
{
m_pinyin_len = 0;
m_lookup_table.clear ();
@@ -292,7 +292,7 @@ LibPinyinPhoneticEditor::reset (void)
}
void
-LibPinyinPhoneticEditor::update (void)
+PhoneticEditor::update (void)
{
guint lookup_cursor = getLookupCursor ();
pinyin_guess_candidates (m_instance, lookup_cursor);
@@ -303,14 +303,14 @@ LibPinyinPhoneticEditor::update (void)
}
void
-LibPinyinPhoneticEditor::commit (const gchar *str)
+PhoneticEditor::commit (const gchar *str)
{
StaticText text(str);
commitText (text);
}
guint
-LibPinyinPhoneticEditor::getPinyinCursor ()
+PhoneticEditor::getPinyinCursor ()
{
guint len = 0;
pinyin_get_n_pinyin (m_instance, &len);
@@ -335,7 +335,7 @@ LibPinyinPhoneticEditor::getPinyinCursor ()
}
guint
-LibPinyinPhoneticEditor::getLookupCursor (void)
+PhoneticEditor::getLookupCursor (void)
{
guint len = 0;
pinyin_get_n_pinyin (m_instance, &len);
@@ -348,7 +348,7 @@ LibPinyinPhoneticEditor::getLookupCursor (void)
}
gboolean
-LibPinyinPhoneticEditor::selectCandidate (guint i)
+PhoneticEditor::selectCandidate (guint i)
{
guint len = 0;
pinyin_get_n_candidate (m_instance, &len);
@@ -401,7 +401,7 @@ LibPinyinPhoneticEditor::selectCandidate (guint i)
}
gboolean
-LibPinyinPhoneticEditor::selectCandidateInPage (guint i)
+PhoneticEditor::selectCandidateInPage (guint i)
{
guint page_size = m_lookup_table.pageSize ();
guint cursor_pos = m_lookup_table.cursorPos ();
@@ -414,7 +414,7 @@ LibPinyinPhoneticEditor::selectCandidateInPage (guint i)
}
gboolean
-LibPinyinPhoneticEditor::removeCharBefore (void)
+PhoneticEditor::removeCharBefore (void)
{
if (G_UNLIKELY (m_cursor == 0))
return FALSE;
@@ -429,7 +429,7 @@ LibPinyinPhoneticEditor::removeCharBefore (void)
}
gboolean
-LibPinyinPhoneticEditor::removeCharAfter (void)
+PhoneticEditor::removeCharAfter (void)
{
if (G_UNLIKELY (m_cursor == m_text.length ()))
return FALSE;
@@ -443,7 +443,7 @@ LibPinyinPhoneticEditor::removeCharAfter (void)
}
gboolean
-LibPinyinPhoneticEditor::moveCursorLeft (void)
+PhoneticEditor::moveCursorLeft (void)
{
if (G_UNLIKELY (m_cursor == 0))
return FALSE;
@@ -454,7 +454,7 @@ LibPinyinPhoneticEditor::moveCursorLeft (void)
}
gboolean
-LibPinyinPhoneticEditor::moveCursorRight (void)
+PhoneticEditor::moveCursorRight (void)
{
if (G_UNLIKELY (m_cursor == m_text.length ()))
return FALSE;
@@ -465,7 +465,7 @@ LibPinyinPhoneticEditor::moveCursorRight (void)
}
gboolean
-LibPinyinPhoneticEditor::moveCursorToBegin (void)
+PhoneticEditor::moveCursorToBegin (void)
{
if (G_UNLIKELY (m_cursor == 0))
return FALSE;
@@ -476,7 +476,7 @@ LibPinyinPhoneticEditor::moveCursorToBegin (void)
}
gboolean
-LibPinyinPhoneticEditor::moveCursorToEnd (void)
+PhoneticEditor::moveCursorToEnd (void)
{
if (G_UNLIKELY (m_cursor == m_text.length ()))
return FALSE;
@@ -490,7 +490,7 @@ LibPinyinPhoneticEditor::moveCursorToEnd (void)
/* move cursor by word functions */
guint
-LibPinyinPhoneticEditor::getCursorLeftByWord (void)
+PhoneticEditor::getCursorLeftByWord (void)
{
guint16 cursor = 0;
@@ -528,7 +528,7 @@ LibPinyinPhoneticEditor::getCursorLeftByWord (void)
}
guint
-LibPinyinPhoneticEditor::getCursorRightByWord (void)
+PhoneticEditor::getCursorRightByWord (void)
{
guint16 cursor = 0;
@@ -545,7 +545,7 @@ LibPinyinPhoneticEditor::getCursorRightByWord (void)
}
gboolean
-LibPinyinPhoneticEditor::removeWordBefore (void)
+PhoneticEditor::removeWordBefore (void)
{
if (G_UNLIKELY (m_cursor == 0))
return FALSE;
@@ -559,7 +559,7 @@ LibPinyinPhoneticEditor::removeWordBefore (void)
}
gboolean
-LibPinyinPhoneticEditor::removeWordAfter (void)
+PhoneticEditor::removeWordAfter (void)
{
if (G_UNLIKELY (m_cursor == m_text.length ()))
return FALSE;
@@ -572,7 +572,7 @@ LibPinyinPhoneticEditor::removeWordAfter (void)
}
gboolean
-LibPinyinPhoneticEditor::moveCursorLeftByWord (void)
+PhoneticEditor::moveCursorLeftByWord (void)
{
if (G_UNLIKELY (m_cursor == 0))
return FALSE;
@@ -585,7 +585,7 @@ LibPinyinPhoneticEditor::moveCursorLeftByWord (void)
}
gboolean
-LibPinyinPhoneticEditor::moveCursorRightByWord (void)
+PhoneticEditor::moveCursorRightByWord (void)
{
if (G_UNLIKELY (m_cursor == m_text.length ()))
return FALSE;