You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
59 lines
2.1 KiB
59 lines
2.1 KiB
18 years ago
|
--- libchewing-0.3.0/src/chewingio.c.4-bz216377 2006-11-21 15:45:08.000000000 +1000
|
||
|
+++ libchewing-0.3.0/src/chewingio.c 2006-11-21 15:45:08.000000000 +1000
|
||
|
@@ -860,6 +860,44 @@
|
||
|
return 0;
|
||
|
}
|
||
|
|
||
|
+CHEWING_API int chewing_handle_PageUp( ChewingContext *ctx )
|
||
|
+{
|
||
|
+ ChewingData *pgdata = ctx->data;
|
||
|
+ ChewingOutput *pgo = ctx->output;
|
||
|
+ int keystrokeRtn = KEYSTROKE_ABSORB;
|
||
|
+
|
||
|
+ CheckAndResetRange( pgdata );
|
||
|
+
|
||
|
+ if ( ! ChewingIsEntering( pgdata ) ) {
|
||
|
+ keystrokeRtn = KEYSTROKE_IGNORE;
|
||
|
+ }
|
||
|
+ else if ( ! pgdata->bSelect ) {
|
||
|
+ pgdata->chiSymbolCursor = pgdata->chiSymbolBufLen;
|
||
|
+ pgdata->cursor = pgdata->nPhoneSeq;
|
||
|
+ }
|
||
|
+ MakeOutputWithRtn( pgo, pgdata, keystrokeRtn );
|
||
|
+ return 0;
|
||
|
+}
|
||
|
+
|
||
|
+CHEWING_API int chewing_handle_PageDown( ChewingContext *ctx )
|
||
|
+{
|
||
|
+ ChewingData *pgdata = ctx->data;
|
||
|
+ ChewingOutput *pgo = ctx->output;
|
||
|
+ int keystrokeRtn = KEYSTROKE_ABSORB;
|
||
|
+
|
||
|
+ CheckAndResetRange( pgdata );
|
||
|
+
|
||
|
+ if ( ! ChewingIsEntering( pgdata ) ) {
|
||
|
+ keystrokeRtn = KEYSTROKE_IGNORE;
|
||
|
+ }
|
||
|
+ else if ( ! pgdata->bSelect ) {
|
||
|
+ pgdata->chiSymbolCursor = pgdata->chiSymbolBufLen;
|
||
|
+ pgdata->cursor = pgdata->nPhoneSeq;
|
||
|
+ }
|
||
|
+ MakeOutputWithRtn( pgo, pgdata, keystrokeRtn );
|
||
|
+ return 0;
|
||
|
+}
|
||
|
+
|
||
|
/* Dvorak <-> Qwerty keyboard layout converter */
|
||
|
static int dvorak_convert( int key )
|
||
|
{
|
||
|
--- libchewing-0.3.0/include/chewingio.h.4-bz216377 2006-11-21 15:45:46.000000000 +1000
|
||
|
+++ libchewing-0.3.0/include/chewingio.h 2006-11-21 15:45:03.000000000 +1000
|
||
|
@@ -37,6 +37,8 @@
|
||
|
CHEWING_API int chewing_handle_Up( ChewingContext * );
|
||
|
CHEWING_API int chewing_handle_Home( ChewingContext * );
|
||
|
CHEWING_API int chewing_handle_End( ChewingContext * );
|
||
|
+CHEWING_API int chewing_handle_PageUp( ChewingContext * );
|
||
|
+CHEWING_API int chewing_handle_PageDown( ChewingContext * );
|
||
|
CHEWING_API int chewing_handle_Down( ChewingContext * );
|
||
|
CHEWING_API int chewing_handle_Capslock( ChewingContext * );
|
||
|
CHEWING_API int chewing_handle_Default( ChewingContext *, int key );
|