Author: chris_y
Date: Sat Aug 29 09:41:24 2009
New Revision: 9497
URL:
http://source.netsurf-browser.org?rev=9497&view=rev
Log:
Give local history own off-screen rendering bitmap
Modified:
trunk/netsurf/amiga/history_local.c
trunk/netsurf/amiga/history_local.h
Modified: trunk/netsurf/amiga/history_local.c
URL:
http://source.netsurf-browser.org/trunk/netsurf/amiga/history_local.c?rev...
==============================================================================
--- trunk/netsurf/amiga/history_local.c (original)
+++ trunk/netsurf/amiga/history_local.c Sat Aug 29 09:41:24 2009
@@ -17,7 +17,7 @@
*/
/** \file
- * Browser history window (RISC OS implementation).
+ * Browser history window (AmigaOS implementation).
*
* There is only one history window, not one per browser window.
*/
@@ -82,6 +82,8 @@
{
hwindow = AllocVec(sizeof(struct history_window),MEMF_CLEAR | MEMF_PRIVATE);
+ ami_init_layers(&hwindow->gg, 0, 0);
+
hwindow->bw = bw;
history_size(history, &width, &height);
@@ -98,7 +100,7 @@
WA_SizeGadget, TRUE,
WA_CustomScreen,scrn,
WA_InnerWidth,width,
- WA_InnerHeight,height,
+ WA_InnerHeight,height + 10,
WINDOW_SharedPort,sport,
WINDOW_UserData,hwindow,
WINDOW_IconifyGadget, FALSE,
@@ -158,19 +160,18 @@
GetAttr(SCROLLER_Top,hw->objects[OID_HSCROLL],(ULONG *)&xs);
GetAttr(SCROLLER_Top,hw->objects[OID_VSCROLL],(ULONG *)&ys);
+ glob = &hw->gg;
ami_clg(0xffffff);
-// RefreshGadgets(hw->gadgets[GID_MAIN],hw->win,NULL);
-// currp = hw->win->RPort;
history_redraw_rectangle(history_current, xs, ys,
bbox->Width + xs, bbox->Height + ys, 0, 0);
-// currp = &glob.rp;
-
- ami_clearclipreg(&browserglob);
+ glob = &browserglob;
+
+ ami_clearclipreg(&hw->gg);
ami_history_update_extent(hw);
- BltBitMapRastPort(browserglob.bm, 0, 0, hw->win->RPort,
+ BltBitMapRastPort(hw->gg.bm, 0, 0, hw->win->RPort,
bbox->Left, bbox->Top, bbox->Width, bbox->Height, 0x0C0);
}
@@ -216,6 +217,7 @@
void ami_history_close(struct history_window *hw)
{
+ ami_free_layers(&hwindow->gg);
hw->bw->window->hw = NULL;
DisposeObject(hw->objects[OID_MAIN]);
DelObject(hw->node);
Modified: trunk/netsurf/amiga/history_local.h
URL:
http://source.netsurf-browser.org/trunk/netsurf/amiga/history_local.h?rev...
==============================================================================
--- trunk/netsurf/amiga/history_local.h (original)
+++ trunk/netsurf/amiga/history_local.h Sat Aug 29 09:41:24 2009
@@ -31,6 +31,7 @@
struct browser_window *bw;
ULONG pad[4];
struct Hook scrollerhook;
+ struct gui_globals gg;
};
void ami_history_open(struct browser_window *bw, struct history *history);