r11554 chris_y - /trunk/netsurf/amiga/system_colour.c
by netsurf@semichrome.net
Author: chris_y
Date: Sun Jan 30 16:57:56 2011
New Revision: 11554
URL: http://source.netsurf-browser.org?rev=11554&view=rev
Log:
Fix colour setting. GetRGB32 seems to have been designed for some futuristic 96bpp
display device.
Modified:
trunk/netsurf/amiga/system_colour.c
Modified: trunk/netsurf/amiga/system_colour.c
URL: http://source.netsurf-browser.org/trunk/netsurf/amiga/system_colour.c?rev...
==============================================================================
--- trunk/netsurf/amiga/system_colour.c (original)
+++ trunk/netsurf/amiga/system_colour.c Sun Jan 30 16:57:56 2011
@@ -30,6 +30,7 @@
#include <proto/graphics.h>
#include <proto/intuition.h>
#include <intuition/screens.h>
+#include <datatypes/pictureclass.h>
struct gui_system_colour_ctx {
const char *name;
@@ -326,18 +327,21 @@
css_color ami_css_colour_from_pen(struct Screen *screen, UWORD pen)
{
- css_color colour = 0x00000000;
+ css_color css_colour = 0x00000000;
+ ULONG colour[3];
struct DrawInfo *drinfo = GetScreenDrawInfo(screen);
if(drinfo == NULL) return 0x00000000;
- /* Get the colour of the pen being used for "pen", and force it opaque */
+ /* Get the colour of the pen being used for "pen" */
GetRGB32(screen->ViewPort.ColorMap, drinfo->dri_Pens[pen], 1, (ULONG *)&colour);
- colour |= 0xff000000;
-
- // printf("Pen %ld\n Palette entry %ld\n Colour %lx\n", pen, drinfo->dri_Pens[pen], colour);
+
+ /* convert it to a css_color */
+ css_colour = (0xff << 24) |
+ ((colour[0] & 0xff000000) >> 8) |
+ ((colour[1] & 0xff000000) >> 16) |
+ ((colour[2] & 0xff000000) >> 24);
FreeScreenDrawInfo(screen, drinfo);
-
- return colour;
-}
+ return css_colour;
+}
12 years, 3 months
r11553 mono - /trunk/netsurf/atari/Makefile.target
by netsurf@semichrome.net
Author: mono
Date: Sun Jan 30 16:34:52 2011
New Revision: 11553
URL: http://source.netsurf-browser.org?rev=11553&view=rev
Log:
add default system colour handlers to atari frontend
Modified:
trunk/netsurf/atari/Makefile.target
Modified: trunk/netsurf/atari/Makefile.target
URL: http://source.netsurf-browser.org/trunk/netsurf/atari/Makefile.target?rev...
==============================================================================
--- trunk/netsurf/atari/Makefile.target (original)
+++ trunk/netsurf/atari/Makefile.target Sun Jan 30 16:34:52 2011
@@ -40,7 +40,7 @@
plot.c plot/plotter.c plot/plotter_vdi.c plot/eddi.s \
plot/font_vdi.c plot/font_freetype.c \
browser_win.c toolbar.c statusbar.c browser.c \
- global_evnt.c osspec.c
+ global_evnt.c osspec.c system_colour.c
S_ATARI := $(addprefix atari/,$(S_ATARI))
12 years, 3 months
r11552 mono - /trunk/netsurf/atari/toolbar.c
by netsurf@semichrome.net
Author: mono
Date: Sun Jan 30 16:31:37 2011
New Revision: 11552
URL: http://source.netsurf-browser.org?rev=11552&view=rev
Log:
Improved call to v_gtext.
Modified:
trunk/netsurf/atari/toolbar.c
Modified: trunk/netsurf/atari/toolbar.c
URL: http://source.netsurf-browser.org/trunk/netsurf/atari/toolbar.c?rev=11552...
==============================================================================
--- trunk/netsurf/atari/toolbar.c (original)
+++ trunk/netsurf/atari/toolbar.c Sun Jan 30 16:31:37 2011
@@ -188,14 +188,15 @@
{
LGRECT work, clip;
short pxy[10];
- short i,d;
- short mchars, width, cs;
+ short i;
+ short d;
+ short mchars;
struct gui_window * gw = (struct gui_window *)mt_CompDataSearch(&app, c, CDT_OWNER);
assert( gw != NULL );
assert( gw->browser != NULL );
assert( gw->root != NULL );
assert( gw->browser->bw != NULL );
- short start = gw->root->toolbar->url.scrollx;
+ CMP_TOOLBAR tb = gw->root->toolbar;
mt_CompGetLGrect(&app, c, WF_WORKXYWH, &work);
clip = work;
@@ -207,11 +208,7 @@
pxy[3] = clip.g_h + clip.g_y;
vs_clip( vdih, 1, (short*)&pxy );
- width = work.g_w-6; /* subtract 6px -> 3px padding around text on each side */
- cs = gw->root->toolbar->url.char_size;
- mchars = (width / cs);
- char textcpy[mchars+3];
- memset(&textcpy, 0, mchars + 3 );
+ mchars = (work.g_w-6 / tb->url.char_size); /* subtract 6px -> 3px padding around text on each side */
vswr_mode( vdih, MD_REPLACE);
vsf_perimeter( vdih, 0 );
@@ -256,31 +253,46 @@
pxy[3] = work.g_y + ((TOOLBAR_HEIGHT - URLBOX_HEIGHT)/2) + URLBOX_HEIGHT ;
vsf_color( vdih, WHITE);
v_bar( vdih, pxy );
- if( strlen(gw->root->toolbar->url.text) > 0 )
- strncpy( (char*)&textcpy, (char*)&gw->root->toolbar->url.text[start], mchars );
- else
- strcpy( (char*)&textcpy, " " );
-
- v_gtext( vdih, work.g_x + 3, work.g_y + ((TOOLBAR_HEIGHT - URLBOX_HEIGHT)/2) + 2, (char*)&textcpy );
+ if( gw->root->toolbar->url.used > 1 ) {
+ short curx;
+ short vqw[4];
+ char t[2];
+ short cw = 0;
+
+ t[1]=0;
+ if( atari_sysinfo.sfont_monospaced ) {
+ vqt_width( vdih, t[0], &vqw[0], &vqw[1], &vqw[2] );
+ cw = vqw[0];
+ }
+ for( curx = work.g_x + 3, i=tb->url.scrollx ; (curx < clip.g_x + clip.g_w) && i < MIN(tb->url.used-1, mchars); i++ ){
+ t[0] = tb->url.text[i];
+ v_gtext( vdih, curx, work.g_y + ((TOOLBAR_HEIGHT - URLBOX_HEIGHT)/2) + 2, (char*)&t );
+ if( !atari_sysinfo.sfont_monospaced ) {
+ vqt_width( vdih, t[0], &vqw[0], &vqw[1], &vqw[2] );
+ curx += vqw[0];
+ } else {
+ curx += cw;
+ }
+ }
+ }
if( window_url_widget_has_focus( gw ) ) {
/* draw caret: */
- pxy[0] = 3 + work.g_x + ((gw->root->toolbar->url.caret_pos - gw->root->toolbar->url.scrollx) * cs);
+ pxy[0] = 3 + work.g_x + ((tb->url.caret_pos - tb->url.scrollx) * tb->url.char_size);
pxy[1] = pxy[1] + 1;
- pxy[2] = 3 + work.g_x + ((gw->root->toolbar->url.caret_pos - gw->root->toolbar->url.scrollx) * cs);
+ pxy[2] = 3 + work.g_x + ((tb->url.caret_pos - tb->url.scrollx) * tb->url.char_size);
pxy[3] = pxy[3] - 1 ;
v_pline( vdih, 2, pxy );
/* draw selection: */
- if( gw->root->toolbar->url.selection_len != 0 ) {
+ if( tb->url.selection_len != 0 ) {
vswr_mode( vdih, MD_XOR);
vsl_color( vdih, BLACK);
- pxy[0] = 3 + work.g_x + ((gw->root->toolbar->url.caret_pos - gw->root->toolbar->url.scrollx) * cs);
- pxy[2] = pxy[0] + ( gw->root->toolbar->url.selection_len * cs);
+ pxy[0] = 3 + work.g_x + ((tb->url.caret_pos - tb->url.scrollx) * tb->url.char_size);
+ pxy[2] = pxy[0] + ( gw->root->toolbar->url.selection_len * tb->url.char_size);
v_bar( vdih, pxy );
vswr_mode( vdih, MD_REPLACE );
}
}
-
vs_clip( vdih, 0, (short*)&pxy );
}
@@ -636,7 +648,7 @@
ret = true;
}
}
- else if( (code == NK_DEL) && tb->url.text[tb->url.caret_pos] != 0) {
+ else if( (code == NK_DEL) ) {
if( tb->url.selection_len != 0 ) {
if( tb->url.selection_len < 0 ) {
strcpy(
@@ -652,11 +664,13 @@
}
tb->url.used = strlen( tb->url.text ) + 1;
} else {
- strcpy(
- &tb->url.text[tb->url.caret_pos+tb->url.selection_len],
- &tb->url.text[tb->url.caret_pos+1]
- );
- tb->url.used--;
+ if( tb->url.caret_pos < tb->url.used -1) {
+ strcpy(
+ &tb->url.text[tb->url.caret_pos+tb->url.selection_len],
+ &tb->url.text[tb->url.caret_pos+1]
+ );
+ tb->url.used--;
+ }
}
tb->url.selection_len = 0;
}
@@ -670,7 +684,7 @@
strcpy(&tb->url.text[tb->url.caret_pos], &tb->url.text[tb->url.caret_pos+tb->url.selection_len]);
}
tb->url.used = strlen( tb->url.text ) + 1;
- } else {
+ } else {
tb->url.text[tb->url.caret_pos-1] = 0;
tb->url.used--;
strcat(tb->url.text, &tb->url.text[tb->url.caret_pos]);
12 years, 3 months
r11551 mono - in /trunk/netsurf/atari: statusbar.c statusbar.h
by netsurf@semichrome.net
Author: mono
Date: Sun Jan 30 16:28:47 2011
New Revision: 11551
URL: http://source.netsurf-browser.org?rev=11551&view=rev
Log:
Cleaned up Statusbar code.
Modified:
trunk/netsurf/atari/statusbar.c
trunk/netsurf/atari/statusbar.h
Modified: trunk/netsurf/atari/statusbar.c
URL: http://source.netsurf-browser.org/trunk/netsurf/atari/statusbar.c?rev=115...
==============================================================================
--- trunk/netsurf/atari/statusbar.c (original)
+++ trunk/netsurf/atari/statusbar.c Sun Jan 30 16:28:47 2011
@@ -43,13 +43,14 @@
#include "atari/global_evnt.h"
#include "atari/res/netsurf.rsh"
#include "atari/plot/plotter.h"
+#include "atari/osspec.h"
extern short vdih;
-extern unsigned short gdosversion;
static
void __CDECL evnt_sb_redraw( COMPONENT *c, long buff[8] )
{
+ size_t i;
struct gui_window * gw = (struct gui_window *)mt_CompDataSearch(&app, c, CDT_OWNER);
assert(gw != NULL);
CMP_STATUSBAR sb = gw->root->statusbar;
@@ -74,7 +75,8 @@
vsl_type( vdih, 1);
vsl_width( vdih, 1 );
vst_color(vdih, BLACK);
- vst_point( vdih, 9, &pxy[0], &pxy[1], &pxy[2], &pxy[3] );
+ //vst_point( vdih, 9, &pxy[0], &pxy[1], &pxy[2], &pxy[3] );
+ vst_height( vdih, atari_sysinfo.medium_sfont_pxh, &pxy[0], &pxy[1], &pxy[2], &pxy[3] );
vst_alignment(vdih, 0, 5, &d, &d );
vst_effects( vdih, 0 );
pxyclip[0] = lclip.g_x;
@@ -104,8 +106,31 @@
pxy[2] = work.g_x + work.g_w;
pxy[3] = work.g_y + work.g_h-1;
v_bar( vdih, pxy );
- vswr_mode( vdih, MD_TRANS );
- v_gtext( vdih, work.g_x + 2, work.g_y + 5, (char*)&sb->text );
+
+ if( sb->textlen > 0 ) {
+ short curx;
+ short vqw[4];
+ char t[2];
+ short cw = 0;
+ t[1]=0;
+ if( atari_sysinfo.sfont_monospaced ) {
+ vqt_width( vdih, t[0], &vqw[0], &vqw[1], &vqw[2] );
+ cw = vqw[0];
+ }
+ vswr_mode( vdih, MD_TRANS );
+ for( curx = work.g_x + 2, i=0 ; (curx < lclip.g_x + lclip.g_w) && i < sb->textlen; i++ ){
+ if( curx >= lclip.g_x ) {
+ t[0] = sb->text[i];
+ v_gtext( vdih, curx, work.g_y + 5, (char*)&t );
+ if( !atari_sysinfo.sfont_monospaced ) {
+ vqt_width( vdih, t[0], &vqw[0], &vqw[1], &vqw[2] );
+ curx += vqw[0];
+ } else {
+ curx += cw;
+ }
+ }
+ }
+ }
vswr_mode( vdih, MD_REPLACE );
pxy[0] = work.g_x + work.g_w - MOVER_WH;
@@ -159,7 +184,7 @@
mt_CompDataAttach( &app, s->comp, CDT_OWNER, gw );
mt_CompEvntAttach( &app, s->comp, WM_REDRAW, evnt_sb_redraw );
mt_CompEvntAttach( &app, s->comp, WM_XBUTTON, evnt_sb_click );
- strncpy( (char*)&s->text, " ", 80 );
+ sb_set_text( s, (char*)"" );
return( s );
}
@@ -174,22 +199,20 @@
}
}
-void sb_set_text( struct gui_window * gw , char * text )
-{
- assert( gw->root != NULL);
- if( gw->root == NULL )
- return;
- CMP_STATUSBAR sb = gw->root->statusbar;
+void sb_set_text( CMP_STATUSBAR sb , char * text )
+{
LGRECT work;
-
- if( sb == NULL || gw->browser->attached == false )
- return;
-
- strncpy( (char*)&sb->text, text, 79 );
- sb->text[79]=0;
+ assert( sb != NULL );
+ assert( sb->comp != NULL );
+ strncpy( (char*)&sb->text, text, STATUSBAR_MAX_SLEN );
+ sb->text[STATUSBAR_MAX_SLEN]=0;
+ sb->textlen = strlen( (char*)&sb->text );
if( sb->attached ){
- mt_CompGetLGrect(&app, sb->comp, WF_WORKXYWH, &work);
- ApplWrite( _AESapid, WM_REDRAW, gw->root->handle->handle,
- work.g_x, work.g_y, work.g_w, work.g_h );
- }
-}
+ struct gui_window * gw = (struct gui_window *)mt_CompDataSearch(&app, sb->comp, CDT_OWNER);
+ if( gw != NULL ){
+ mt_CompGetLGrect(&app, sb->comp, WF_WORKXYWH, &work);
+ ApplWrite( _AESapid, WM_REDRAW, gw->root->handle->handle,
+ work.g_x, work.g_y, work.g_w, work.g_h );
+ }
+ }
+}
Modified: trunk/netsurf/atari/statusbar.h
URL: http://source.netsurf-browser.org/trunk/netsurf/atari/statusbar.h?rev=115...
==============================================================================
--- trunk/netsurf/atari/statusbar.h (original)
+++ trunk/netsurf/atari/statusbar.h Sun Jan 30 16:28:47 2011
@@ -21,5 +21,5 @@
CMP_STATUSBAR sb_create( struct gui_window * gw );
void sb_destroy( CMP_STATUSBAR s );
-void sb_set_text( struct gui_window * gw, char * text );
+void sb_set_text( CMP_STATUSBAR sb , char * text );
#endif
12 years, 3 months
r11550 mono - in /trunk/netsurf/atari: osspec.c osspec.h
by netsurf@semichrome.net
Author: mono
Date: Sun Jan 30 16:24:07 2011
New Revision: 11550
URL: http://source.netsurf-browser.org?rev=11550&view=rev
Log:
Cleanup of TOS compatibility fixes.
Added:
trunk/netsurf/atari/osspec.c
trunk/netsurf/atari/osspec.h
Added: trunk/netsurf/atari/osspec.c
URL: http://source.netsurf-browser.org/trunk/netsurf/atari/osspec.c?rev=11550&...
==============================================================================
--- trunk/netsurf/atari/osspec.c (added)
+++ trunk/netsurf/atari/osspec.c Sun Jan 30 16:24:07 2011
@@ -1,0 +1,66 @@
+#include <sys/types.h>
+#include <stdlib.h>
+#include <stdbool.h>
+#include <stdio.h>
+#include <string.h>
+#include <mint/osbind.h>
+#include <mint/cookie.h>
+#include <windom.h>
+
+#include "atari/osspec.h"
+
+NS_ATARI_SYSINFO atari_sysinfo;
+/*
+short appl_xgetinfo( int16_t type, int16_t *out1, int16_t *out2,
+ int16_t *out3, int16_t *out4 )
+{
+ bool has_agi;
+ has_agi = ((app.aes_global[0] == 0x399 && atari_sysinfo.gdosversion == 0x1900)
+ || (app.aes_global[0] > 0x400)
+ || ( appl_find("?AGI") >= 0));
+ if(has_agi){
+ return( mt_appl_getinfo( type, out1, out2, out3, out4, app.aes_global) );
+ } else {
+ return( 0 );
+ }
+}*/
+
+void init_os_info(void)
+{
+ int16_t out[4];
+ atari_sysinfo.gdosversion = Sversion();
+ atari_sysinfo.large_sfont_pxh = 13;
+ atari_sysinfo.medium_sfont_pxh = 6;
+ atari_sysinfo.small_sfont_pxh = 4;
+ /* todo: detect if system font is monospaced */
+ atari_sysinfo.sfont_monospaced = true;
+ if( appl_xgetinfo(AES_LARGEFONT, &out[0], &out[1], &out[2], &out[3] ) > 0 ){
+ atari_sysinfo.large_sfont_pxh = out[0];
+ }
+ if( appl_xgetinfo(AES_SMALLFONT, &out[0], &out[1], &out[2], &out[3] ) > 0 ){
+ atari_sysinfo.small_sfont_pxh = out[0];
+ }
+}
+
+int tos_getcookie(long tag, long * value)
+{
+ COOKIE * cptr;
+ long oldsp;
+
+ if( atari_sysinfo.gdosversion > TOS4VER ){
+ return( Getcookie(tag, value) );
+ }
+
+ cptr = (COOKIE*)Setexc(0x0168, -1L);
+ if(cptr != NULL) {
+ do {
+ if( cptr->c == tag ){
+ if(cptr->v != 0 ){
+ *value = cptr->v;
+ return( C_FOUND );
+ }
+ }
+ } while( (cptr++)->c != 0L );
+ }
+ return( C_NOTFOUND );
+}
Added: trunk/netsurf/atari/osspec.h
URL: http://source.netsurf-browser.org/trunk/netsurf/atari/osspec.h?rev=11550&...
==============================================================================
--- trunk/netsurf/atari/osspec.h (added)
+++ trunk/netsurf/atari/osspec.h Sun Jan 30 16:24:07 2011
@@ -1,0 +1,41 @@
+/*
+ * Copyright 2011 Ole Loots <ole(a)monochrom.net>
+ *
+ * This file is part of NetSurf, http://www.netsurf-browser.org/
+ *
+ * NetSurf is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; version 2 of the License.
+ *
+ * NetSurf is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program. If not, see <http://www.gnu.org/licenses/>.
+ */
+
+#ifndef NS_ATARI_OSSPEC_H
+#define NS_ATARI_OSSPEC_H
+
+typedef struct {
+ long c;
+ long v;
+} COOKIE;
+
+typedef struct {
+ unsigned short gdosversion;
+ unsigned short small_sfont_pxh;
+ unsigned short medium_sfont_pxh;
+ unsigned short large_sfont_pxh;
+ bool sfont_monospaced;
+} NS_ATARI_SYSINFO;
+
+extern NS_ATARI_SYSINFO atari_sysinfo;
+
+#define TOS4VER 0x03000 /* this is assumed to be the last single tasking OS */
+
+void init_os_info(void);
+int tos_getcookie( long tag, long * value );
+#endif
12 years, 3 months
r11549 mono - in /trunk/netsurf/atari: misc.c misc.h
by netsurf@semichrome.net
Author: mono
Date: Sun Jan 30 16:23:00 2011
New Revision: 11549
URL: http://source.netsurf-browser.org?rev=11549&view=rev
Log:
Cleanup of TOS compatibility fixes.
Modified:
trunk/netsurf/atari/misc.c
trunk/netsurf/atari/misc.h
Modified: trunk/netsurf/atari/misc.c
URL: http://source.netsurf-browser.org/trunk/netsurf/atari/misc.c?rev=11549&r1...
==============================================================================
--- trunk/netsurf/atari/misc.c (original)
+++ trunk/netsurf/atari/misc.c Sun Jan 30 16:23:00 2011
@@ -36,35 +36,6 @@
#include "atari/misc.h"
extern void * h_gem_rsrc;
-unsigned short gdosversion;
-
-void init_os_info(void)
-{
- gdosversion = Sversion();
-}
-
-int tos_getcookie(long tag, long * value)
-{
- COOKIE * cptr;
- long oldsp;
-
- if( gdosversion > TOS4VER ){
- return( Getcookie(tag, value) );
- }
-
- cptr = (COOKIE*)Setexc(0x0168, -1L);
- if(cptr != NULL) {
- do {
- if( cptr->c == tag ){
- if(cptr->v != NULL ){
- *value = cptr->v;
- return( C_FOUND );
- }
- }
- } while( (cptr++)->c != 0L );
- }
- return( C_NOTFOUND );
-}
void warn_user(const char *warning, const char *detail)
{
Modified: trunk/netsurf/atari/misc.h
URL: http://source.netsurf-browser.org/trunk/netsurf/atari/misc.h?rev=11549&r1...
==============================================================================
--- trunk/netsurf/atari/misc.h (original)
+++ trunk/netsurf/atari/misc.h Sun Jan 30 16:23:00 2011
@@ -19,13 +19,6 @@
#ifndef NS_ATARI_MISC_H
#define NS_ATARI_MISC_H
-typedef struct {
- long c;
- long v;
-} COOKIE;
-
-#define TOS4VER 0x03000 /* this is assumed to be the last single tasking OS */
-
#define SBUF8_TO_LBUF8(sbuf,lbuf)\
lbuf[0] = (long)sbuf[0];\
lbuf[1] = (long)sbuf[1];\
@@ -43,6 +36,4 @@
char *get_rsc_string( int idx );
void gem_set_cursor( MFORM_EX * cursor );
void dbg_grect( char * str, GRECT * r );
-void init_os_info(void);
-int tos_getcookie( long tag, long * value );
#endif
12 years, 3 months
r11547 mono - /trunk/netsurf/atari/global_evnt.c
by netsurf@semichrome.net
Author: mono
Date: Sun Jan 30 16:19:46 2011
New Revision: 11547
URL: http://source.netsurf-browser.org?rev=11547&view=rev
Log:
Implemented Search Dialog
Modified:
trunk/netsurf/atari/global_evnt.c
Modified: trunk/netsurf/atari/global_evnt.c
URL: http://source.netsurf-browser.org/trunk/netsurf/atari/global_evnt.c?rev=1...
==============================================================================
--- trunk/netsurf/atari/global_evnt.c (original)
+++ trunk/netsurf/atari/global_evnt.c Sun Jan 30 16:19:46 2011
@@ -43,6 +43,7 @@
#include "atari/global_evnt.h"
#include "atari/browser_win.h"
#include "atari/res/netsurf.rsh"
+#include "atari/search.h"
extern const char * cfg_homepage_url;
extern struct gui_window *input_window;
@@ -140,6 +141,8 @@
static void __CDECL menu_find(WINDOW *win, int item, int title, void *data)
{
LOG(("%s", __FUNCTION__));
+ if( input_window != NULL )
+ open_browser_search( input_window );
}
static void __CDECL menu_choices(WINDOW *win, int item, int title, void *data)
@@ -765,5 +768,4 @@
gw = gw->next;
}
return;
-}
-
+}
12 years, 3 months
r11546 mono - /trunk/netsurf/atari/font.c
by netsurf@semichrome.net
Author: mono
Date: Sun Jan 30 16:19:28 2011
New Revision: 11546
URL: http://source.netsurf-browser.org?rev=11546&view=rev
Log:
renamed plotter member function pixel_pos to pixel_position.
Modified:
trunk/netsurf/atari/font.c
Modified: trunk/netsurf/atari/font.c
URL: http://source.netsurf-browser.org/trunk/netsurf/atari/font.c?rev=11546&r1...
==============================================================================
--- trunk/netsurf/atari/font.c (original)
+++ trunk/netsurf/atari/font.c Sun Jan 30 16:19:28 2011
@@ -93,7 +93,7 @@
static bool atari_font_position_in_string(const plot_font_style_t * fstyle,const char *string,
size_t length,int x, size_t *char_offset, int *actual_x )
{
- fplotter->pixel_position(fplotter, fstyle, string, length, x, char_offset, actual_x );
+ fplotter->pixel_pos(fplotter, fstyle, string, length, x, char_offset, actual_x );
return( true );
}
12 years, 3 months
r11545 mono - /trunk/netsurf/atari/findfile.c
by netsurf@semichrome.net
Author: mono
Date: Sun Jan 30 16:17:15 2011
New Revision: 11545
URL: http://source.netsurf-browser.org?rev=11545&view=rev
Log:
Cleanup of TOS fixes.
Modified:
trunk/netsurf/atari/findfile.c
Modified: trunk/netsurf/atari/findfile.c
URL: http://source.netsurf-browser.org/trunk/netsurf/atari/findfile.c?rev=1154...
==============================================================================
--- trunk/netsurf/atari/findfile.c (original)
+++ trunk/netsurf/atari/findfile.c Sun Jan 30 16:17:15 2011
@@ -30,8 +30,9 @@
#include "atari/findfile.h"
#include "atari/gui.h"
#include "atari/misc.h"
-
-extern unsigned short gdosversion;
+#include "atari/osspec.h"
+
+
static void fix_path(char * path);
@@ -56,8 +57,7 @@
char *path;
/* return the absolute path including leading / */
- /* TODO: fix path seperator */
- if(gdosversion > TOS4VER ) {
+ if( atari_sysinfo.gdosversion > TOS4VER ) {
path = strdup(url_path + (FILE_SCHEME_PREFIX_LEN - 1));
} else {
/* do not include / within ulr_path */
@@ -68,10 +68,10 @@
if( path[i] == '/' ){
path[i] = 0x5C;
}
- }
+ }
+ LOG(("%s", path));
}
curl_free(url_path);
- LOG(("%s", path));
return path;
}
@@ -110,7 +110,7 @@
if( rpath == NULL ){
return( NULL );
}
- if( gdosversion > TOS4VER ){
+ if( atari_sysinfo.gdosversion > TOS4VER ){
return( realpath(path, rpath) );
}
12 years, 3 months