summaryrefslogtreecommitdiff
path: root/amiga
diff options
context:
space:
mode:
authorChris Young <chris@unsatisfactorysoftware.co.uk>2013-04-04 19:46:33 +0100
committerChris Young <chris@unsatisfactorysoftware.co.uk>2013-04-04 19:46:33 +0100
commit6686d9dad81a5599a0e0144994c5d0eefe6d86e0 (patch)
treec303b6cf04fd22e5d9d5fdde81d33253f82d38bc /amiga
parentc297f45bb9f557a2260be02a2de84bbab41e0f22 (diff)
downloadnetsurf-6686d9dad81a5599a0e0144994c5d0eefe6d86e0.tar.gz
netsurf-6686d9dad81a5599a0e0144994c5d0eefe6d86e0.tar.bz2
Schedule redraws from local history too, hide ami_do_redraw and friends as only gui.c needs to call those directly now
Diffstat (limited to 'amiga')
-rw-r--r--amiga/gui.c13
-rwxr-xr-xamiga/gui.h2
-rwxr-xr-xamiga/history_local.c2
-rw-r--r--amiga/menu.c2
4 files changed, 9 insertions, 10 deletions
diff --git a/amiga/gui.c b/amiga/gui.c
index 247c536f7..a84972789 100644
--- a/amiga/gui.c
+++ b/amiga/gui.c
@@ -190,7 +190,7 @@ static uint32 ami_set_throbber_render_hook(struct Hook *hook, APTR space,
bool ami_gui_map_filename(char **remapped, const char *path, const char *file,
const char *map);
static void ami_gui_window_update_box_deferred(struct gui_window *g, bool draw);
-static void ami_schedule_redraw(struct gui_window_2 *gwin, bool full_redraw);
+static void ami_do_redraw(struct gui_window_2 *g);
STRPTR ami_locale_langs(void)
{
@@ -2119,11 +2119,10 @@ void ami_handle_msg(void)
if(node->Type == AMINS_WINDOW)
{
- /* Catch any reformats tagged by the core - not sure this is required
+ /* Catch any reformats tagged by the core - only used by scale? */
if(gwin->bw->reformat_pending) {
ami_do_redraw(gwin);
}
- */
if(gwin->bw->window->throbbing)
ami_update_throbber(gwin,false);
@@ -3887,13 +3886,13 @@ static void ami_redraw_callback(struct gui_window_2 *gwin)
}
}
-static void ami_schedule_redraw(struct gui_window_2 *gwin, bool full_redraw)
+void ami_schedule_redraw(struct gui_window_2 *gwin, bool full_redraw)
{
schedule(0, ami_redraw_callback, gwin);
if(full_redraw) gwin->redraw_required = true;
}
-void ami_do_redraw_tiled(struct gui_window_2 *gwin, bool busy,
+static void ami_do_redraw_tiled(struct gui_window_2 *gwin, bool busy,
int left, int top, int width, int height,
int sx, int sy, struct IBox *bbox, struct redraw_context *ctx)
{
@@ -3985,7 +3984,7 @@ void ami_do_redraw_tiled(struct gui_window_2 *gwin, bool busy,
* \param y1 bottom-right co-ordinate (in document co-ordinates)
*/
-void ami_do_redraw_limits(struct gui_window *g, struct browser_window *bw, bool busy,
+static void ami_do_redraw_limits(struct gui_window *g, struct browser_window *bw, bool busy,
int x0, int y0, int x1, int y1)
{
ULONG xoffset,yoffset,width=800,height=600;
@@ -4116,7 +4115,7 @@ void gui_window_update_box(struct gui_window *g, const struct rect *rect)
ami_schedule_redraw(g->shared, false);
}
-void ami_do_redraw(struct gui_window_2 *gwin)
+static void ami_do_redraw(struct gui_window_2 *gwin)
{
struct Region *reg = NULL;
struct Rectangle rect;
diff --git a/amiga/gui.h b/amiga/gui.h
index e708cefbb..08a8b19e9 100755
--- a/amiga/gui.h
+++ b/amiga/gui.h
@@ -148,7 +148,7 @@ struct gui_window
void ami_get_msg(void);
void ami_close_all_tabs(struct gui_window_2 *gwin);
void ami_quit_netsurf(void);
-void ami_do_redraw(struct gui_window_2 *g);
+void ami_schedule_redraw(struct gui_window_2 *gwin, bool full_redraw);
STRPTR ami_locale_langs(void);
int ami_key_to_nskey(ULONG keycode, struct InputEvent *ie);
bool ami_text_box_at_point(struct gui_window_2 *gwin, ULONG *x, ULONG *y);
diff --git a/amiga/history_local.c b/amiga/history_local.c
index a0d37b0b2..3c8b6e11a 100755
--- a/amiga/history_local.c
+++ b/amiga/history_local.c
@@ -212,7 +212,7 @@ bool ami_history_click(struct history_window *hw,uint16 code)
case SELECTUP:
history_click(hw->bw,history_current,x,y,false);
ami_history_redraw(hw);
- ami_do_redraw(hw->bw->window->shared);
+ ami_schedule_redraw(hw->bw->window->shared, true);
break;
case MIDDLEUP:
diff --git a/amiga/menu.c b/amiga/menu.c
index a0abc24a1..c710bffac 100644
--- a/amiga/menu.c
+++ b/amiga/menu.c
@@ -1005,7 +1005,7 @@ static void ami_menu_item_browser_redraw(struct Hook *hook, APTR window, struct
struct gui_window_2 *gwin;
GetAttr(WINDOW_UserData, (Object *)window, (ULONG *)&gwin);
- gwin->redraw_required = true;
+ ami_schedule_redraw(gwin, true);
gwin->new_content = true;
}