remove some warnings in amiga frontend build
This commit is contained in:
parent
8dc7869937
commit
f966580d22
|
@ -88,6 +88,15 @@ ami_history_local_destroy(struct ami_history_local_window *history_local_win)
|
|||
return res;
|
||||
}
|
||||
|
||||
static void ami_history_local_destroy_cw(struct ami_corewindow *ami_cw)
|
||||
{
|
||||
struct ami_history_local_window *history_local_win;
|
||||
/* technically degenerate container of */
|
||||
history_local_win = (struct ami_history_local_window *)ami_cw;
|
||||
|
||||
ami_history_local_destroy(history_local_win);
|
||||
}
|
||||
|
||||
/**
|
||||
* callback for mouse action for local history on core window
|
||||
*
|
||||
|
@ -271,7 +280,7 @@ nserror ami_history_local_present(struct gui_window *gw)
|
|||
ncwin->core.draw = ami_history_local_draw;
|
||||
ncwin->core.key = ami_history_local_key;
|
||||
ncwin->core.mouse = ami_history_local_mouse;
|
||||
ncwin->core.close = ami_history_local_destroy;
|
||||
ncwin->core.close = ami_history_local_destroy_cw;
|
||||
ncwin->core.event = NULL;
|
||||
ncwin->core.drag_end = NULL;
|
||||
ncwin->core.icon_drop = NULL;
|
||||
|
|
|
@ -74,7 +74,7 @@ static void ami_openurl_free_list(struct MinList *list)
|
|||
struct ami_protocol *node;
|
||||
struct ami_protocol *nnode;
|
||||
|
||||
if(IsMinListEmpty(list) == NULL) {
|
||||
if(IsMinListEmpty(list)) {
|
||||
node = (struct ami_protocol *)GetHead((struct List *)list);
|
||||
|
||||
do
|
||||
|
|
|
@ -107,7 +107,8 @@ static nserror ami_schedule_add_timer_event(struct nscallback *nscb, int t)
|
|||
* A scheduled callback matching both callback and p is returned, or NULL if none present.
|
||||
*/
|
||||
|
||||
static struct nscallback *ami_schedule_locate(void (*callback)(void *p), void *p, bool remove)
|
||||
static struct nscallback *
|
||||
ami_schedule_locate(void (*callback)(void *p), void *p, bool remove)
|
||||
{
|
||||
PblIterator *iterator;
|
||||
struct nscallback *nscb;
|
||||
|
@ -119,7 +120,7 @@ static struct nscallback *ami_schedule_locate(void (*callback)(void *p), void *p
|
|||
|
||||
iterator = pblHeapIterator(schedule_list);
|
||||
|
||||
while ((nscb = pblIteratorNext(iterator)) != -1) {
|
||||
while ((nscb = pblIteratorNext(iterator)) != (void *)-1) {
|
||||
if ((nscb->callback == callback) && (nscb->p == p)) {
|
||||
if (remove == true) pblIteratorRemove(iterator);
|
||||
found_cb = true;
|
||||
|
@ -190,8 +191,7 @@ static void schedule_remove_all(void)
|
|||
|
||||
iterator = pblHeapIterator(schedule_list);
|
||||
|
||||
while ((nscb = pblIteratorNext(iterator)) != -1)
|
||||
{
|
||||
while ((nscb = pblIteratorNext(iterator)) != (void *)-1) {
|
||||
ami_schedule_remove_timer_event(nscb);
|
||||
pblIteratorRemove(iterator);
|
||||
#ifdef __amigaos4__
|
||||
|
@ -226,18 +226,17 @@ static void ami_schedule_dump(void)
|
|||
GetSysTime(&tv);
|
||||
Amiga2Date(tv.Seconds, &clockdata);
|
||||
|
||||
NSLOG(netsurf, INFO, "Current time = %d-%d-%d %d:%d:%d.%d",
|
||||
NSLOG(netsurf, INFO, "Current time = %d-%d-%d %d:%d:%d.%lu",
|
||||
clockdata.mday, clockdata.month, clockdata.year,
|
||||
clockdata.hour, clockdata.min, clockdata.sec, tv.Microseconds);
|
||||
NSLOG(netsurf, INFO, "Events remaining in queue:");
|
||||
|
||||
iterator = pblHeapIterator(schedule_list);
|
||||
|
||||
while ((nscb = pblIteratorNext(iterator)) != -1)
|
||||
{
|
||||
while ((nscb = pblIteratorNext(iterator)) != (void *)-1) {
|
||||
Amiga2Date(nscb->tv.Seconds, &clockdata);
|
||||
NSLOG(netsurf, INFO,
|
||||
"nscb: %p, at %d-%d-%d %d:%d:%d.%d, callback: %p, %p",
|
||||
"nscb: %p, at %d-%d-%d %d:%d:%d.%lu, callback: %p, %p",
|
||||
nscb, clockdata.mday, clockdata.month, clockdata.year,
|
||||
clockdata.hour, clockdata.min, clockdata.sec,
|
||||
nscb->tv.Microseconds, nscb->callback, nscb->p);
|
||||
|
@ -307,7 +306,10 @@ nserror ami_schedule_create(struct MsgPort *msgport)
|
|||
schedule_msgport = msgport;
|
||||
#endif
|
||||
schedule_list = pblHeapNew();
|
||||
if(schedule_list == PBL_ERROR_OUT_OF_MEMORY) return NSERROR_NOMEM;
|
||||
|
||||
if (schedule_list == NULL) {
|
||||
return NSERROR_NOMEM;
|
||||
}
|
||||
|
||||
pblHeapSetCompareFunction(schedule_list, ami_schedule_compare);
|
||||
|
||||
|
|
|
@ -41,8 +41,8 @@ struct myStringClassData
|
|||
Object * WindowObject;
|
||||
Object * ListviewObject;
|
||||
struct List ListviewHeader;
|
||||
uint32 ListviewCount;
|
||||
uint32 ListviewSelected;
|
||||
int32 ListviewCount;
|
||||
int32 ListviewSelected;
|
||||
struct List * SearchHeader;
|
||||
STRPTR SearchBuffer;
|
||||
};
|
||||
|
|
Loading…
Reference in New Issue