Gitweb links:
...log
http://git.netsurf-browser.org/netsurf.git/shortlog/0cdc1029460cf86ec7186...
...commit
http://git.netsurf-browser.org/netsurf.git/commit/0cdc1029460cf86ec7186de...
...tree
http://git.netsurf-browser.org/netsurf.git/tree/0cdc1029460cf86ec7186de4c...
The branch, master has been updated
via 0cdc1029460cf86ec7186de4ca46bd3e4637bc3a (commit)
via ee32aa43feea16911c041436d7c3554b23146387 (commit)
via 77cea75e51ba95bb421bdbd8d9c3183408d5a872 (commit)
via 4bf23fc2173740e93ee1d81fb31deedc8755768b (commit)
from 0793ae25e31d16e691d6a1af9ac31eb42b0420b2 (commit)
Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.
- Log -----------------------------------------------------------------
commitdiff
http://git.netsurf-browser.org/netsurf.git/commit/?id=0cdc1029460cf86ec71...
commit 0cdc1029460cf86ec7186de4ca46bd3e4637bc3a
Author: Michael Drake <tlsa(a)netsurf-browser.org>
Commit: Michael Drake <tlsa(a)netsurf-browser.org>
Remove unused variable.
diff --git a/amiga/icon.c b/amiga/icon.c
index d0e1c84..01802d3 100644
--- a/amiga/icon.c
+++ b/amiga/icon.c
@@ -144,7 +144,6 @@ bool amiga_icon_convert(struct content *c)
int err;
uint8 r, g, b, a;
ULONG offset;
- const char *url;
char *filename = NULL;
char *p;
ULONG trans, pals1;
commitdiff
http://git.netsurf-browser.org/netsurf.git/commit/?id=ee32aa43feea16911c0...
commit ee32aa43feea16911c041436d7c3554b23146387
Author: Michael Drake <tlsa(a)netsurf-browser.org>
Commit: Michael Drake <tlsa(a)netsurf-browser.org>
Remove an unused variable.
diff --git a/amiga/gui.c b/amiga/gui.c
index 19064f9..11f874b 100644
--- a/amiga/gui.c
+++ b/amiga/gui.c
@@ -638,7 +638,6 @@ static nsurl *gui_get_resource_url(const char *path)
{
char buf[1024];
char path2[1024];
- char *raw;
nsurl *url = NULL;
if(ami_locate_resource(buf, path) == false)
commitdiff
http://git.netsurf-browser.org/netsurf.git/commit/?id=77cea75e51ba95bb421...
commit 77cea75e51ba95bb421bdbd8d9c3183408d5a872
Author: Michael Drake <tlsa(a)netsurf-browser.org>
Commit: Michael Drake <tlsa(a)netsurf-browser.org>
Remove unused variable.
diff --git a/atari/misc.c b/atari/misc.c
index 3e4411e..e689b82 100755
--- a/atari/misc.c
+++ b/atari/misc.c
@@ -210,7 +210,6 @@ static nserror load_icon_callback(hlcache_handle *handle,
hlcache_handle *load_icon(const char *name, hlcache_handle_callback cb,
void * pw )
{
- const char *icon_url = NULL;
hlcache_handle *c;
nserror err;
nsurl *icon_nsurl;
commitdiff
http://git.netsurf-browser.org/netsurf.git/commit/?id=4bf23fc2173740e93ee...
commit 4bf23fc2173740e93ee1d81fb31deedc8755768b
Author: Michael Drake <tlsa(a)netsurf-browser.org>
Commit: Michael Drake <tlsa(a)netsurf-browser.org>
Fix line endings.
diff --git a/atari/misc.c b/atari/misc.c
index 849eec9..3e4411e 100755
--- a/atari/misc.c
+++ b/atari/misc.c
@@ -1,97 +1,97 @@
-/*
- * Copyright 2010 Ole Loots <ole(a)monochrom.net>
- *
- * This file is part of NetSurf,
http://www.netsurf-browser.org/
- *
- * NetSurf is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; version 2 of the License.
- *
- * NetSurf is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program. If not, see <
http://www.gnu.org/licenses/>.
- */
+/*
+ * Copyright 2010 Ole Loots <ole(a)monochrom.net>
+ *
+ * This file is part of NetSurf,
http://www.netsurf-browser.org/
+ *
+ * NetSurf is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; version 2 of the License.
+ *
+ * NetSurf is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program. If not, see <
http://www.gnu.org/licenses/>.
+ */
#include <assert.h>
-#include <stdlib.h>
+#include <stdlib.h>
#include <stdio.h>
-#include <stdbool.h>
-#include <string.h>
+#include <stdbool.h>
+#include <string.h>
-#include <sys/types.h>
+#include <sys/types.h>
#include <mint/osbind.h>
#include "content/content.h"
-#include "content/hlcache.h"
-#include "desktop/cookie_manager.h"
+#include "content/hlcache.h"
+#include "desktop/cookie_manager.h"
#include "desktop/mouse.h"
#include "desktop/tree.h"
-#include "utils/nsoption.h"
-#include "utils/messages.h"
-#include "utils/utils.h"
-#include "utils/log.h"
+#include "utils/nsoption.h"
+#include "utils/messages.h"
+#include "utils/utils.h"
+#include "utils/log.h"
#include "content/fetch.h"
-
-#include "atari/gui.h"
-#include "atari/toolbar.h"
-
+
+#include "atari/gui.h"
+#include "atari/toolbar.h"
+
#include "atari/misc.h"
#include "atari/encoding.h"
#include "atari/gemtk/gemtk.h"
-#include "cflib.h"
-
-extern void * h_gem_rsrc;
+#include "cflib.h"
+
+extern void * h_gem_rsrc;
struct is_process_running_callback_data {
const char * fname;
bool found;
};
-
-void warn_user(const char *warning, const char *detail)
-{
- size_t len = 1 + ((warning != NULL) ? strlen(messages_get(warning)) :
- 0) + ((detail != 0) ? strlen(detail) : 0);
- char message[len];
- snprintf(message, len, messages_get(warning), detail);
+
+void warn_user(const char *warning, const char *detail)
+{
+ size_t len = 1 + ((warning != NULL) ? strlen(messages_get(warning)) :
+ 0) + ((detail != 0) ? strlen(detail) : 0);
+ char message[len];
+ snprintf(message, len, messages_get(warning), detail);
printf("%s\n", message);
- gemtk_msg_box_show(GEMTK_MSG_BOX_ALERT, message);
-}
-
-void die(const char *error)
+ gemtk_msg_box_show(GEMTK_MSG_BOX_ALERT, message);
+}
+
+void die(const char *error)
{
- printf("%s\n", error);
+ printf("%s\n", error);
gemtk_msg_box_show(GEMTK_MSG_BOX_ALERT, error);
- exit(1);
-}
-
-
-struct gui_window * find_guiwin_by_aes_handle(short handle){
-
- struct gui_window * gw;
- gw = window_list;
-
- if( handle == 0 ){
+ exit(1);
+}
+
+
+struct gui_window * find_guiwin_by_aes_handle(short handle){
+
+ struct gui_window * gw;
+ gw = window_list;
+
+ if( handle == 0 ){
return( NULL );
}
- while(gw != NULL) {
+ while(gw != NULL) {
if(gw->root->win != NULL
- && gemtk_wm_get_handle(gw->root->win) == handle) {
- return(gw);
- }
- else
- gw = gw->next;
- }
-
- return( NULL );
+ && gemtk_wm_get_handle(gw->root->win) == handle) {
+ return(gw);
+ }
+ else
+ gw = gw->next;
+ }
+
+ return( NULL );
}
-
-
+
+
static int scan_process_list(scan_process_callback cb, void *data)
{
int pid, count = 0;
@@ -186,9 +186,9 @@ bool is_process_running(const char * name)
scan_process_list(proc_running_callback, &data);
return( (data.found==1) ? true : false );
-}
-
-
+}
+
+
/**
* Callback for load_icon(). Should be removed once bitmaps get loaded directly
* from disc
@@ -251,21 +251,21 @@ hlcache_handle *load_icon(const char *name, hlcache_handle_callback
cb,
}
return c;
-}
-
-void gem_set_cursor( MFORM_EX * cursor )
-{
- static unsigned char flags = 255;
- static int number = 255;
- if( flags == cursor->flags && number == cursor->number )
- return;
+}
+
+void gem_set_cursor( MFORM_EX * cursor )
+{
+ static unsigned char flags = 255;
+ static int number = 255;
+ if( flags == cursor->flags && number == cursor->number )
+ return;
if( cursor->flags & MFORM_EX_FLAG_USERFORM ) {
- gemtk_obj_mouse_sprite(cursor->tree, cursor->number);
- } else {
- graf_mouse(cursor->number, NULL );
- }
- number = cursor->number;
- flags = cursor->flags;
+ gemtk_obj_mouse_sprite(cursor->tree, cursor->number);
+ } else {
+ graf_mouse(cursor->number, NULL );
+ }
+ number = cursor->number;
+ flags = cursor->flags;
}
/**
@@ -277,7 +277,7 @@ void gem_set_cursor( MFORM_EX * cursor )
*/
long nkc_to_input_key(short nkc, long * ucs4_out)
{
- unsigned char ascii = (nkc & 0xFF);
+ unsigned char ascii = (nkc & 0xFF);
long ik = 0;
// initialize result:
@@ -290,131 +290,131 @@ long nkc_to_input_key(short nkc, long * ucs4_out)
if( ((nkc & NKF_CTRL) == NKF_CTRL) && ((nkc & (NKF_SHIFT))!=0) ) {
}
- /* cntrl key only: */
- else if( (nkc & NKF_CTRL) == NKF_CTRL ) {
- switch ( ascii ) {
- case 'A':
- ik = KEY_SELECT_ALL;
- break;
-
- case 'C':
- ik = KEY_COPY_SELECTION;
- break;
-
- case 'X':
- ik = KEY_CUT_SELECTION;
- break;
-
- case 'V':
- ik = KEY_PASTE;
- break;
-
- default:
- break;
- }
+ /* cntrl key only: */
+ else if( (nkc & NKF_CTRL) == NKF_CTRL ) {
+ switch ( ascii ) {
+ case 'A':
+ ik = KEY_SELECT_ALL;
+ break;
+
+ case 'C':
+ ik = KEY_COPY_SELECTION;
+ break;
+
+ case 'X':
+ ik = KEY_CUT_SELECTION;
+ break;
+
+ case 'V':
+ ik = KEY_PASTE;
+ break;
+
+ default:
+ break;
+ }
}
- /* shift key only: */
+ /* shift key only: */
else if( (nkc & NKF_SHIFT) != 0 ) {
- switch( ascii ) {
- case NK_TAB:
- ik = KEY_SHIFT_TAB;
- break;
-
- case NK_LEFT:
- ik = KEY_LINE_START;
- break;
-
- case NK_RIGHT:
- ik = KEY_LINE_END;
- break;
-
- case NK_UP:
- ik = KEY_PAGE_UP;
- break;
-
- case NK_DOWN:
- ik = KEY_PAGE_DOWN;
- break;
-
- default:
- break;
- }
+ switch( ascii ) {
+ case NK_TAB:
+ ik = KEY_SHIFT_TAB;
+ break;
+
+ case NK_LEFT:
+ ik = KEY_LINE_START;
+ break;
+
+ case NK_RIGHT:
+ ik = KEY_LINE_END;
+ break;
+
+ case NK_UP:
+ ik = KEY_PAGE_UP;
+ break;
+
+ case NK_DOWN:
+ ik = KEY_PAGE_DOWN;
+ break;
+
+ default:
+ break;
+ }
}
- /* No modifier keys: */
- else {
+ /* No modifier keys: */
+ else {
switch( ascii ) {
case NK_INS:
ik = KEY_PASTE;
break;
-
- case NK_BS:
- ik = KEY_DELETE_LEFT;
- break;
-
- case NK_DEL:
- ik = KEY_DELETE_RIGHT;
- break;
-
- case NK_TAB:
- ik = KEY_TAB;
- break;
-
-
- case NK_ENTER:
- ik = KEY_NL;
- break;
-
- case NK_RET:
- ik = KEY_CR;
- break;
-
- case NK_ESC:
- ik = KEY_ESCAPE;
- break;
-
- case NK_CLRHOME:
- ik = KEY_TEXT_START;
- break;
-
- case NK_RIGHT:
- ik = KEY_RIGHT;
- break;
-
- case NK_LEFT:
- ik = KEY_LEFT;
- break;
-
- case NK_UP:
- ik = KEY_UP;
+
+ case NK_BS:
+ ik = KEY_DELETE_LEFT;
+ break;
+
+ case NK_DEL:
+ ik = KEY_DELETE_RIGHT;
+ break;
+
+ case NK_TAB:
+ ik = KEY_TAB;
+ break;
+
+
+ case NK_ENTER:
+ ik = KEY_NL;
+ break;
+
+ case NK_RET:
+ ik = KEY_CR;
+ break;
+
+ case NK_ESC:
+ ik = KEY_ESCAPE;
+ break;
+
+ case NK_CLRHOME:
+ ik = KEY_TEXT_START;
+ break;
+
+ case NK_RIGHT:
+ ik = KEY_RIGHT;
+ break;
+
+ case NK_LEFT:
+ ik = KEY_LEFT;
+ break;
+
+ case NK_UP:
+ ik = KEY_UP;
break;
case NK_UNDO:
ik = KEY_UNDO;
- break;
-
- case NK_DOWN:
- ik = KEY_DOWN;
- break;
-
- case NK_M_PGUP:
- ik = KEY_PAGE_UP;
- break;
-
- case NK_M_PGDOWN:
- ik = KEY_PAGE_DOWN;
- break;
-
- default:
- break;
- }
+ break;
+
+ case NK_DOWN:
+ ik = KEY_DOWN;
+ break;
+
+ case NK_M_PGUP:
+ ik = KEY_PAGE_UP;
+ break;
+
+ case NK_M_PGDOWN:
+ ik = KEY_PAGE_DOWN;
+ break;
+
+ default:
+ break;
+ }
}
-
- if( ik == 0 && ( (nkc & NKF_CTRL)==0) ) {
+
+ if( ik == 0 && ( (nkc & NKF_CTRL)==0) ) {
if (ascii >= 9 ) {
*ucs4_out = atari_to_ucs4(ascii);
- }
- }
+ }
+ }
return ( ik );
}
@@ -448,25 +448,25 @@ const char * file_select(const char * title, const char * name) {
return( NULL );
}
-
-
-void dbg_grect(const char * str, GRECT * r)
-{
- printf("%s: x: %d, y: %d, w: %d, h: %d (x2: %d, y2: %d)\n", str,
- r->g_x, r->g_y, r->g_w, r->g_h, r->g_x + r->g_w, r->g_y +
r->g_h);
-}
-
-void dbg_pxy(const char * str, short * pxy )
-{
- printf("%s: x: %d, y: %d, w: %d, h: %d\n", str,
- pxy[0], pxy[1], pxy[2], pxy[3] );
+
+
+void dbg_grect(const char * str, GRECT * r)
+{
+ printf("%s: x: %d, y: %d, w: %d, h: %d (x2: %d, y2: %d)\n", str,
+ r->g_x, r->g_y, r->g_w, r->g_h, r->g_x + r->g_w, r->g_y +
r->g_h);
+}
+
+void dbg_pxy(const char * str, short * pxy )
+{
+ printf("%s: x: %d, y: %d, w: %d, h: %d\n", str,
+ pxy[0], pxy[1], pxy[2], pxy[3] );
}
-void dbg_rect(const char * str, int * pxy)
-{
- printf("%s: x0: %d, y0: %d, x1: %d, y1: %d (w: %d, h: %d)\n", str,
+void dbg_rect(const char * str, int * pxy)
+{
+ printf("%s: x0: %d, y0: %d, x1: %d, y1: %d (w: %d, h: %d)\n", str,
pxy[0], pxy[1], pxy[2], pxy[3],
pxy[2] - pxy[0],
- pxy[3] - pxy[1] );
-}
-
+ pxy[3] - pxy[1] );
+}
+
-----------------------------------------------------------------------
Summary of changes:
amiga/gui.c | 1 -
amiga/icon.c | 1 -
atari/misc.c | 427 +++++++++++++++++++++++++++++-----------------------------
3 files changed, 213 insertions(+), 216 deletions(-)
diff --git a/amiga/gui.c b/amiga/gui.c
index 19064f9..11f874b 100644
--- a/amiga/gui.c
+++ b/amiga/gui.c
@@ -638,7 +638,6 @@ static nsurl *gui_get_resource_url(const char *path)
{
char buf[1024];
char path2[1024];
- char *raw;
nsurl *url = NULL;
if(ami_locate_resource(buf, path) == false)
diff --git a/amiga/icon.c b/amiga/icon.c
index d0e1c84..01802d3 100644
--- a/amiga/icon.c
+++ b/amiga/icon.c
@@ -144,7 +144,6 @@ bool amiga_icon_convert(struct content *c)
int err;
uint8 r, g, b, a;
ULONG offset;
- const char *url;
char *filename = NULL;
char *p;
ULONG trans, pals1;
diff --git a/atari/misc.c b/atari/misc.c
index 849eec9..e689b82 100755
--- a/atari/misc.c
+++ b/atari/misc.c
@@ -1,97 +1,97 @@
-/*
- * Copyright 2010 Ole Loots <ole(a)monochrom.net>
- *
- * This file is part of NetSurf,
http://www.netsurf-browser.org/
- *
- * NetSurf is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; version 2 of the License.
- *
- * NetSurf is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program. If not, see <
http://www.gnu.org/licenses/>.
- */
+/*
+ * Copyright 2010 Ole Loots <ole(a)monochrom.net>
+ *
+ * This file is part of NetSurf,
http://www.netsurf-browser.org/
+ *
+ * NetSurf is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; version 2 of the License.
+ *
+ * NetSurf is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program. If not, see <
http://www.gnu.org/licenses/>.
+ */
#include <assert.h>
-#include <stdlib.h>
+#include <stdlib.h>
#include <stdio.h>
-#include <stdbool.h>
-#include <string.h>
+#include <stdbool.h>
+#include <string.h>
-#include <sys/types.h>
+#include <sys/types.h>
#include <mint/osbind.h>
#include "content/content.h"
-#include "content/hlcache.h"
-#include "desktop/cookie_manager.h"
+#include "content/hlcache.h"
+#include "desktop/cookie_manager.h"
#include "desktop/mouse.h"
#include "desktop/tree.h"
-#include "utils/nsoption.h"
-#include "utils/messages.h"
-#include "utils/utils.h"
-#include "utils/log.h"
+#include "utils/nsoption.h"
+#include "utils/messages.h"
+#include "utils/utils.h"
+#include "utils/log.h"
#include "content/fetch.h"
-
-#include "atari/gui.h"
-#include "atari/toolbar.h"
-
+
+#include "atari/gui.h"
+#include "atari/toolbar.h"
+
#include "atari/misc.h"
#include "atari/encoding.h"
#include "atari/gemtk/gemtk.h"
-#include "cflib.h"
-
-extern void * h_gem_rsrc;
+#include "cflib.h"
+
+extern void * h_gem_rsrc;
struct is_process_running_callback_data {
const char * fname;
bool found;
};
-
-void warn_user(const char *warning, const char *detail)
-{
- size_t len = 1 + ((warning != NULL) ? strlen(messages_get(warning)) :
- 0) + ((detail != 0) ? strlen(detail) : 0);
- char message[len];
- snprintf(message, len, messages_get(warning), detail);
+
+void warn_user(const char *warning, const char *detail)
+{
+ size_t len = 1 + ((warning != NULL) ? strlen(messages_get(warning)) :
+ 0) + ((detail != 0) ? strlen(detail) : 0);
+ char message[len];
+ snprintf(message, len, messages_get(warning), detail);
printf("%s\n", message);
- gemtk_msg_box_show(GEMTK_MSG_BOX_ALERT, message);
-}
-
-void die(const char *error)
+ gemtk_msg_box_show(GEMTK_MSG_BOX_ALERT, message);
+}
+
+void die(const char *error)
{
- printf("%s\n", error);
+ printf("%s\n", error);
gemtk_msg_box_show(GEMTK_MSG_BOX_ALERT, error);
- exit(1);
-}
-
-
-struct gui_window * find_guiwin_by_aes_handle(short handle){
-
- struct gui_window * gw;
- gw = window_list;
-
- if( handle == 0 ){
+ exit(1);
+}
+
+
+struct gui_window * find_guiwin_by_aes_handle(short handle){
+
+ struct gui_window * gw;
+ gw = window_list;
+
+ if( handle == 0 ){
return( NULL );
}
- while(gw != NULL) {
+ while(gw != NULL) {
if(gw->root->win != NULL
- && gemtk_wm_get_handle(gw->root->win) == handle) {
- return(gw);
- }
- else
- gw = gw->next;
- }
-
- return( NULL );
+ && gemtk_wm_get_handle(gw->root->win) == handle) {
+ return(gw);
+ }
+ else
+ gw = gw->next;
+ }
+
+ return( NULL );
}
-
-
+
+
static int scan_process_list(scan_process_callback cb, void *data)
{
int pid, count = 0;
@@ -186,9 +186,9 @@ bool is_process_running(const char * name)
scan_process_list(proc_running_callback, &data);
return( (data.found==1) ? true : false );
-}
-
-
+}
+
+
/**
* Callback for load_icon(). Should be removed once bitmaps get loaded directly
* from disc
@@ -210,7 +210,6 @@ static nserror load_icon_callback(hlcache_handle *handle,
hlcache_handle *load_icon(const char *name, hlcache_handle_callback cb,
void * pw )
{
- const char *icon_url = NULL;
hlcache_handle *c;
nserror err;
nsurl *icon_nsurl;
@@ -251,21 +250,21 @@ hlcache_handle *load_icon(const char *name, hlcache_handle_callback
cb,
}
return c;
-}
-
-void gem_set_cursor( MFORM_EX * cursor )
-{
- static unsigned char flags = 255;
- static int number = 255;
- if( flags == cursor->flags && number == cursor->number )
- return;
+}
+
+void gem_set_cursor( MFORM_EX * cursor )
+{
+ static unsigned char flags = 255;
+ static int number = 255;
+ if( flags == cursor->flags && number == cursor->number )
+ return;
if( cursor->flags & MFORM_EX_FLAG_USERFORM ) {
- gemtk_obj_mouse_sprite(cursor->tree, cursor->number);
- } else {
- graf_mouse(cursor->number, NULL );
- }
- number = cursor->number;
- flags = cursor->flags;
+ gemtk_obj_mouse_sprite(cursor->tree, cursor->number);
+ } else {
+ graf_mouse(cursor->number, NULL );
+ }
+ number = cursor->number;
+ flags = cursor->flags;
}
/**
@@ -277,7 +276,7 @@ void gem_set_cursor( MFORM_EX * cursor )
*/
long nkc_to_input_key(short nkc, long * ucs4_out)
{
- unsigned char ascii = (nkc & 0xFF);
+ unsigned char ascii = (nkc & 0xFF);
long ik = 0;
// initialize result:
@@ -290,131 +289,131 @@ long nkc_to_input_key(short nkc, long * ucs4_out)
if( ((nkc & NKF_CTRL) == NKF_CTRL) && ((nkc & (NKF_SHIFT))!=0) ) {
}
- /* cntrl key only: */
- else if( (nkc & NKF_CTRL) == NKF_CTRL ) {
- switch ( ascii ) {
- case 'A':
- ik = KEY_SELECT_ALL;
- break;
-
- case 'C':
- ik = KEY_COPY_SELECTION;
- break;
-
- case 'X':
- ik = KEY_CUT_SELECTION;
- break;
-
- case 'V':
- ik = KEY_PASTE;
- break;
-
- default:
- break;
- }
+ /* cntrl key only: */
+ else if( (nkc & NKF_CTRL) == NKF_CTRL ) {
+ switch ( ascii ) {
+ case 'A':
+ ik = KEY_SELECT_ALL;
+ break;
+
+ case 'C':
+ ik = KEY_COPY_SELECTION;
+ break;
+
+ case 'X':
+ ik = KEY_CUT_SELECTION;
+ break;
+
+ case 'V':
+ ik = KEY_PASTE;
+ break;
+
+ default:
+ break;
+ }
}
- /* shift key only: */
+ /* shift key only: */
else if( (nkc & NKF_SHIFT) != 0 ) {
- switch( ascii ) {
- case NK_TAB:
- ik = KEY_SHIFT_TAB;
- break;
-
- case NK_LEFT:
- ik = KEY_LINE_START;
- break;
-
- case NK_RIGHT:
- ik = KEY_LINE_END;
- break;
-
- case NK_UP:
- ik = KEY_PAGE_UP;
- break;
-
- case NK_DOWN:
- ik = KEY_PAGE_DOWN;
- break;
-
- default:
- break;
- }
+ switch( ascii ) {
+ case NK_TAB:
+ ik = KEY_SHIFT_TAB;
+ break;
+
+ case NK_LEFT:
+ ik = KEY_LINE_START;
+ break;
+
+ case NK_RIGHT:
+ ik = KEY_LINE_END;
+ break;
+
+ case NK_UP:
+ ik = KEY_PAGE_UP;
+ break;
+
+ case NK_DOWN:
+ ik = KEY_PAGE_DOWN;
+ break;
+
+ default:
+ break;
+ }
}
- /* No modifier keys: */
- else {
+ /* No modifier keys: */
+ else {
switch( ascii ) {
case NK_INS:
ik = KEY_PASTE;
break;
-
- case NK_BS:
- ik = KEY_DELETE_LEFT;
- break;
-
- case NK_DEL:
- ik = KEY_DELETE_RIGHT;
- break;
-
- case NK_TAB:
- ik = KEY_TAB;
- break;
-
-
- case NK_ENTER:
- ik = KEY_NL;
- break;
-
- case NK_RET:
- ik = KEY_CR;
- break;
-
- case NK_ESC:
- ik = KEY_ESCAPE;
- break;
-
- case NK_CLRHOME:
- ik = KEY_TEXT_START;
- break;
-
- case NK_RIGHT:
- ik = KEY_RIGHT;
- break;
-
- case NK_LEFT:
- ik = KEY_LEFT;
- break;
-
- case NK_UP:
- ik = KEY_UP;
+
+ case NK_BS:
+ ik = KEY_DELETE_LEFT;
+ break;
+
+ case NK_DEL:
+ ik = KEY_DELETE_RIGHT;
+ break;
+
+ case NK_TAB:
+ ik = KEY_TAB;
+ break;
+
+
+ case NK_ENTER:
+ ik = KEY_NL;
+ break;
+
+ case NK_RET:
+ ik = KEY_CR;
+ break;
+
+ case NK_ESC:
+ ik = KEY_ESCAPE;
+ break;
+
+ case NK_CLRHOME:
+ ik = KEY_TEXT_START;
+ break;
+
+ case NK_RIGHT:
+ ik = KEY_RIGHT;
+ break;
+
+ case NK_LEFT:
+ ik = KEY_LEFT;
+ break;
+
+ case NK_UP:
+ ik = KEY_UP;
break;
case NK_UNDO:
ik = KEY_UNDO;
- break;
-
- case NK_DOWN:
- ik = KEY_DOWN;
- break;
-
- case NK_M_PGUP:
- ik = KEY_PAGE_UP;
- break;
-
- case NK_M_PGDOWN:
- ik = KEY_PAGE_DOWN;
- break;
-
- default:
- break;
- }
+ break;
+
+ case NK_DOWN:
+ ik = KEY_DOWN;
+ break;
+
+ case NK_M_PGUP:
+ ik = KEY_PAGE_UP;
+ break;
+
+ case NK_M_PGDOWN:
+ ik = KEY_PAGE_DOWN;
+ break;
+
+ default:
+ break;
+ }
}
-
- if( ik == 0 && ( (nkc & NKF_CTRL)==0) ) {
+
+ if( ik == 0 && ( (nkc & NKF_CTRL)==0) ) {
if (ascii >= 9 ) {
*ucs4_out = atari_to_ucs4(ascii);
- }
- }
+ }
+ }
return ( ik );
}
@@ -448,25 +447,25 @@ const char * file_select(const char * title, const char * name) {
return( NULL );
}
-
-
-void dbg_grect(const char * str, GRECT * r)
-{
- printf("%s: x: %d, y: %d, w: %d, h: %d (x2: %d, y2: %d)\n", str,
- r->g_x, r->g_y, r->g_w, r->g_h, r->g_x + r->g_w, r->g_y +
r->g_h);
-}
-
-void dbg_pxy(const char * str, short * pxy )
-{
- printf("%s: x: %d, y: %d, w: %d, h: %d\n", str,
- pxy[0], pxy[1], pxy[2], pxy[3] );
+
+
+void dbg_grect(const char * str, GRECT * r)
+{
+ printf("%s: x: %d, y: %d, w: %d, h: %d (x2: %d, y2: %d)\n", str,
+ r->g_x, r->g_y, r->g_w, r->g_h, r->g_x + r->g_w, r->g_y +
r->g_h);
+}
+
+void dbg_pxy(const char * str, short * pxy )
+{
+ printf("%s: x: %d, y: %d, w: %d, h: %d\n", str,
+ pxy[0], pxy[1], pxy[2], pxy[3] );
}
-void dbg_rect(const char * str, int * pxy)
-{
- printf("%s: x0: %d, y0: %d, x1: %d, y1: %d (w: %d, h: %d)\n", str,
+void dbg_rect(const char * str, int * pxy)
+{
+ printf("%s: x0: %d, y0: %d, x1: %d, y1: %d (w: %d, h: %d)\n", str,
pxy[0], pxy[1], pxy[2], pxy[3],
pxy[2] - pxy[0],
- pxy[3] - pxy[1] );
-}
-
+ pxy[3] - pxy[1] );
+}
+
--
NetSurf Browser