diff options
author | 2011-12-15 22:29:05 +0900 | |
---|---|---|
committer | 2011-12-16 17:32:53 +0900 | |
commit | 744dab691e45ff8c5ca9745ee673f50060bcb7a9 (patch) | |
tree | b8210ec5210fb7544fc417c5d3d9ea3755e20fbc /native/src/proximity_info.cpp | |
parent | a7e5a5a6b9ed1367a4bb81c874d0fde7de85a787 (diff) | |
download | latinime-744dab691e45ff8c5ca9745ee673f50060bcb7a9.tar.gz latinime-744dab691e45ff8c5ca9745ee673f50060bcb7a9.tar.xz latinime-744dab691e45ff8c5ca9745ee673f50060bcb7a9.zip |
Prepare for proximity + two words suggestion
Change-Id: I3637f9bec1f4a3c5953498c4562e1f17a7bf593c
Diffstat (limited to 'native/src/proximity_info.cpp')
-rw-r--r-- | native/src/proximity_info.cpp | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/native/src/proximity_info.cpp b/native/src/proximity_info.cpp index 6857caf00..6e26da276 100644 --- a/native/src/proximity_info.cpp +++ b/native/src/proximity_info.cpp @@ -100,9 +100,17 @@ inline int ProximityInfo::getStartIndexFromCoordinates(const int x, const int y) } bool ProximityInfo::hasSpaceProximity(const int x, const int y) const { + if (x < 0 || y < 0) { + if (DEBUG_DICT) { + LOGI("HasSpaceProximity: Illegal coordinates (%d, %d)", x, y); + assert(true); + } + return false; + } + const int startIndex = getStartIndexFromCoordinates(x, y); if (DEBUG_PROXIMITY_INFO) { - LOGI("hasSpaceProximity: index %d", startIndex); + LOGI("hasSpaceProximity: index %d, %d, %d", startIndex, x, y); } for (int i = 0; i < MAX_PROXIMITY_CHARS_SIZE; ++i) { if (DEBUG_PROXIMITY_INFO) { |