Gitweb links:
...log
http://git.netsurf-browser.org/netsurf.git/shortlog/545644f23d388467e7cd3ce7562f1ff3e7ae6c29
...commit
http://git.netsurf-browser.org/netsurf.git/commit/545644f23d388467e7cd3ce7562f1ff3e7ae6c29
...tree
http://git.netsurf-browser.org/netsurf.git/tree/545644f23d388467e7cd3ce7562f1ff3e7ae6c29
The branch, master has been updated
via 545644f23d388467e7cd3ce7562f1ff3e7ae6c29 (commit)
from 03566a1182809c00b1df4060645d17315e55660f (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=545644f23d388467e7cd3ce7562f1ff3e7ae6c29
commit 545644f23d388467e7cd3ce7562f1ff3e7ae6c29
Author: Vincent Sanders <[email protected]>
Commit: Vincent Sanders <[email protected]>
update atari frontend to remove usage of depricated warn_user API
diff --git a/atari/about.c b/atari/about.c
index c7db7b2..105037a 100644
--- a/atari/about.c
+++ b/atari/about.c
@@ -177,7 +177,7 @@ void atari_about_show(void)
nsurl_unref(url);
}
if (nserr != NSERROR_OK) {
- warn_user(messages_get_errorcode(nserr), 0);
+ atari_warn_user(messages_get_errorcode(nserr), 0);
}
}
/*
diff --git a/atari/ctxmenu.c b/atari/ctxmenu.c
index aecf3d1..0343b20 100644
--- a/atari/ctxmenu.c
+++ b/atari/ctxmenu.c
@@ -24,6 +24,7 @@
#include "content/hlcache.h"
#include "atari/gui.h"
+#include "atari/misc.h"
#include "atari/rootwin.h"
#include "atari/clipboard.h"
#include "atari/gemtk/gemtk.h"
@@ -237,7 +238,7 @@ void context_popup(struct gui_window * gw, short x, short y)
NULL);
if (error != NSERROR_OK) {
-
warn_user(messages_get_errorcode(error), 0);
+
atari_warn_user(messages_get_errorcode(error), 0);
}
}
@@ -271,7 +272,7 @@ void context_popup(struct gui_window * gw, short x, short y)
gw->browser->bw,
NULL);
if (error != NSERROR_OK) {
-
warn_user(messages_get_errorcode(error), 0);
+
atari_warn_user(messages_get_errorcode(error), 0);
}
}
break;
diff --git a/atari/deskmenu.c b/atari/deskmenu.c
index 17fa33c..7238358 100644
--- a/atari/deskmenu.c
+++ b/atari/deskmenu.c
@@ -195,7 +195,7 @@ static void __CDECL menu_about(short item, short title,
void *data)
nsurl_unref(url);
}
if (error != NSERROR_OK) {
- warn_user(messages_get_errorcode(error), 0);
+ atari_warn_user(messages_get_errorcode(error), 0);
}
*/
atari_about_show();
@@ -227,7 +227,7 @@ static void __CDECL menu_new_win(short item, short title,
void *data)
}
if (error != NSERROR_OK) {
- warn_user(messages_get_errorcode(error), 0);
+ atari_warn_user(messages_get_errorcode(error), 0);
}
}
@@ -270,7 +270,7 @@ static void __CDECL menu_open_file(short item, short title,
void *data)
}
if (error != NSERROR_OK) {
- warn_user(messages_get_errorcode(error), 0);
+ atari_warn_user(messages_get_errorcode(error),
0);
}
free( urltxt );
}
diff --git a/atari/download.c b/atari/download.c
index dad5d1f..9ebe787 100644
--- a/atari/download.c
+++ b/atari/download.c
@@ -287,7 +287,7 @@ gui_download_window_create(download_context *ctx, struct
gui_window *parent)
gdw = calloc(1, sizeof(struct gui_download_window));
if( gdw == NULL ){
- warn_user(NULL, "Out of memory!");
+ atari_warn_user(NULL, "Out of memory!");
free( destination );
return( NULL );
}
diff --git a/atari/hotlist.c b/atari/hotlist.c
index 380e1b6..1130e62 100644
--- a/atari/hotlist.c
+++ b/atari/hotlist.c
@@ -93,7 +93,7 @@ static void atari_hotlist_keypress(struct core_window *cw,
uint32_t ucs4)
{
GUIWIN *gemtk_win;
GRECT area;
- LOG("ucs4: %lu\n", ucs4);
+ LOG("ucs4: %"PRIu32 , ucs4);
hotlist_keypress(ucs4);
gemtk_win = atari_treeview_get_gemtk_window(cw);
atari_treeview_get_grect(cw, TREEVIEW_AREA_CONTENT, &area);
diff --git a/atari/misc.c b/atari/misc.c
index 8c94091..8688b93 100644
--- a/atari/misc.c
+++ b/atari/misc.c
@@ -194,18 +194,6 @@ bool is_process_running(const char * name)
}
-/**
- * Callback for load_icon(). Should be removed once bitmaps get loaded directly
- * from disc
- */
-static nserror load_icon_callback(hlcache_handle *handle,
- const hlcache_event *event, void *pw)
-{
- return NSERROR_OK;
-}
-
-
-
void gem_set_cursor( MFORM_EX * cursor )
{
static unsigned char flags = 255;
@@ -221,13 +209,8 @@ void gem_set_cursor( MFORM_EX * cursor )
flags = cursor->flags;
}
-/**
- * Convert NKC (atari normalized key code) to netsurf
- * Input key code and/or to ucs4 (depends on keycode).
- * When the input key can not be found for the NKC,
- * the function will return 0 and fill ucs4_out with
- * the NKC converted to UC4 encoding.
-*/
+
+/* exported interface documented in atari/misc.h */
long nkc_to_input_key(short nkc, long * ucs4_out)
{
unsigned char ascii = (nkc & 0xFF);
diff --git a/atari/misc.h b/atari/misc.h
index 0ccaaa7..4c7ff02 100644
--- a/atari/misc.h
+++ b/atari/misc.h
@@ -75,8 +75,12 @@ void dbg_rect(const char * str, int * pxy);
const char * file_select(const char * title, const char * name);
/**
- * Convert NKC (atari normalized key code) to netsurf
- * Input key code and/or to ucs4 (depends on keycode).
+ * Convert NKC to netsurf input key code and/or to ucs4 (depends on keycode).
+ *
+ * \param[in] nkc atari normalized key code
+ * \param[out] ucs4_out The ucs4 converted keycode
+ * \return The netsurf input keycode or 0 and ucs4_out updated with
+ * the NKC converted to UC4 encoding.
*/
long nkc_to_input_key(short nkc, long * ucs4_out);
diff --git a/atari/osspec.c b/atari/osspec.c
index adf8375..f64402e 100644
--- a/atari/osspec.c
+++ b/atari/osspec.c
@@ -40,7 +40,7 @@ NS_ATARI_SYSINFO atari_sysinfo;
void init_os_info(void)
{
int16_t out[4];
- unsigned long cookie_FSMC = 0;
+ long cookie_FSMC = 0;
atari_sysinfo.gemdos_version = Sversion();
@@ -71,6 +71,8 @@ void init_os_info(void)
}
}
+
+/* exported interface documented in atari/osspec.h */
int tos_getcookie(long tag, long * value)
{
COOKIE * cptr;
diff --git a/atari/search.c b/atari/search.c
index 8ba5521..d72d3ca 100644
--- a/atari/search.c
+++ b/atari/search.c
@@ -224,7 +224,7 @@ void nsatari_search_restore_form( struct
s_search_form_session *s, OBJECT *obj)
void nsatari_search_session_destroy(struct s_search_form_session *s)
{
if (s != NULL) {
- LOG("");
+ LOG("session %p", s);
browser_window_search_clear(s->g->browser->bw);
free(s);
}
diff --git a/atari/settings.c b/atari/settings.c
index 3bfa4bb..b6df127 100644
--- a/atari/settings.c
+++ b/atari/settings.c
@@ -168,7 +168,7 @@ static char **read_locales(void)
fp_locales = fopen(buf, "r");
if (fp_locales == NULL) {
- warn_user("Failed to load locales: %s",buf);
+ atari_warn_user("Failed to load locales: %s",buf);
return(NULL);
} else {
LOG("Reading locales from: %s...", buf);
diff --git a/atari/toolbar.c b/atari/toolbar.c
index eefab5f..f630332 100644
--- a/atari/toolbar.c
+++ b/atari/toolbar.c
@@ -699,7 +699,7 @@ bool toolbar_key_input(struct s_toolbar *tb, short nkc)
if ( textarea_get_text( tb->url.textarea, tmp_url, PATH_MAX) >
0 ) {
window_set_focus(tb->owner, BROWSER, gw->browser);
if (nsurl_create((const char*)&tmp_url, &url) !=
NSERROR_OK) {
- warn_user("NoMemory", 0);
+ atari_warn_user("NoMemory", 0);
} else {
browser_window_navigate(gw->browser->bw, url,
NULL,
BW_NAVIGATE_HISTORY,
@@ -977,7 +977,7 @@ void toolbar_home_click(struct s_toolbar *tb)
}
if (nsurl_create(use_url, &url) != NSERROR_OK) {
- warn_user("NoMemory", 0);
+ atari_warn_user("NoMemory", 0);
} else {
browser_window_navigate(bw,
url,
diff --git a/atari/treeview.c b/atari/treeview.c
index 20ac3e7..513e2df 100644
--- a/atari/treeview.c
+++ b/atari/treeview.c
@@ -528,7 +528,7 @@ atari_treeview_create(GUIWIN *win, struct
atari_treeview_callbacks * callbacks,
tv = calloc(1, sizeof(struct atari_treeview_window));
if (tv == NULL) {
LOG("calloc failed");
- warn_user(messages_get_errorcode(NSERROR_NOMEM), 0);
+ atari_warn_user(messages_get_errorcode(NSERROR_NOMEM), 0);
return NULL;
}
-----------------------------------------------------------------------
Summary of changes:
atari/about.c | 2 +-
atari/ctxmenu.c | 5 +++--
atari/deskmenu.c | 6 +++---
atari/download.c | 2 +-
atari/hotlist.c | 2 +-
atari/misc.c | 21 ++-------------------
atari/misc.h | 8 ++++++--
atari/osspec.c | 4 +++-
atari/search.c | 2 +-
atari/settings.c | 2 +-
atari/toolbar.c | 4 ++--
atari/treeview.c | 2 +-
12 files changed, 25 insertions(+), 35 deletions(-)
diff --git a/atari/about.c b/atari/about.c
index c7db7b2..105037a 100644
--- a/atari/about.c
+++ b/atari/about.c
@@ -177,7 +177,7 @@ void atari_about_show(void)
nsurl_unref(url);
}
if (nserr != NSERROR_OK) {
- warn_user(messages_get_errorcode(nserr), 0);
+ atari_warn_user(messages_get_errorcode(nserr), 0);
}
}
/*
diff --git a/atari/ctxmenu.c b/atari/ctxmenu.c
index aecf3d1..0343b20 100644
--- a/atari/ctxmenu.c
+++ b/atari/ctxmenu.c
@@ -24,6 +24,7 @@
#include "content/hlcache.h"
#include "atari/gui.h"
+#include "atari/misc.h"
#include "atari/rootwin.h"
#include "atari/clipboard.h"
#include "atari/gemtk/gemtk.h"
@@ -237,7 +238,7 @@ void context_popup(struct gui_window * gw, short x, short y)
NULL);
if (error != NSERROR_OK) {
-
warn_user(messages_get_errorcode(error), 0);
+
atari_warn_user(messages_get_errorcode(error), 0);
}
}
@@ -271,7 +272,7 @@ void context_popup(struct gui_window * gw, short x, short y)
gw->browser->bw,
NULL);
if (error != NSERROR_OK) {
-
warn_user(messages_get_errorcode(error), 0);
+
atari_warn_user(messages_get_errorcode(error), 0);
}
}
break;
diff --git a/atari/deskmenu.c b/atari/deskmenu.c
index 17fa33c..7238358 100644
--- a/atari/deskmenu.c
+++ b/atari/deskmenu.c
@@ -195,7 +195,7 @@ static void __CDECL menu_about(short item, short title,
void *data)
nsurl_unref(url);
}
if (error != NSERROR_OK) {
- warn_user(messages_get_errorcode(error), 0);
+ atari_warn_user(messages_get_errorcode(error), 0);
}
*/
atari_about_show();
@@ -227,7 +227,7 @@ static void __CDECL menu_new_win(short item, short title,
void *data)
}
if (error != NSERROR_OK) {
- warn_user(messages_get_errorcode(error), 0);
+ atari_warn_user(messages_get_errorcode(error), 0);
}
}
@@ -270,7 +270,7 @@ static void __CDECL menu_open_file(short item, short title,
void *data)
}
if (error != NSERROR_OK) {
- warn_user(messages_get_errorcode(error), 0);
+ atari_warn_user(messages_get_errorcode(error),
0);
}
free( urltxt );
}
diff --git a/atari/download.c b/atari/download.c
index dad5d1f..9ebe787 100644
--- a/atari/download.c
+++ b/atari/download.c
@@ -287,7 +287,7 @@ gui_download_window_create(download_context *ctx, struct
gui_window *parent)
gdw = calloc(1, sizeof(struct gui_download_window));
if( gdw == NULL ){
- warn_user(NULL, "Out of memory!");
+ atari_warn_user(NULL, "Out of memory!");
free( destination );
return( NULL );
}
diff --git a/atari/hotlist.c b/atari/hotlist.c
index 380e1b6..1130e62 100644
--- a/atari/hotlist.c
+++ b/atari/hotlist.c
@@ -93,7 +93,7 @@ static void atari_hotlist_keypress(struct core_window *cw,
uint32_t ucs4)
{
GUIWIN *gemtk_win;
GRECT area;
- LOG("ucs4: %lu\n", ucs4);
+ LOG("ucs4: %"PRIu32 , ucs4);
hotlist_keypress(ucs4);
gemtk_win = atari_treeview_get_gemtk_window(cw);
atari_treeview_get_grect(cw, TREEVIEW_AREA_CONTENT, &area);
diff --git a/atari/misc.c b/atari/misc.c
index 8c94091..8688b93 100644
--- a/atari/misc.c
+++ b/atari/misc.c
@@ -194,18 +194,6 @@ bool is_process_running(const char * name)
}
-/**
- * Callback for load_icon(). Should be removed once bitmaps get loaded directly
- * from disc
- */
-static nserror load_icon_callback(hlcache_handle *handle,
- const hlcache_event *event, void *pw)
-{
- return NSERROR_OK;
-}
-
-
-
void gem_set_cursor( MFORM_EX * cursor )
{
static unsigned char flags = 255;
@@ -221,13 +209,8 @@ void gem_set_cursor( MFORM_EX * cursor )
flags = cursor->flags;
}
-/**
- * Convert NKC (atari normalized key code) to netsurf
- * Input key code and/or to ucs4 (depends on keycode).
- * When the input key can not be found for the NKC,
- * the function will return 0 and fill ucs4_out with
- * the NKC converted to UC4 encoding.
-*/
+
+/* exported interface documented in atari/misc.h */
long nkc_to_input_key(short nkc, long * ucs4_out)
{
unsigned char ascii = (nkc & 0xFF);
diff --git a/atari/misc.h b/atari/misc.h
index 0ccaaa7..4c7ff02 100644
--- a/atari/misc.h
+++ b/atari/misc.h
@@ -75,8 +75,12 @@ void dbg_rect(const char * str, int * pxy);
const char * file_select(const char * title, const char * name);
/**
- * Convert NKC (atari normalized key code) to netsurf
- * Input key code and/or to ucs4 (depends on keycode).
+ * Convert NKC to netsurf input key code and/or to ucs4 (depends on keycode).
+ *
+ * \param[in] nkc atari normalized key code
+ * \param[out] ucs4_out The ucs4 converted keycode
+ * \return The netsurf input keycode or 0 and ucs4_out updated with
+ * the NKC converted to UC4 encoding.
*/
long nkc_to_input_key(short nkc, long * ucs4_out);
diff --git a/atari/osspec.c b/atari/osspec.c
index adf8375..f64402e 100644
--- a/atari/osspec.c
+++ b/atari/osspec.c
@@ -40,7 +40,7 @@ NS_ATARI_SYSINFO atari_sysinfo;
void init_os_info(void)
{
int16_t out[4];
- unsigned long cookie_FSMC = 0;
+ long cookie_FSMC = 0;
atari_sysinfo.gemdos_version = Sversion();
@@ -71,6 +71,8 @@ void init_os_info(void)
}
}
+
+/* exported interface documented in atari/osspec.h */
int tos_getcookie(long tag, long * value)
{
COOKIE * cptr;
diff --git a/atari/search.c b/atari/search.c
index 8ba5521..d72d3ca 100644
--- a/atari/search.c
+++ b/atari/search.c
@@ -224,7 +224,7 @@ void nsatari_search_restore_form( struct
s_search_form_session *s, OBJECT *obj)
void nsatari_search_session_destroy(struct s_search_form_session *s)
{
if (s != NULL) {
- LOG("");
+ LOG("session %p", s);
browser_window_search_clear(s->g->browser->bw);
free(s);
}
diff --git a/atari/settings.c b/atari/settings.c
index 3bfa4bb..b6df127 100644
--- a/atari/settings.c
+++ b/atari/settings.c
@@ -168,7 +168,7 @@ static char **read_locales(void)
fp_locales = fopen(buf, "r");
if (fp_locales == NULL) {
- warn_user("Failed to load locales: %s",buf);
+ atari_warn_user("Failed to load locales: %s",buf);
return(NULL);
} else {
LOG("Reading locales from: %s...", buf);
diff --git a/atari/toolbar.c b/atari/toolbar.c
index eefab5f..f630332 100644
--- a/atari/toolbar.c
+++ b/atari/toolbar.c
@@ -699,7 +699,7 @@ bool toolbar_key_input(struct s_toolbar *tb, short nkc)
if ( textarea_get_text( tb->url.textarea, tmp_url, PATH_MAX) >
0 ) {
window_set_focus(tb->owner, BROWSER, gw->browser);
if (nsurl_create((const char*)&tmp_url, &url) !=
NSERROR_OK) {
- warn_user("NoMemory", 0);
+ atari_warn_user("NoMemory", 0);
} else {
browser_window_navigate(gw->browser->bw, url,
NULL,
BW_NAVIGATE_HISTORY,
@@ -977,7 +977,7 @@ void toolbar_home_click(struct s_toolbar *tb)
}
if (nsurl_create(use_url, &url) != NSERROR_OK) {
- warn_user("NoMemory", 0);
+ atari_warn_user("NoMemory", 0);
} else {
browser_window_navigate(bw,
url,
diff --git a/atari/treeview.c b/atari/treeview.c
index 20ac3e7..513e2df 100644
--- a/atari/treeview.c
+++ b/atari/treeview.c
@@ -528,7 +528,7 @@ atari_treeview_create(GUIWIN *win, struct
atari_treeview_callbacks * callbacks,
tv = calloc(1, sizeof(struct atari_treeview_window));
if (tv == NULL) {
LOG("calloc failed");
- warn_user(messages_get_errorcode(NSERROR_NOMEM), 0);
+ atari_warn_user(messages_get_errorcode(NSERROR_NOMEM), 0);
return NULL;
}
--
NetSurf Browser
_______________________________________________
netsurf-commits mailing list
[email protected]
http://listmaster.pepperfish.net/cgi-bin/mailman/listinfo/netsurf-commits-netsurf-browser.org