r12117 chris_y - /trunk/netsurf/amiga/pkg/makepackage
by netsurf@semichrome.net
Author: chris_y
Date: Mon Mar 21 14:46:04 2011
New Revision: 12117
URL: http://source.netsurf-browser.org?rev=12117&view=rev
Log:
Use webp.library instead of libwebp.so
Modified:
trunk/netsurf/amiga/pkg/makepackage
Modified: trunk/netsurf/amiga/pkg/makepackage
URL: http://source.netsurf-browser.org/trunk/netsurf/amiga/pkg/makepackage?rev...
==============================================================================
--- trunk/netsurf/amiga/pkg/makepackage (original)
+++ trunk/netsurf/amiga/pkg/makepackage Mon Mar 21 14:46:04 2011
@@ -21,8 +21,8 @@
makedir ram:NetSurf/Rexx
copy amiga/dist/Rexx/~(.svn) ram:NetSurf/Rexx/ COM
makedir ram:NetSurf/Libs
-copy libs:parserutils.library libs:nsgif.library libs:nsbmp.library libs:iconv.library libs:hubbub.library ram:NetSurf/Libs
+copy libs:parserutils.library libs:nsgif.library libs:nsbmp.library libs:iconv.library libs:hubbub.library libs:webp.library ram:NetSurf/Libs
; libs:css.library libs:wapcaplet.library
makedir ram:NetSurf/SObjs
-copy sobjs:libjpeg.so.8 sobjs:libmng.so.1 sobjs:liblcms.so sobjs:libxml2.so.9 sobjs:libcurl.so.7 sobjs:librtmp.so.0 sobjs:libsvgtiny.so.0 sobjs:libz.so.1.2.5 sobjs:libwebp.so.0 sobjs:libssl.so.1.0.0 sobjs:libcrypto.so.1.0.0 sobjs:libcss.so.0 sobjs:libwapcaplet.so.0 sobjs:libpng12.so ram:NetSurf/SObjs clone
+copy sobjs:libjpeg.so.8 sobjs:libmng.so.1 sobjs:liblcms.so sobjs:libxml2.so.9 sobjs:libcurl.so.7 sobjs:librtmp.so.0 sobjs:libsvgtiny.so.0 sobjs:libz.so.1.2.5 sobjs:libssl.so.1.0.0 sobjs:libcrypto.so.1.0.0 sobjs:libcss.so.0 sobjs:libwapcaplet.so.0 sobjs:libpng12.so ram:NetSurf/SObjs clone
;sobjs:libhpdf-2.2.0.so.0.0
12 years, 2 months
r12116 vince - in /trunk/netsurf/framebuffer: fbtk.h fbtk/fbtk.c fbtk/text.c
by netsurf@semichrome.net
Author: vince
Date: Mon Mar 21 02:51:37 2011
New Revision: 12116
URL: http://source.netsurf-browser.org?rev=12116&view=rev
Log:
add control of fbtk text widget padding
Modified:
trunk/netsurf/framebuffer/fbtk.h
trunk/netsurf/framebuffer/fbtk/fbtk.c
trunk/netsurf/framebuffer/fbtk/text.c
Modified: trunk/netsurf/framebuffer/fbtk.h
URL: http://source.netsurf-browser.org/trunk/netsurf/framebuffer/fbtk.h?rev=12...
==============================================================================
--- trunk/netsurf/framebuffer/fbtk.h (original)
+++ trunk/netsurf/framebuffer/fbtk.h Mon Mar 21 02:51:37 2011
@@ -19,11 +19,19 @@
#ifndef NETSURF_FB_FBTK_H
#define NETSURF_FB_FBTK_H
+#ifdef FBTK_LOGGING
+#define FBTK_LOG(x) LOG(x)
+#else
+#define FBTK_LOG(x)
+#endif
#define FB_SCROLL_COLOUR 0xFFAAAAAA
#define FB_FRAME_COLOUR 0xFFDDDDDD
#define FB_COLOUR_BLACK 0xFF000000
#define FB_COLOUR_WHITE 0xFFFFFFFF
+
+#define FBTK_WIDGET_PADDING 30 /* percentage of widget size used for padding */
+#define FBTK_DPI 90 /* screen DPI */
typedef struct fbtk_widget_s fbtk_widget_t;
Modified: trunk/netsurf/framebuffer/fbtk/fbtk.c
URL: http://source.netsurf-browser.org/trunk/netsurf/framebuffer/fbtk/fbtk.c?r...
==============================================================================
--- trunk/netsurf/framebuffer/fbtk/fbtk.c (original)
+++ trunk/netsurf/framebuffer/fbtk/fbtk.c Mon Mar 21 02:51:37 2011
@@ -42,6 +42,8 @@
#include "framebuffer/image_data.h"
#include "widget.h"
+
+#ifdef FBTK_LOGGING
/* tree dump debug, also example of depth first tree walk */
static void
@@ -73,6 +75,8 @@
}
}
+#endif
+
/* exported function documented in fbtk.h */
void
fbtk_request_redraw(fbtk_widget_t *widget)
Modified: trunk/netsurf/framebuffer/fbtk/text.c
URL: http://source.netsurf-browser.org/trunk/netsurf/framebuffer/fbtk/text.c?r...
==============================================================================
--- trunk/netsurf/framebuffer/fbtk/text.c (original)
+++ trunk/netsurf/framebuffer/fbtk/text.c Mon Mar 21 02:51:37 2011
@@ -37,7 +37,7 @@
#include "widget.h"
-#define TEXT_WIDGET_BORDER 3 /**< The pixel border round a text widget. */
+//#define TEXT_WIDGET_BORDER 3 /**< The pixel border round a text widget. */
/* Lighten a colour by taking seven eights of each channel's intensity
* and adding a full eighth
@@ -48,7 +48,7 @@
((((7 * (c1 & 0xff)) >> 3) + 32) << 0))
/* Convert pixels to points, assuming a DPI of 90 */
-#define px_to_pt(x) (((x) * 72) / 90)
+#define px_to_pt(x) (((x) * 72) / FBTK_DPI)
/** Text redraw callback.
*
@@ -66,9 +66,9 @@
fbtk_widget_t *root;
plot_font_style_t font_style;
int fh;
- int border;
-
- border = (widget->height * 10) / 90;
+ int padding;
+
+ padding = (widget->height * FBTK_WIDGET_PADDING) / 200;
root = fbtk_get_root_widget(widget);
@@ -84,15 +84,16 @@
nsfb_plot_rectangle_fill(root->u.root.fb, &bbox, widget->bg);
}
+ /* widget can have a single pixel outline border */
if (widget->u.text.outline) {
rect.x1--;
rect.y1--;
nsfb_plot_rectangle(root->u.root.fb, &rect, 1, 0x00000000, false, false);
- border++;
+ padding++;
}
if (widget->u.text.text != NULL) {
- fh = widget->height - border - border;
+ fh = widget->height - padding - padding;
font_style.family = PLOT_FONT_FAMILY_SANS_SERIF;
font_style.size = px_to_pt(fh) * FONT_SIZE_SCALE;
font_style.weight = 400;
@@ -100,16 +101,16 @@
font_style.background = widget->bg;
font_style.foreground = widget->fg;
- LOG(("plotting %p at %d,%d %d,%d w/h %d,%d font h %d border %d",
+ FBTK_LOG(("plotting %p at %d,%d %d,%d w/h %d,%d font h %d padding %d",
widget, bbox.x0, bbox.y0, bbox.x1, bbox.y1,
- widget->width, widget->height, fh, border));
+ widget->width, widget->height, fh, padding));
/* Call the fb text plotting, baseline is 3/4 down the
* font, somewhere along the way the co-ordinate
* system for the baseline is to the "higher value
* pixel co-ordinate" due to this the + 1 is neccessary.
*/
- plot.text(bbox.x0 + border,
- bbox.y0 + (((fh * 3) + 3)/4) + border + 1,
+ plot.text(bbox.x0 + padding,
+ bbox.y0 + (((fh * 3) + 3)/4) + padding + 1,
widget->u.text.text,
strlen(widget->u.text.text),
&font_style);
12 years, 2 months
r12115 chris_y - in /trunk/netsurf: Makefile.defaults amiga/Makefile.target amiga/dist/Install amiga/pkg/makepackage gtk/Makefile.target image/webp.c
by netsurf@semichrome.net
Author: chris_y
Date: Sun Mar 20 18:32:44 2011
New Revision: 12115
URL: http://source.netsurf-browser.org?rev=12115&view=rev
Log:
Update to use official libwebp 0.1
Remove libvpx references as no longer needed.
Modified:
trunk/netsurf/Makefile.defaults
trunk/netsurf/amiga/Makefile.target
trunk/netsurf/amiga/dist/Install
trunk/netsurf/amiga/pkg/makepackage
trunk/netsurf/gtk/Makefile.target
trunk/netsurf/image/webp.c
Modified: trunk/netsurf/Makefile.defaults
URL: http://source.netsurf-browser.org/trunk/netsurf/Makefile.defaults?rev=121...
==============================================================================
--- trunk/netsurf/Makefile.defaults (original)
+++ trunk/netsurf/Makefile.defaults Sun Mar 20 18:32:44 2011
@@ -53,7 +53,7 @@
# Valid options: YES, NO (at least one of PNG/MNG highly recommended)
NETSURF_USE_MNG := YES
-# Enable NetSurf's use of libwebp/libvpx for displaying WebPs
+# Enable NetSurf's use of libwebp for displaying WebPs
# Valid options: YES, NO
NETSURF_USE_WEBP := NO
@@ -220,7 +220,7 @@
# Valid options: YES, NO, AUTO
NETSURF_USE_ROSPRITE := YES
- # Enable NetSurf's use of libwebp/libvpx for displaying WebPs
+ # Enable NetSurf's use of libwebp for displaying WebPs
# Valid options: YES, NO
NETSURF_USE_WEBP := YES
@@ -340,7 +340,7 @@
# Valid options: YES, NO, AUTO
NETSURF_USE_ROSPRITE := NO
- # Enable NetSurf's use of libwebp/libvpx for displaying WebPs
+ # Enable NetSurf's use of libwebp for displaying WebPs
# Valid options: YES, NO
NETSURF_USE_WEBP := NO
@@ -379,7 +379,7 @@
# Valid options: YES, NO, AUTO
NETSURF_USE_ROSPRITE := NO
- # Enable NetSurf's use of libwebp/libvpx for displaying WebPs
+ # Enable NetSurf's use of libwebp for displaying WebPs
# Valid options: YES, NO
NETSURF_USE_WEBP := NO
Modified: trunk/netsurf/amiga/Makefile.target
URL: http://source.netsurf-browser.org/trunk/netsurf/amiga/Makefile.target?rev...
==============================================================================
--- trunk/netsurf/amiga/Makefile.target (original)
+++ trunk/netsurf/amiga/Makefile.target Sun Mar 20 18:32:44 2011
@@ -22,7 +22,7 @@
$(eval $(call feature_enabled,PNG,-DWITH_PNG,-lpng,PNG (libpng) ))
$(eval $(call feature_enabled,NSSVG,-DWITH_NS_SVG,-lsvgtiny,SVG (libsvgtiny)))
$(eval $(call feature_enabled,MNG,,-llcms -ljpeg,PNG/JNG/MNG (libmng)))
- $(eval $(call feature_enabled,WEBP,-DWITH_WEBP,-lwebp -lvpx,WebP (libwebp)))
+ $(eval $(call feature_enabled,WEBP,-DWITH_WEBP,-lwebp,WebP (libwebp)))
$(eval $(call feature_enabled,AMIGA_ICON,-DWITH_AMIGA_ICON,,Amiga icon ))
$(eval $(call feature_enabled,PLUGINS,-DWITH_PLUGIN,,DataTypes images))
Modified: trunk/netsurf/amiga/dist/Install
URL: http://source.netsurf-browser.org/trunk/netsurf/amiga/dist/Install?rev=12...
==============================================================================
--- trunk/netsurf/amiga/dist/Install (original)
+++ trunk/netsurf/amiga/dist/Install Sun Mar 20 18:32:44 2011
@@ -484,8 +484,6 @@
(p_linksobj "libz.so.1.2.5" "libz.so")
(p_linksobj "libz.so.1.2.5" "libz.so.1")
(p_linksobj "libz.so.1.2.5" "libz.so.1.2")
- (p_linksobj "libvpx.so.0.9.5" "libvpx.so.0")
-; (p_linksobj "libpng14.so.14" "libpng.so")
)
)
Modified: trunk/netsurf/amiga/pkg/makepackage
URL: http://source.netsurf-browser.org/trunk/netsurf/amiga/pkg/makepackage?rev...
==============================================================================
--- trunk/netsurf/amiga/pkg/makepackage (original)
+++ trunk/netsurf/amiga/pkg/makepackage Sun Mar 20 18:32:44 2011
@@ -24,5 +24,5 @@
copy libs:parserutils.library libs:nsgif.library libs:nsbmp.library libs:iconv.library libs:hubbub.library ram:NetSurf/Libs
; libs:css.library libs:wapcaplet.library
makedir ram:NetSurf/SObjs
-copy sobjs:libjpeg.so.8 sobjs:libmng.so.1 sobjs:liblcms.so sobjs:libxml2.so.9 sobjs:libcurl.so.7 sobjs:librtmp.so.0 sobjs:libsvgtiny.so.0 sobjs:libz.so.1.2.5 sobjs:libvpx.so.0.9.5 sobjs:libssl.so.1.0.0 sobjs:libcrypto.so.1.0.0 sobjs:libcss.so.0 sobjs:libwapcaplet.so.0 sobjs:libpng12.so ram:NetSurf/SObjs clone
+copy sobjs:libjpeg.so.8 sobjs:libmng.so.1 sobjs:liblcms.so sobjs:libxml2.so.9 sobjs:libcurl.so.7 sobjs:librtmp.so.0 sobjs:libsvgtiny.so.0 sobjs:libz.so.1.2.5 sobjs:libwebp.so.0 sobjs:libssl.so.1.0.0 sobjs:libcrypto.so.1.0.0 sobjs:libcss.so.0 sobjs:libwapcaplet.so.0 sobjs:libpng12.so ram:NetSurf/SObjs clone
;sobjs:libhpdf-2.2.0.so.0.0
Modified: trunk/netsurf/gtk/Makefile.target
URL: http://source.netsurf-browser.org/trunk/netsurf/gtk/Makefile.target?rev=1...
==============================================================================
--- trunk/netsurf/gtk/Makefile.target (original)
+++ trunk/netsurf/gtk/Makefile.target Sun Mar 20 18:32:44 2011
@@ -24,7 +24,7 @@
$(eval $(call pkg_config_find_and_add,PNG,libpng,PNG ))
# no pkg-config for this library
- $(eval $(call feature_enabled,WEBP,-DWITH_WEBP,-lwebp -lvpx,WebP (libwebp)))
+ $(eval $(call feature_enabled,WEBP,-DWITH_WEBP,-lwebp,WebP (libwebp)))
GTKCFLAGS := -std=c99 -Dgtk -Dnsgtk \
-DGTK_DISABLE_DEPRECATED \
Modified: trunk/netsurf/image/webp.c
URL: http://source.netsurf-browser.org/trunk/netsurf/image/webp.c?rev=12115&r1...
==============================================================================
--- trunk/netsurf/image/webp.c (original)
+++ trunk/netsurf/image/webp.c Sun Mar 20 18:32:44 2011
@@ -27,7 +27,7 @@
#include <assert.h>
#include <string.h>
#include <stdlib.h>
-#include <webpimg.h>
+#include <webp/decode.h>
#include "desktop/plotters.h"
#include "image/bitmap.h"
#include "content/content_protected.h"
@@ -44,24 +44,21 @@
bool webp_convert(struct content *c)
{
union content_msg_data msg_data;
- const uint8 *data;
+ const uint8_t *data;
unsigned char *imagebuf = NULL;
- uint32 *imagebufptr = NULL;
+ uint32_t *imagebufptr = NULL;
unsigned long size;
- uint8 *Y = NULL, *U = NULL, *V = NULL;
int width = 0, height = 0;
- uint32 offset = 0;
- uint8 r, g, b, a;
char title[100];
- WebPResult res = webp_success;
+ int res = 0;
+ uint8_t *res_p = NULL;
data = (uint8 *)content__get_source_data(c, &size);
- res = WebPDecode(data, size, &Y, &U, &V, &width, &height);
- if (res != webp_success) {
+ res = WebPGetInfo(data, size, &width, &height);
+ if (res == 0) {
msg_data.error = messages_get("NoMemory");
content_broadcast(c, CONTENT_MSG_ERROR, msg_data);
- if(Y) free(Y);
return false;
}
@@ -69,35 +66,23 @@
if (!c->bitmap) {
msg_data.error = messages_get("NoMemory");
content_broadcast(c, CONTENT_MSG_ERROR, msg_data);
- if(Y) free(Y);
return false;
}
+
imagebuf = bitmap_get_buffer(c->bitmap);
if (!imagebuf) {
msg_data.error = messages_get("NoMemory");
content_broadcast(c, CONTENT_MSG_ERROR, msg_data);
- if(Y) free(Y);
return false;
}
- unsigned int row_width = bitmap_get_rowstride(c->bitmap) / 4;
+ unsigned int row_width = bitmap_get_rowstride(c->bitmap);
- YUV420toRGBA(Y, U, V, row_width, width, height, (uint32 *)imagebuf);
-
- if(Y) free(Y);
-
- /* Decoded data is RGBA on both big- and little-endian platforms,
- * so ensure correct byte order. */
-
- size = width * height * 4;
-
- for (offset = 0; offset < size; offset += 4) {
- a = imagebuf[offset+3];
- b = imagebuf[offset+2];
- g = imagebuf[offset+1];
- r = imagebuf[offset];
-
- imagebufptr = imagebuf + offset;
- *imagebufptr = r << 24 | g << 16 | b << 8 | a;
+ res_p = WebPDecodeRGBAInto(data, size, imagebuf,
+ row_width * height, row_width);
+ if (res_p == NULL) {
+ msg_data.error = messages_get("NoMemory");
+ content_broadcast(c, CONTENT_MSG_ERROR, msg_data);
+ return false;
}
c->width = width;
12 years, 2 months
r12114 mono - /trunk/netsurf/atari/doc/readme.txt
by netsurf@semichrome.net
Author: mono
Date: Sun Mar 20 17:45:09 2011
New Revision: 12114
URL: http://source.netsurf-browser.org?rev=12114&view=rev
Log:
Thanks to AtFact
Modified:
trunk/netsurf/atari/doc/readme.txt
Modified: trunk/netsurf/atari/doc/readme.txt
URL: http://source.netsurf-browser.org/trunk/netsurf/atari/doc/readme.txt?rev=...
==============================================================================
--- trunk/netsurf/atari/doc/readme.txt (original)
+++ trunk/netsurf/atari/doc/readme.txt Sun Mar 20 17:45:09 2011
@@ -145,6 +145,7 @@
Greetings & Thanks
------------------
+ - AtFact for providing help with resource files & images
- The MiNT Mailing list, they all helped me a lot!
- The NetSurf Mailing list guys, especially the Amiga guys.
- The NetSurf developers that did a great job!
@@ -153,6 +154,7 @@
- The forum.atari-home.de members for giving me much help
during setup of my atari!
+
----
M0N0 - 19.02.2011
12 years, 2 months
r12113 mono - in /trunk/netsurf/atari: misc.h schedule.c treeview.h
by netsurf@semichrome.net
Author: mono
Date: Sun Mar 20 17:43:07 2011
New Revision: 12113
URL: http://source.netsurf-browser.org?rev=12113&view=rev
Log:
Added missing prototypes.
Modified:
trunk/netsurf/atari/misc.h
trunk/netsurf/atari/schedule.c
trunk/netsurf/atari/treeview.h
Modified: trunk/netsurf/atari/misc.h
URL: http://source.netsurf-browser.org/trunk/netsurf/atari/misc.h?rev=12113&r1...
==============================================================================
--- trunk/netsurf/atari/misc.h (original)
+++ trunk/netsurf/atari/misc.h Sun Mar 20 17:43:07 2011
@@ -36,4 +36,7 @@
char *get_rsc_string( int idx );
void gem_set_cursor( MFORM_EX * cursor );
void dbg_grect( char * str, GRECT * r );
+void * ldg_open( char * name, short * global );
+void * ldg_find( char * name, short * ldg );
+int ldg_close( void * ldg, short * global );
#endif
Modified: trunk/netsurf/atari/schedule.c
URL: http://source.netsurf-browser.org/trunk/netsurf/atari/schedule.c?rev=1211...
==============================================================================
--- trunk/netsurf/atari/schedule.c (original)
+++ trunk/netsurf/atari/schedule.c Sun Mar 20 17:43:07 2011
@@ -16,6 +16,8 @@
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
+#include <stdlib.h>
+#include <string.h>
#include <sys/time.h>
#include <time.h>
Modified: trunk/netsurf/atari/treeview.h
URL: http://source.netsurf-browser.org/trunk/netsurf/atari/treeview.h?rev=1211...
==============================================================================
--- trunk/netsurf/atari/treeview.h (original)
+++ trunk/netsurf/atari/treeview.h Sun Mar 20 17:43:07 2011
@@ -40,7 +40,7 @@
typedef struct atari_treeview * NSTREEVIEW;
-NSTREEVIEW atari_treeview_create( uint32_t flags, WINDOW * win ) ;
+NSTREEVIEW atari_treeview_create( uint32_t flags, WINDOW * win );
void atari_treeview_destroy( NSTREEVIEW tv );
void atari_treeview_open( NSTREEVIEW tv );
void atari_treeview_close( NSTREEVIEW tv );
12 years, 2 months
r12112 mono - in /trunk/netsurf/atari: font.c gui.c
by netsurf@semichrome.net
Author: mono
Date: Sun Mar 20 17:41:29 2011
New Revision: 12112
URL: http://source.netsurf-browser.org?rev=12112&view=rev
Log:
added resource: handling, gui_poll now checks for browser_reformat_pending
Modified:
trunk/netsurf/atari/font.c
trunk/netsurf/atari/gui.c
Modified: trunk/netsurf/atari/font.c
URL: http://source.netsurf-browser.org/trunk/netsurf/atari/font.c?rev=12112&r1...
==============================================================================
--- trunk/netsurf/atari/font.c (original)
+++ trunk/netsurf/atari/font.c Sun Mar 20 17:41:29 2011
@@ -20,9 +20,6 @@
#include <assert.h>
#include <stdbool.h>
#include <windom.h>
-
-#include <ft2build.h>
-#include FT_CACHE_H
#include "css/css.h"
#include "render/font.h"
Modified: trunk/netsurf/atari/gui.c
URL: http://source.netsurf-browser.org/trunk/netsurf/atari/gui.c?rev=12112&r1=...
==============================================================================
--- trunk/netsurf/atari/gui.c (original)
+++ trunk/netsurf/atari/gui.c Sun Mar 20 17:41:29 2011
@@ -50,6 +50,7 @@
#include "desktop/mouse.h"
#include "render/html.h"
#include "render/font.h"
+#include "utils/schedule.h"
#include "utils/url.h"
#include "utils/log.h"
#include "utils/messages.h"
@@ -150,7 +151,7 @@
/* right now, schedule is only used for the spinner, */
/* spinner code must be reviewed, so disable schedule for now */
timeout = schedule_run();
- if ( active )
+ if ( active || browser_reformat_pending )
timeout = 1;
if(input_window) {
@@ -175,7 +176,7 @@
}
/* if we have some state that can't be recognized by evnt_multi, don't block
so tracking can take place after timeout: */
- if( MOUSE_IS_DRAGGING() ) // MOUSE_EVNT_IN_PROGRESS()
+ if( MOUSE_IS_DRAGGING() )
timeout = 1;
}
@@ -347,9 +348,9 @@
return;
/* TODO: query AES for max. title length */
if( gw->root && gw->parent == NULL ){
- strncpy((char*)&gw->root->title, title, 79);
- gw->root->title[79] = 0;
- WindSetStr( gw->root->handle, WF_NAME, (char *)&gw->root->title );
+ strncpy(gw->root->title, title, atari_sysinfo.aes_max_win_title_len);
+ gw->root->title[atari_sysinfo.aes_max_win_title_len] = 0;
+ WindSetStr( gw->root->handle, WF_NAME, gw->root->title );
}
}
@@ -463,8 +464,8 @@
gw->browser->bw->scale
);*/
browser_set_content_size( gw,
- content_get_width(gw->browser->bw->current_content),
- content_get_height(gw->browser->bw->current_content)
+ content_get_width(gw->browser->bw->current_content),
+ content_get_height(gw->browser->bw->current_content)
);
}
}
@@ -1051,7 +1052,15 @@
char* gui_get_resource_url(const char *filename)
{
- return NULL;
+ char buf[PATH_MAX];
+ int len;
+ char * ret;
+ printf("gui_find_res: %s\n", filename);
+ atari_find_resource((char*)&buf, filename, filename);
+ printf("found: %s\n", (char*)&buf);
+ /* TODO: handle failure? */
+ len = strlen( (char*)&buf ) + 1;
+ return( path_to_url((char*)&buf) );
}
static void gui_init(int argc, char** argv)
@@ -1124,13 +1133,15 @@
atari_plotter_init( option_atari_screen_driver, option_atari_font_driver );
}
+static char *theapp = "NetSurf";
static void gui_init2(int argc, char** argv)
{
struct browser_window *bw;
const char *addr = NETSURF_HOMEPAGE;
MenuBar( h_gem_menu , 1 );
bind_global_events();
- if( atari_sysinfo.gemdos_version > TOS4VER ) {
+ menu_register( -1, theapp);
+ if (sys_type() & (SYS_MAGIC|SYS_NAES|SYS_XAAES)) {
menu_register( _AESapid, (char*)" NetSurf ");
}
}
12 years, 2 months
r12111 mono - in /trunk/netsurf/atari: browser_win.c gui.h
by netsurf@semichrome.net
Author: mono
Date: Sun Mar 20 17:38:32 2011
New Revision: 12111
URL: http://source.netsurf-browser.org?rev=12111&view=rev
Log:
Allocate window title string memory dynamically.
Modified:
trunk/netsurf/atari/browser_win.c
trunk/netsurf/atari/gui.h
Modified: trunk/netsurf/atari/browser_win.c
URL: http://source.netsurf-browser.org/trunk/netsurf/atari/browser_win.c?rev=1...
==============================================================================
--- trunk/netsurf/atari/browser_win.c (original)
+++ trunk/netsurf/atari/browser_win.c Sun Mar 20 17:38:32 2011
@@ -55,6 +55,7 @@
#include "atari/plot/plotter.h"
#include "atari/dragdrop.h"
#include "atari/search.h"
+#include "atari/osspec.h"
bool cfg_rt_resize = false;
@@ -116,6 +117,7 @@
if( gw->root == NULL )
return( -1 );
memset( gw->root, 0, sizeof(struct s_gui_win_root) );
+ gw->root->title = malloc(atari_sysinfo.aes_max_win_title_len+1);
gw->root->handle = WindCreate( flags,40, 40, app.w, app.h );
gw->root->cmproot = mt_CompCreate(&app, CLT_VERTICAL, 1, 1);
WindSetPtr( gw->root->handle, WF_COMPONENT, gw->root->cmproot, NULL);
@@ -140,8 +142,9 @@
}
WindSetStr(gw->root->handle, WF_ICONTITLE, (char*)"NetSurf");
+
+ /* Event Handlers: */
EvntDataAttach( gw->root->handle, WM_CLOSED, evnt_window_close, NULL );
-
/* capture resize/move events so we can handle that manually */
if( !cfg_rt_resize ) {
EvntAttach( gw->root->handle, WM_SIZED, evnt_window_resize);
@@ -206,6 +209,9 @@
/* needed? */ /*listRemove( (LINKABLE*)gw->root->cmproot ); */
LOG(("Freeing root window"));
if( gw->root ) {
+ /* TODO: check if no other browser is bound to this root window! */
+ if( gw->root->title )
+ free( gw->root->title );
if( gw->root->cmproot )
mt_CompDelete( &app, gw->root->cmproot );
ApplWrite( _AESapid, WM_DESTROY, gw->root->handle->handle, 0, 0, 0, 0);
Modified: trunk/netsurf/atari/gui.h
URL: http://source.netsurf-browser.org/trunk/netsurf/atari/gui.h?rev=12111&r1=...
==============================================================================
--- trunk/netsurf/atari/gui.h (original)
+++ trunk/netsurf/atari/gui.h Sun Mar 20 17:38:32 2011
@@ -217,7 +217,7 @@
struct s_focus_info focus;
float scale;
bool throbbing;
- char title[80];
+ char * title;
GRECT loc; /* current size of window on screen */
};
12 years, 2 months
r12110 mono - /trunk/netsurf/atari/browser.c
by netsurf@semichrome.net
Author: mono
Date: Sun Mar 20 17:33:56 2011
New Revision: 12110
URL: http://source.netsurf-browser.org?rev=12110&view=rev
Log:
Removed special handling of non html content, added sanity checking for scroll requests.
Modified:
trunk/netsurf/atari/browser.c
Modified: trunk/netsurf/atari/browser.c
URL: http://source.netsurf-browser.org/trunk/netsurf/atari/browser.c?rev=12110...
==============================================================================
--- trunk/netsurf/atari/browser.c (original)
+++ trunk/netsurf/atari/browser.c Sun Mar 20 17:33:56 2011
@@ -113,6 +113,10 @@
browser_evnt_wdestroy, (void*)bnew );
mt_CompDataAttach( &app, bnew->comp, CDT_OWNER, gw );
+ bnew->scroll.requested.y = 0;
+ bnew->scroll.requested.x = 0;
+ bnew->scroll.current.x = 0;
+ bnew->scroll.current.y = 0;
}
return( bnew );
}
@@ -440,11 +444,12 @@
}
-
switch( mode ) {
case WA_UPPAGE:
case WA_UPLINE:
+ if( max_y_scroll < 1 )
+ return;
if( abs == false )
b->scroll.requested.y -= value;
else
@@ -453,6 +458,8 @@
case WA_DNPAGE:
case WA_DNLINE:
+ if( max_y_scroll < 1 )
+ return;
if( abs == false )
b->scroll.requested.y += value;
else
@@ -461,6 +468,8 @@
case WA_LFPAGE:
case WA_LFLINE:
+ if( max_x_scroll < 1 )
+ return;
if( abs == false )
b->scroll.requested.x -= value;
else
@@ -469,6 +478,8 @@
case WA_RTPAGE:
case WA_RTLINE:
+ if( max_x_scroll < 1 )
+ return;
if( abs == false )
b->scroll.requested.x += value;
else
@@ -861,27 +872,11 @@
current_redraw_browser = b->bw;
- if(content_get_type(b->bw->current_content) == CONTENT_HTML ) {
- clip.x0 = b->redraw.area.x0;
- clip.y0 = b->redraw.area.y0;
- clip.x1 = b->redraw.area.x1;
- clip.y1 = b->redraw.area.y1;
- } else {
- /* totally different coords, I don't understand why! */
- clip.x0 = b->redraw.area.x0 + b->scroll.current.x;
- clip.y0 = b->redraw.area.y0 + b->scroll.current.y;
- clip.x1 = b->redraw.area.x1 + b->scroll.current.x;
- clip.y1 = b->redraw.area.y1 + b->scroll.current.y;
- /* must clear the surface: */
- plot.clip( &clip );
- plot.rectangle( b->redraw.area.x0,
- b->redraw.area.y0,
- b->redraw.area.x1,
- b->redraw.area.y1,
- plot_style_fill_white
- );
- }
-
+ clip.x0 = b->redraw.area.x0;
+ clip.y0 = b->redraw.area.y0;
+ clip.x1 = b->redraw.area.x1;
+ clip.y1 = b->redraw.area.y1;
+
browser_window_redraw( b->bw, -b->scroll.current.x,
-b->scroll.current.y, &clip );
12 years, 2 months
r12109 mono - in /trunk/netsurf/atari/plot: font_internal.c plotter.c plotter.h plotter_vdi.c
by netsurf@semichrome.net
Author: mono
Date: Sun Mar 20 17:28:53 2011
New Revision: 12109
URL: http://source.netsurf-browser.org?rev=12109&view=rev
Log:
When using onscreen plotter: Collect nsfb internal font characters into a single bitmap instead of plotting each character.
Modified:
trunk/netsurf/atari/plot/font_internal.c
trunk/netsurf/atari/plot/plotter.c
trunk/netsurf/atari/plot/plotter.h
trunk/netsurf/atari/plot/plotter_vdi.c
Modified: trunk/netsurf/atari/plot/font_internal.c
URL: http://source.netsurf-browser.org/trunk/netsurf/atari/plot/font_internal....
==============================================================================
--- trunk/netsurf/atari/plot/font_internal.c (original)
+++ trunk/netsurf/atari/plot/font_internal.c Sun Mar 20 17:28:53 2011
@@ -24,6 +24,8 @@
#include "utils/utf8.h"
#include "utils/log.h"
+#include <windom.h>
+
static int dtor( FONT_PLOTTER self );
static int str_width( FONT_PLOTTER self,const plot_font_style_t *fstyle, const char * str, size_t length, int * width );
@@ -43,6 +45,10 @@
const struct fb_font_desc font_bold;
const struct fb_font_desc font_italic_bold;
+static MFDB tmp;
+static int tmp_mfdb_size;
+
+#define FONTDATAMAX 4096
static const struct fb_font_desc*
fb_get_font(const plot_font_style_t *fstyle)
@@ -92,6 +98,9 @@
static int dtor( FONT_PLOTTER self )
{
+ if( tmp.fd_addr != NULL ){
+ free( tmp.fd_addr );
+ }
return( 1 );
}
@@ -169,28 +178,73 @@
utf8_to_font_encoding(fb_font, text, length, &buffer);
if (buffer == NULL)
- return true;
+ return 1;
/* y is given to the fonts baseline we need it to the fonts top */
- y-=((fb_font->height * 75)/100);
-
- y+=1; /* the coord is the bottom-left of the pixels offset by 1 to make
+ y-=((fb_font->height * 75)/100);
+
+ /* needed? */
+ y+=1; /* the coord is the bottom-left of the pixels offset by 1 to make
* it work since fb coords are the top-left of pixels
*/
- c = fstyle->foreground;
- /* in -> BGR */
- /* out -> ARGB */
- c = (ABGR_TO_RGB(c) | 0xFF);
blen = strlen(buffer);
- loc.g_y = y;
- loc.g_w = fb_font->width;
- loc.g_h = fb_font->height;
- for (chr = 0; chr < blen; chr++) {
- loc.g_x = x;
- chrp = fb_font->data + ((unsigned char)buffer[chr] * fb_font->height);
- draw_glyph1(self, &loc, (uint8_t *)chrp, 32, c);
- x+=fb_font->width;
- }
+ if ( blen < 1 ) {
+ return( 1 );
+ }
+
+ if( self->plotter->flags & PLOT_FLAG_OFFSCREEN ){
+ /* when the plotter is an offscreen plotter the call to
+ bitmap() isn't that expensive. Draw an 8 bit bitmap into the
+ offscreen buffer.
+ */
+ c = fstyle->foreground;
+ /* in -> BGR */
+ /* out -> ARGB */
+ c = (ABGR_TO_RGB(c) | 0xFF);
+ loc.g_y = y;
+ loc.g_x = x;
+ loc.g_w = fb_font->width;
+ loc.g_h = fb_font->height;
+ for (chr = 0; chr < blen; chr++) {
+ loc.g_x = x;
+ chrp = fb_font->data + ((unsigned char)buffer[chr] * fb_font->height);
+ draw_glyph1(self, &loc, (uint8_t *)chrp, 32, c);
+ x+=fb_font->width;
+ }
+ } else {
+ /* render the whole string into an monochrom mfdb */
+ /* and plot that to reduce overhead */
+ loc.g_x = x;
+ loc.g_y = y;
+ loc.g_w = blen * fb_font->width;
+ assert( loc.g_w > 0 );
+ loc.g_h = fb_font->height;
+ int stride = MFDB_STRIDE( loc.g_w );
+ if( tmp.fd_addr == NULL || tmp_mfdb_size < MFDB_SIZE( 1, stride, loc.g_h) ){
+ tmp_mfdb_size = init_mfdb( 1, loc.g_w, loc.g_h+1, MFDB_FLAG_STAND | MFDB_FLAG_ZEROMEM, &tmp );
+ } else {
+ void * buf = tmp.fd_addr;
+ int size = init_mfdb( 1, loc.g_w, loc.g_h+1, MFDB_FLAG_STAND | MFDB_FLAG_NOALLOC, &tmp );
+ tmp.fd_addr = buf;
+ memset( tmp.fd_addr, 0, size );
+ }
+ int ypos;
+ int rowsize = tmp.fd_wdwidth << 1;
+ char * d;
+ uint32_t * pp;
+ for (chr = 0; chr < blen; chr++) {
+ pp = (uint32_t*)fb_font->data + ((unsigned char)buffer[chr] * fb_font->height);
+ d = ((uint8_t*)tmp.fd_addr) + chr;
+ for( ypos=0; (unsigned int)ypos<loc.g_h; ypos++){
+ *d = (unsigned char)*pp++;
+ d += rowsize;
+ }
+ }
+ unsigned short out[4];
+ rgb_to_vdi1000( (unsigned char*)&fstyle->foreground, (unsigned short*)&out );
+ vs_color( self->plotter->vdi_handle, OFFSET_CUSTOM_COLOR, (unsigned short*)&out[0] );
+ self->plotter->plot_mfdb( self->plotter, &loc, &tmp, PLOT_FLAG_TRANS );
+ }
free(buffer);
return( 1 );
@@ -199,8 +253,6 @@
/* ------------------*/
/* Fontdata */
/* ------------------*/
-
-#define FONTDATAMAX 4096
static const uint32_t fontdata_bold[FONTDATAMAX] = {
0x00, 0xFE, 0x00, 0xEE, 0xAA, 0xAA, 0xAA, 0xEE,
Modified: trunk/netsurf/atari/plot/plotter.c
URL: http://source.netsurf-browser.org/trunk/netsurf/atari/plot/plotter.c?rev=...
==============================================================================
--- trunk/netsurf/atari/plot/plotter.c (original)
+++ trunk/netsurf/atari/plot/plotter.c Sun Mar 20 17:28:53 2011
@@ -683,16 +683,22 @@
}
-int init_mfdb(int bpp, int w, int h, bool stand, MFDB * out )
+int init_mfdb(int bpp, int w, int h, uint32_t flags, MFDB * out )
{
int dststride;
dststride = MFDB_STRIDE( w );
+ int size = MFDB_SIZE( bpp, dststride, h );
if( bpp > 0 ) {
- out->fd_addr = malloc( ((dststride >> 3) * h) * bpp );
- if( out->fd_addr == NULL ){
- return( 0 );
- }
- out->fd_stand = stand;
+ if( (flags & MFDB_FLAG_NOALLOC) == 0 ) {
+ out->fd_addr = malloc( size );
+ if( out->fd_addr == NULL ){
+ return( 0 );
+ }
+ if( (flags & MFDB_FLAG_ZEROMEM) ){
+ memset( out->fd_addr, 0, size );
+ }
+ }
+ out->fd_stand = (flags & MFDB_FLAG_STAND) ? 1 : 0;
out->fd_nplanes = (short)bpp;
out->fd_r1 = out->fd_r2 = out->fd_r3 = 0;
} else {
@@ -701,7 +707,7 @@
out->fd_w = dststride;
out->fd_h = h;
out->fd_wdwidth = dststride >> 4;
- return( 1 );
+ return( size );
}
@@ -714,6 +720,21 @@
return( 1 );
}
+void plotter_get_clip_grect( GEM_PLOTTER self, GRECT * out )
+{
+ out->g_x = self->clipping.x0;
+ out->g_y = self->clipping.y0;
+ out->g_w = self->clipping.x1 - self->clipping.x0;
+ out->g_h = self->clipping.y1 - self->clipping.y0;
+}
+
+void plotter_get_visible_grect( GEM_PLOTTER self, GRECT * out )
+{
+ out->g_x = self->clipping.x0;
+ out->g_y = self->clipping.y0;
+ out->g_w = self->clipping.x1 - self->clipping.x0;
+ out->g_h = self->clipping.y1 - self->clipping.y0;
+}
int plotter_std_clip(GEM_PLOTTER self, const struct rect * clip)
{
Modified: trunk/netsurf/atari/plot/plotter.h
URL: http://source.netsurf-browser.org/trunk/netsurf/atari/plot/plotter.h?rev=...
==============================================================================
--- trunk/netsurf/atari/plot/plotter.h (original)
+++ trunk/netsurf/atari/plot/plotter.h Sun Mar 20 17:28:53 2011
@@ -38,6 +38,7 @@
#include "utils/log.h"
#ifndef ceilf
+#warning "ceilf emulation"
#define ceilf(x) (float)ceil((double)x)
#endif
@@ -54,6 +55,10 @@
#define PLOT_FLAG_LOCKED 0x02
#define PLOT_FLAG_DITHER 0x04
#define PLOT_FLAG_TRANS 0x08
+
+#define MFDB_FLAG_STAND 0x01
+#define MFDB_FLAG_ZEROMEM 0x02
+#define MFDB_FLAG_NOALLOC 0x04
/* Error codes: */
#define ERR_BUFFERSIZE_EXCEEDS_SCREEN 1
@@ -168,6 +173,7 @@
typedef int (*_pmf_bitmap_resize) ( GEM_PLOTTER self, struct bitmap * bm, int nw, int nh );
typedef int (*_pmf_bitmap)(GEM_PLOTTER self, struct bitmap * bmp, int x, int y,
unsigned long bg, unsigned long flags );
+typedef int (*_pmf_plot_mfdb)(GEM_PLOTTER self, GRECT * loc, MFDB * mfdb, uint32_t flags);
typedef int (*_pmf_text)(GEM_PLOTTER self, int x, int y, const char *text, size_t length, const plot_font_style_t *fstyle);
typedef int (*_pmf_dtor)(GEM_PLOTTER self);
@@ -206,6 +212,7 @@
_pmf_path path;
_pmf_bitmap_resize bitmap_resize;
_pmf_bitmap bitmap;
+ _pmf_plot_mfdb plot_mfdb;
_pmf_text text;
_pmf_dtor dtor;
};
@@ -296,9 +303,10 @@
If bpp == 0, this function assumes that the MFDB shall point to the screen
and will not allocate any memory (mfdb.fd_addr == 0).
The function will return 0 when the memory allocation fails
- ( out of memory).
-*/
-int init_mfdb(int bpp, int w, int h, bool stand, MFDB * out );
+ ( out of memory), otherwise it returns the size of the mfdb.fd_addr
+ as number of bytes.
+*/
+int init_mfdb(int bpp, int w, int h, uint32_t flags, MFDB * out );
/* shared / static methods follows */
@@ -308,9 +316,20 @@
int plotter_get_clip( GEM_PLOTTER self, struct rect * out );
/*
+ Get clipping for current framebuffer as GRECT
+*/
+void plotter_get_clip_grect( GEM_PLOTTER self, GRECT * out );
+
+/*
+ Get current visible coords
+*/
+void plotter_get_visible_grect( GEM_PLOTTER self, GRECT * out );
+
+/*
Set clipping for current framebuffer
*/
int plotter_std_clip(GEM_PLOTTER self, const struct rect * clip);
+
/*
convert framebuffer clipping to vdi clipping and activates it
@@ -358,5 +377,6 @@
#define OFFSET_CUSTOM_COLOR 255
#define RGB_TO_VDI(c) rgb_to_666_index( (c&0xFF),(c&0xFF00)>>8,(c&0xFF0000)>>16)+OFFSET_WEB_PAL
#define ABGR_TO_RGB(c) ( ((c&0xFF)<<16) | (c&0xFF00) | ((c&0xFF0000)>>16) ) << 8
+#define MFDB_SIZE( bpp, stride, h ) ( ((stride >> 3) * h) * bpp )
#endif
Modified: trunk/netsurf/atari/plot/plotter_vdi.c
URL: http://source.netsurf-browser.org/trunk/netsurf/atari/plot/plotter_vdi.c?...
==============================================================================
--- trunk/netsurf/atari/plot/plotter_vdi.c (original)
+++ trunk/netsurf/atari/plot/plotter_vdi.c Sun Mar 20 17:28:53 2011
@@ -65,6 +65,7 @@
static int bitmap_resize( GEM_PLOTTER self, struct bitmap * img, int nw, int nh );
static int bitmap( GEM_PLOTTER self, struct bitmap * bmp, int x, int y,
unsigned long bg, unsigned long flags );
+static int plot_mfdb( GEM_PLOTTER self, GRECT * where, MFDB * mfdb, uint32_t flags);
static int text(GEM_PLOTTER self, int x, int y, const char *text,size_t length, const plot_font_style_t *fstyle);
static unsigned short sys_pal[256][3]; /*RGB*/
@@ -143,6 +144,7 @@
self->path = path;
self->bitmap = bitmap;
self->bitmap_resize = bitmap_resize;
+ self->plot_mfdb = plot_mfdb;
self->text = text;
LOG(("Screen: x: %d, y: %d\n", vdi_sysinfo.scr_w, vdi_sysinfo.scr_h));
@@ -352,10 +354,7 @@
int src_offs;
GRECT screen_area, tmp, visible;
short pxy[10];
- visible.g_x = CURFB(self).vis_x;
- visible.g_y = CURFB(self).vis_y;
- visible.g_w = CURFB(self).vis_w;
- visible.g_h = CURFB(self).vis_h;
+ plotter_get_visible_grect( self, &visible );
/*
LOG(("%s: %s %d\n", (char*)__FILE__, __FUNCTION__, __LINE__));
@@ -453,10 +452,7 @@
GRECT vis;
/* clip to visible rect, only needed for onscreen renderer: */
- vis.g_x = CURFB(self).vis_x;
- vis.g_y = CURFB(self).vis_y;
- vis.g_w = CURFB(self).vis_w;
- vis.g_h = CURFB(self).vis_h;
+ plotter_get_visible_grect( self, &vis );
if( !rc_intersect(&vis, &src) )
return 1;
@@ -990,10 +986,7 @@
return( true );
}
- vis.g_x = CURFB(self).vis_x;
- vis.g_y = CURFB(self).vis_y;
- vis.g_w = CURFB(self).vis_w;
- vis.g_h = CURFB(self).vis_h;
+ plotter_get_visible_grect( self, &vis );
if( !rc_intersect( &vis, &off) ) {
return( true );
}
@@ -1020,6 +1013,64 @@
return( true );
}
+static int plot_mfdb (GEM_PLOTTER self, GRECT * loc, MFDB * insrc, uint32_t flags)
+{
+
+ MFDB screen, tran;
+ MFDB * src;
+ short pxy[8];
+ short pxyclip[4];
+ short c[2] = {OFFSET_CUSTOM_COLOR, WHITE};
+ plotter_vdi_clip(self, true);
+
+ init_mfdb( 0, loc->g_w, loc->g_h, 0, &screen );
+
+ pxy[0] = 0;
+ pxy[1] = 0;
+ pxy[2] = loc->g_w -1;
+ pxy[3] = loc->g_h -1;
+ pxy[4] = CURFB(self).x + loc->g_x;
+ pxy[5] = CURFB(self).y + loc->g_y;
+ pxy[6] = pxy[4] + loc->g_w -1;
+ pxy[7] = pxy[5] + loc->g_h -1;
+
+ if( insrc->fd_stand ){
+ int size = init_mfdb( insrc->fd_nplanes, loc->g_w, loc->g_h,
+ MFDB_FLAG_NOALLOC,
+ &tran
+ );
+ if( DUMMY_PRIV(self)->size_buf_scr == 0 ){
+ DUMMY_PRIV(self)->buf_scr.fd_addr = malloc( size );
+ DUMMY_PRIV(self)->size_buf_scr = size;
+ } else {
+ if( size > DUMMY_PRIV(self)->size_buf_scr ) {
+ DUMMY_PRIV(self)->buf_scr.fd_addr = realloc(
+ DUMMY_PRIV(self)->buf_scr.fd_addr, size
+ );
+ DUMMY_PRIV(self)->size_buf_scr = size;
+ }
+ }
+ tran.fd_addr = DUMMY_PRIV(self)->buf_scr.fd_addr;
+ vr_trnfm( self->vdi_handle, insrc, &tran );
+ src = &tran;
+ } else {
+ src = insrc;
+ }
+
+ if( flags & PLOT_FLAG_TRANS && src->fd_nplanes == 1){
+ vrt_cpyfm( self->vdi_handle, MD_TRANS, (short*)pxy, src, &screen, (short*)&c );
+ } else {
+
+ }
+ if( insrc->fd_stand ){
+ // TODO: shrink conv buffer
+ }
+
+
+ plotter_vdi_clip(self, false);
+ return( 1 );
+}
+
static int text(GEM_PLOTTER self, int x, int y, const char *text, size_t length, const plot_font_style_t *fstyle)
{
self->font_plotter->text( self->font_plotter, x, y,
12 years, 2 months
r12108 chris_y - /trunk/netsurf/amiga/gui.c
by netsurf@semichrome.net
Author: chris_y
Date: Sat Mar 19 17:40:02 2011
New Revision: 12108
URL: http://source.netsurf-browser.org?rev=12108&view=rev
Log:
print caret at scroll position netsurf believes the page is at, rather than where the
gui says it is
Modified:
trunk/netsurf/amiga/gui.c
Modified: trunk/netsurf/amiga/gui.c
URL: http://source.netsurf-browser.org/trunk/netsurf/amiga/gui.c?rev=12108&r1=...
==============================================================================
--- trunk/netsurf/amiga/gui.c (original)
+++ trunk/netsurf/amiga/gui.c Sat Mar 19 17:40:02 2011
@@ -3746,8 +3746,8 @@
gui_window_remove_caret(g);
GetAttr(SPACE_AreaBox,g->shared->objects[GID_BROWSER],(ULONG *)&bbox);
- ami_get_hscroll_pos(g->shared, (ULONG *)&xs);
- ami_get_vscroll_pos(g->shared, (ULONG *)&ys);
+ xs = g->scrollx;
+ ys = g->scrolly;
SetAPen(g->shared->win->RPort,3);
12 years, 2 months