r10836 tlsa - in /trunk/netsurfweb/about: index.en screenshots/index.en screenshots/wip/amigaos1.jpg screenshots/wip/amigaos2.jpg
by netsurf@semichrome.net
Author: tlsa
Date: Fri Sep 24 05:06:34 2010
New Revision: 10836
URL: http://source.netsurf-browser.org?rev=10836&view=rev
Log:
Update Amiga screenshots and project timeline.
Modified:
trunk/netsurfweb/about/index.en
trunk/netsurfweb/about/screenshots/index.en
trunk/netsurfweb/about/screenshots/wip/amigaos1.jpg
trunk/netsurfweb/about/screenshots/wip/amigaos2.jpg
Modified: trunk/netsurfweb/about/index.en
URL: http://source.netsurf-browser.org/trunk/netsurfweb/about/index.en?rev=108...
==============================================================================
--- trunk/netsurfweb/about/index.en (original)
+++ trunk/netsurfweb/about/index.en Fri Sep 24 05:06:34 2010
@@ -110,11 +110,12 @@
<tr><th>May 2008</th><td>LibCSS CSS parser started</td></tr>
<tr><th>Jun 2008</th><td>BeOS & Haiku port available</td></tr>
<tr><th>Aug 2008</th><td>AmigaOS 4 port available</td></tr>
-<tr><th>Aug 2008</th><td>Hubbub used by NetSurf development builds</td></tr>
+<tr><th>Aug 2008</th><td>Hubbub used in NetSurf builds</td></tr>
<tr><th>Sep 2008</th><td>Framebuffer port available</td></tr>
<tr><th>Apr 2009</th><td>NetSurf 2.0 released</td></tr>
<tr><th>May 2009</th><td>NetSurf 2.1 released</td></tr>
-<tr><th>Jul 2009</th><td>LibCSS used by NetSurf development builds</td></tr>
+<tr><th>Jul 2009</th><td>LibCSS used in NetSurf builds</td></tr>
+<tr><th>Mar 2010</th><td>New cache designed and used in NetSurf</td></tr>
<tr><th>Apr 2010</th><td>NetSurf 2.5 released</td></tr>
<tr><th>Sep 2010</th><td>NetSurf 2.6 released</td></tr>
</table>
Modified: trunk/netsurfweb/about/screenshots/index.en
URL: http://source.netsurf-browser.org/trunk/netsurfweb/about/screenshots/inde...
==============================================================================
--- trunk/netsurfweb/about/screenshots/index.en (original)
+++ trunk/netsurfweb/about/screenshots/index.en Fri Sep 24 05:06:34 2010
@@ -80,7 +80,7 @@
<h2>Work in Progress</h2>
<ul>
-<li>AmigaOS port: [<a href="wip/amigaos1.jpg">screenshot</a>], [<a href="wip/amigaos2.jpg">screenshot</a>]</li>
+<li>AmigaOS port: [<a href="wip/amigaos1.jpg">Browsing with Tabs</a>], [<a href="wip/amigaos2.jpg">Unicode text</a>]</li>
<li>BeOS/Haiku port: [<a href="wip/beos1.png">screenshot</a>]</li>
<li>Framebuffer port: [<a href="wip/fb1.png">screenshot</a>], [<a href="wip/fb2.png">screenshot</a>]</li>
</ul>
Modified: trunk/netsurfweb/about/screenshots/wip/amigaos1.jpg
URL: http://source.netsurf-browser.org/trunk/netsurfweb/about/screenshots/wip/...
==============================================================================
Binary files - no diff available.
Modified: trunk/netsurfweb/about/screenshots/wip/amigaos2.jpg
URL: http://source.netsurf-browser.org/trunk/netsurfweb/about/screenshots/wip/...
==============================================================================
Binary files - no diff available.
12 years, 8 months
r10835 chris_y - in /branches/jmb/treeview-redux/amiga: gui.c gui.h menu.c menu.h sslcert.c theme.c theme.h
by netsurf@semichrome.net
Author: chris_y
Date: Thu Sep 23 17:59:28 2010
New Revision: 10835
URL: http://source.netsurf-browser.org?rev=10835&view=rev
Log:
Fix compilation. Fails to create GUI as the menu code is currently completely
screwed.
Modified:
branches/jmb/treeview-redux/amiga/gui.c
branches/jmb/treeview-redux/amiga/gui.h
branches/jmb/treeview-redux/amiga/menu.c
branches/jmb/treeview-redux/amiga/menu.h
branches/jmb/treeview-redux/amiga/sslcert.c
branches/jmb/treeview-redux/amiga/theme.c
branches/jmb/treeview-redux/amiga/theme.h
Modified: branches/jmb/treeview-redux/amiga/gui.c
URL: http://source.netsurf-browser.org/branches/jmb/treeview-redux/amiga/gui.c...
==============================================================================
--- branches/jmb/treeview-redux/amiga/gui.c (original)
+++ branches/jmb/treeview-redux/amiga/gui.c Thu Sep 23 17:59:28 2010
@@ -2028,6 +2028,10 @@
FreeVec(nsscreentitle);
if(option_context_menu) ami_context_menu_free();
+
+/* fixme: need newmenu struct propd to this function - should this be freed here?
+ ami_free_menulabs(menu);
+*/
ami_mouse_pointers_free();
ami_clipboard_free();
@@ -2351,7 +2355,7 @@
{
ULONG addtabclosegadget = TAG_IGNORE;
- menu = ami_create_menu(bw->browser_window_type, gwin->shared);
+ menu = ami_create_menu(bw->browser_window_type);
NewList(&gwin->shared->tab_list);
gwin->tab_node = AllocClickTabNode(TNA_Text,messages_get("NetSurf"),
@@ -2476,7 +2480,7 @@
IDCMP_GADGETUP | IDCMP_IDCMPUPDATE |
IDCMP_ACTIVEWINDOW | IDCMP_INTUITICKS |
IDCMP_EXTENDEDMOUSE | IDCMP_GADGETDOWN,
- WINDOW_NewMenu,gwin->shared->menu,
+ WINDOW_NewMenu, menu,
WINDOW_VertProp,1,
WINDOW_IDCMPHook,&gwin->shared->scrollerhook,
WINDOW_IDCMPHookBits,IDCMP_IDCMPUPDATE |
@@ -2928,7 +2932,6 @@
DisposeObject(g->shared->objects[OID_MAIN]);
- ami_free_menulabs(g->shared);
free(g->shared->wintitle);
ami_utf8_free(g->shared->status);
FreeVec(g->shared->svbuffer);
Modified: branches/jmb/treeview-redux/amiga/gui.h
URL: http://source.netsurf-browser.org/branches/jmb/treeview-redux/amiga/gui.h...
==============================================================================
--- branches/jmb/treeview-redux/amiga/gui.h (original)
+++ branches/jmb/treeview-redux/amiga/gui.h Thu Sep 23 17:59:28 2010
@@ -96,11 +96,6 @@
ULONG oldv;
bool redraw_scroll;
bool new_content;
- char *menulab[AMI_MENU_AREXX_MAX + 1];
- char menukey[AMI_MENU_AREXX_MAX + 1];
- UBYTE *menutype;
- struct NewMenu *menu;
- ULONG hotlist_items;
char *svbuffer;
char *status;
char *wintitle;
Modified: branches/jmb/treeview-redux/amiga/menu.c
URL: http://source.netsurf-browser.org/branches/jmb/treeview-redux/amiga/menu....
==============================================================================
--- branches/jmb/treeview-redux/amiga/menu.c (original)
+++ branches/jmb/treeview-redux/amiga/menu.c Thu Sep 23 17:59:28 2010
@@ -66,34 +66,33 @@
const char * const verdate;
static struct Hook aslhookfunc;
-ULONG ami_menu_scan(struct tree *tree, bool count, struct gui_window_2 *gwin);
-void ami_menu_scan_2(struct tree *tree, struct node *root, WORD *gen,
- ULONG *item, bool count, struct gui_window_2 *gwin);
-void ami_menu_arexx_scan(struct gui_window_2 *gwin);
+void ami_menu_scan(struct tree *tree,struct NewMenu *menu);
+void ami_menu_scan_2(struct tree *tree,struct node *root,WORD *gen,ULONG *item,struct NewMenu *menu);
+void ami_menu_arexx_scan(struct NewMenu *menu);
static const ULONG ami_asl_mime_hook(struct Hook *mh,struct FileRequester *fr,struct AnchorPathOld *ap);
-void ami_free_menulabs(struct gui_window_2 *gwin)
+void ami_free_menulabs(struct NewMenu *menu)
{
int i;
for(i=0;i<=AMI_MENU_AREXX_MAX;i++)
{
- if(gwin->menulab[i] && (gwin->menulab[i] != NM_BARLABEL))
- ami_utf8_free(gwin->menulab[i]);
-
- gwin->menulab[i] = NULL;
- gwin->menukey[i] = 0;
- }
-
- FreeVec(gwin->menutype);
- FreeVec(gwin->menu);
-
- gwin->menutype = NULL;
- gwin->menu = NULL;
+ if(menulab[i] && (menulab[i] != NM_BARLABEL))
+ ami_utf8_free(menulab[i]);
+
+ menulab[i] = NULL;
+ menukey[i] = 0;
+ }
+
+ FreeVec(menutype);
+ FreeVec(menu);
+
+ menutype = NULL;
+ menu = NULL;
}
-void ami_init_menulabs(struct gui_window_2 *gwin)
+void ami_init_menulabs(void)
{
int i;
@@ -141,54 +140,56 @@
menulab[41] = ami_utf8_easy((char *)messages_get("HotlistShowNS"));
menulab[42] = NM_BARLABEL;
- gwin->menutype = AllocVec(AMI_MENU_AREXX_MAX + 1, MEMF_PRIVATE | MEMF_CLEAR);
+ menutype = AllocVec(AMI_MENU_AREXX_MAX + 1, MEMF_PRIVATE | MEMF_CLEAR);
for(i=0;i <= AMI_MENU_AREXX_MAX;i++)
{
- gwin->menutype[i] = NM_IGNORE;
- gwin->menulab[i] = NULL;
- }
-
- gwin->menutype[AMI_MENU_HOTLIST_MAX + 1] = NM_TITLE;
- gwin->menulab[AMI_MENU_HOTLIST_MAX + 1] = ami_utf8_easy((char *)messages_get("Settings"));
- gwin->menutype[AMI_MENU_HOTLIST_MAX + 2] = NM_ITEM;
- gwin->menulab[AMI_MENU_HOTLIST_MAX + 2] = ami_utf8_easy((char *)messages_get("SettingsEdit"));
- gwin->menutype[AMI_MENU_HOTLIST_MAX + 3] = NM_ITEM;
- gwin->menulab[AMI_MENU_HOTLIST_MAX + 3] = NM_BARLABEL;
- gwin->menutype[AMI_MENU_HOTLIST_MAX + 4] = NM_ITEM;
- gwin->menulab[AMI_MENU_HOTLIST_MAX + 4] = ami_utf8_easy((char *)messages_get("SnapshotWindow"));
- gwin->menutype[AMI_MENU_HOTLIST_MAX + 5] = NM_ITEM;
- gwin->menulab[AMI_MENU_HOTLIST_MAX + 5] = ami_utf8_easy((char *)messages_get("SettingsSave"));
- gwin->menutype[AMI_MENU_HOTLIST_MAX + 6] = NM_TITLE;
- gwin->menulab[AMI_MENU_HOTLIST_MAX + 6] = ami_utf8_easy((char *)messages_get("ARexx"));
- gwin->menutype[AMI_MENU_HOTLIST_MAX + 7] = NM_ITEM;
- gwin->menulab[AMI_MENU_HOTLIST_MAX + 7] = ami_utf8_easy((char *)messages_get("ARexxExecute"));
- gwin->menutype[AMI_MENU_HOTLIST_MAX + 8] = NM_ITEM;
- gwin->menulab[AMI_MENU_HOTLIST_MAX + 8] = NM_BARLABEL;
-
- gwin->menutype[AMI_MENU_AREXX_MAX] = NM_END;
+ menutype[i] = NM_IGNORE;
+ menulab[i] = NULL;
+ }
+
+ menutype[AMI_MENU_HOTLIST_MAX + 1] = NM_TITLE;
+ menulab[AMI_MENU_HOTLIST_MAX + 1] = ami_utf8_easy((char *)messages_get("Settings"));
+ menutype[AMI_MENU_HOTLIST_MAX + 2] = NM_ITEM;
+ menulab[AMI_MENU_HOTLIST_MAX + 2] = ami_utf8_easy((char *)messages_get("SettingsEdit"));
+ menutype[AMI_MENU_HOTLIST_MAX + 3] = NM_ITEM;
+ menulab[AMI_MENU_HOTLIST_MAX + 3] = NM_BARLABEL;
+ menutype[AMI_MENU_HOTLIST_MAX + 4] = NM_ITEM;
+ menulab[AMI_MENU_HOTLIST_MAX + 4] = ami_utf8_easy((char *)messages_get("SnapshotWindow"));
+ menutype[AMI_MENU_HOTLIST_MAX + 5] = NM_ITEM;
+ menulab[AMI_MENU_HOTLIST_MAX + 5] = ami_utf8_easy((char *)messages_get("SettingsSave"));
+ menutype[AMI_MENU_HOTLIST_MAX + 6] = NM_TITLE;
+ menulab[AMI_MENU_HOTLIST_MAX + 6] = ami_utf8_easy((char *)messages_get("ARexx"));
+ menutype[AMI_MENU_HOTLIST_MAX + 7] = NM_ITEM;
+ menulab[AMI_MENU_HOTLIST_MAX + 7] = ami_utf8_easy((char *)messages_get("ARexxExecute"));
+ menutype[AMI_MENU_HOTLIST_MAX + 8] = NM_ITEM;
+ menulab[AMI_MENU_HOTLIST_MAX + 8] = NM_BARLABEL;
+
+ menutype[AMI_MENU_AREXX_MAX] = NM_END;
}
-void ami_menu_refresh(struct gui_window_2 *gwin)
+void ami_menu_refresh(struct gui_window_2 *gwin, struct NewMenu *menu)
{
SetAttrs(gwin->objects[OID_MAIN],
WINDOW_NewMenu, NULL,
TAG_DONE);
- ami_free_menulabs(gwin);
- ami_create_menu(BROWSER_WINDOW_NORMAL, gwin);
+ ami_free_menulabs(menu);
+ ami_create_menu(BROWSER_WINDOW_NORMAL);
SetAttrs(gwin->objects[OID_MAIN],
- WINDOW_NewMenu, gwin->menu,
+ WINDOW_NewMenu, menu,
TAG_DONE);
schedule(6000,(void *)ami_menu_refresh,gwin);
}
-struct NewMenu *ami_create_menu(ULONG type, struct gui_window_2 *gwin)
+struct NewMenu *ami_create_menu(ULONG type)
{
int i;
ULONG menuflags = 0;
+ struct NewMenu *menu;
+/*
STATIC struct NewMenu menu[] = {
{NM_TITLE,0,0,0,0,0,}, // project
{ NM_ITEM,0,"N",0,0,0,}, // new window
@@ -303,9 +304,10 @@
{ NM_IGNORE,0,0,0,0,0,}, // ** arexx entry **
{ NM_END,0,0,0,0,0,},
};
-
- ami_init_menulabs(gwin);
- gwin->menu = AllocVec(sizeof(struct NewMenu) * (AMI_MENU_AREXX_MAX + 1), MEMF_CLEAR);
+*/
+
+ menu = AllocVec(sizeof(struct NewMenu) * (AMI_MENU_AREXX_MAX + 1), MEMF_CLEAR);
+ ami_init_menulabs();
if(type != BROWSER_WINDOW_NORMAL)
{
@@ -314,26 +316,26 @@
for(i=0;i<=AMI_MENU_AREXX_MAX;i++)
{
- gwin->menu[i].nm_Type = gwin->menutype[i];
- gwin->menu[i].nm_Label = gwin->menulab[i];
- if(gwin->menukey[i]) gwin->menu[i].nm_CommKey = &gwin->menukey[i];
- gwin->menu[i].nm_Flags = 0;
- }
-
- gwin->menu[1].nm_Flags = menuflags;
- gwin->menu[2].nm_Flags = menuflags;
- gwin->menu[12].nm_Flags = menuflags;
- gwin->menu[13].nm_Flags = menuflags;
+ menu[i].nm_Type = menutype[i];
+ menu[i].nm_Label = menulab[i];
+ if(menukey[i]) menu[i].nm_CommKey = &menukey[i];
+ menu[i].nm_Flags = 0;
+ }
+
+ menu[1].nm_Flags = menuflags;
+ menu[2].nm_Flags = menuflags;
+ menu[12].nm_Flags = menuflags;
+ menu[13].nm_Flags = menuflags;
#ifndef WITH_PDF_EXPORT
- gwin->menu[9].nm_Flags = NM_ITEMDISABLED;
-#endif
-
- ami_menu_scan(ami_tree_get_tree(hotlist_window), false, gwin);
- ami_menu_arexx_scan(gwin);
+ menu[9].nm_Flags = NM_ITEMDISABLED;
+#endif
if(!menualreadyinit)
{
+ ami_menu_scan(ami_tree_get_tree(hotlist_window),menu);
+ ami_menu_arexx_scan(menu);
+
aslhookfunc.h_Entry = (void *)&ami_asl_mime_hook;
aslhookfunc.h_SubEntry = NULL;
aslhookfunc.h_Data = NULL;
@@ -344,13 +346,13 @@
/* Set up scheduler to refresh the hotlist menu
Disabled as it causes everything to slow down to a halt after
several iterations
- schedule(6000,(void *)ami_menu_refresh,gwin);
+ schedule(6000,(void *)ami_menu_refresh,menu);
*/
- return(gwin->menu);
+ return(menu);
}
-void ami_menu_arexx_scan(struct gui_window_2 *gwin)
+void ami_menu_arexx_scan(struct NewMenu *menu)
{
int item = AMI_MENU_AREXX;
BPTR lock = 0;
@@ -387,18 +389,18 @@
if(EAD_IS_FILE(ead))
{
- gwin->menu[item].nm_Type = NM_ITEM;
+ menu[item].nm_Type = NM_ITEM;
if(ead->ed_Comment[0] != '\0')
{
- gwin->menulab[item] = (char *)strdup(ead->ed_Comment);
+ menulab[item] = (char *)strdup(ead->ed_Comment);
}
else
{
- gwin->menulab[item] = (char *)strdup(ead->ed_Name);
+ menulab[item] = (char *)strdup(ead->ed_Name);
}
- gwin->menu[item].nm_Label = gwin->menulab[item];
- gwin->menu[item].nm_UserData = (char *)strdup(ead->ed_Name);
+ menu[item].nm_Label = menulab[item];
+ menu[item].nm_UserData = (char *)strdup(ead->ed_Name);
item++;
}
@@ -411,15 +413,15 @@
UnLock(lock);
}
- gwin->menu[item].nm_Type = NM_END;
- gwin->menu[item].nm_Label = NULL;
+ menu[item].nm_Type = NM_END;
+ menu[item].nm_Label = NULL;
}
-ULONG ami_menu_scan(struct tree *tree, bool count, struct gui_window_2 *gwin)
+void ami_menu_scan(struct tree *tree,struct NewMenu *menu)
{
struct node *root = tree_node_get_child(tree_get_root(tree));
+ struct node_element *element=NULL;
struct node *node;
- struct node_element *element;
static WORD gen = 0;
static ULONG item;
@@ -432,15 +434,12 @@
if(element && (strcmp(tree_node_element_get_text(element),"Menu")==0))
{
// found menu
- ami_menu_scan_2(tree,tree_node_get_child(node),&gen,&item,count,gwin);
+ ami_menu_scan_2(tree,tree_node_get_child(node),&gen,&item,menu);
}
}
-
- return(item - AMI_MENU_HOTLIST);
}
-void ami_menu_scan_2(struct tree *tree,struct node *root,WORD *gen,
- ULONG *item, bool count, struct gui_window_2 *gwin)
+void ami_menu_scan_2(struct tree *tree,struct node *root,WORD *gen,ULONG *item,struct NewMenu *menu)
{
struct node *tempnode;
struct node_element *element=NULL;
@@ -452,35 +451,32 @@
{
if((*gen > 0) && (*gen < 3))
{
-// if(*item >= AMI_MENU_HOTLIST_MAX) return;
-
- if(!count)
+ if(*item >= AMI_MENU_HOTLIST_MAX) return;
+
+ if(*gen == 1) menu[*item].nm_Type = NM_ITEM;
+ if(*gen == 2) menu[*item].nm_Type = NM_SUB;
+
+ if(strcmp(tree_url_node_get_title(node),"--"))
{
- if(*gen == 1) gwin->menu[*item].nm_Type = NM_ITEM;
- if(*gen == 2) gwin->menu[*item].nm_Type = NM_SUB;
-
- if(strcmp(tree_url_node_get_title(node),"--"))
- {
- gwin->menulab[*item] = ami_utf8_easy((char *)tree_url_node_get_title(node));
- }
- else
- {
- gwin->menulab[*item] = NM_BARLABEL;
- }
-
- gwin->menu[*item].nm_Label = gwin->menulab[*item];
-
- gwin->menu[*item].nm_UserData = (void *)tree_url_node_get_url(node);
- if(tree_node_is_folder(node) && (!tree_node_get_child(node)))
- gwin->menu[*item].nm_Flags = NM_ITEMDISABLED;
+ menulab[*item] = ami_utf8_easy((char *)tree_url_node_get_title(node));
}
+ else
+ {
+ menulab[*item] = NM_BARLABEL;
+ }
+
+ menu[*item].nm_Label = menulab[*item];
+
+ menu[*item].nm_UserData = (void *)tree_url_node_get_url(node);
+ if(tree_node_is_folder(node) && (!tree_node_get_child(node)))
+ menu[*item].nm_Flags = NM_ITEMDISABLED;
*item = *item + 1;
}
if (tree_node_get_child(node))
{
- ami_menu_scan_2(tree,tree_node_get_child(node),gen,item,count,gwin);
+ ami_menu_scan_2(tree,tree_node_get_child(node),gen,item,menu);
}
}
@@ -805,11 +801,11 @@
if (bw == NULL ||
bw->current_content
== NULL ||
- bw->current_content->url
+ content_get_url(bw->current_content)
== NULL)
break;
- hotlist_add_page(gwin->bw->
- current_content->url);
+ hotlist_add_page(content_get_url(gwin->bw->
+ current_content));
break;
case 1: // show
Modified: branches/jmb/treeview-redux/amiga/menu.h
URL: http://source.netsurf-browser.org/branches/jmb/treeview-redux/amiga/menu....
==============================================================================
--- branches/jmb/treeview-redux/amiga/menu.h (original)
+++ branches/jmb/treeview-redux/amiga/menu.h Thu Sep 23 17:59:28 2010
@@ -18,8 +18,10 @@
#ifndef AMIGA_MENU_H
#define AMIGA_MENU_H
+#include "amiga/gui.h"
#include <exec/types.h>
#include <intuition/intuition.h>
+#include <libraries/gadtools.h>
/* Number of hotlist items, menu structure needs to be changed in ami_create_menu()
* if this value is changed. */
@@ -63,9 +65,13 @@
struct gui_window_2;
-void ami_free_menulabs(struct gui_window_2 *gwin);
-struct NewMenu *ami_create_menu(ULONG type, struct gui_window_2 *gwin);
-void ami_menu_refresh(struct gui_window_2 *gwin);
+char *menulab[AMI_MENU_AREXX_MAX+1];
+UBYTE *menutype;
+char menukey[AMI_MENU_AREXX_MAX+1];
+
+void ami_free_menulabs(struct NewMenu *menu);
+struct NewMenu *ami_create_menu(ULONG type);
+void ami_menu_refresh(struct gui_window_2 *gwin, struct NewMenu *menu);
void ami_menupick(ULONG code,struct gui_window_2 *gwin,struct MenuItem *item);
void ami_menu_update_disabled(struct gui_window *g, hlcache_handle *c);
#endif
Modified: branches/jmb/treeview-redux/amiga/sslcert.c
URL: http://source.netsurf-browser.org/branches/jmb/treeview-redux/amiga/sslce...
==============================================================================
--- branches/jmb/treeview-redux/amiga/sslcert.c (original)
+++ branches/jmb/treeview-redux/amiga/sslcert.c Thu Sep 23 17:59:28 2010
@@ -27,8 +27,7 @@
struct sslcert_session_data *data;
struct treeview_window *ssl_window;
- data = sslcert_create_session_data(num, bw, content_get_url(c),
- cb. cbpw);
+ data = sslcert_create_session_data(num, url, cb, cbpw);
ssl_window = ami_tree_create(sslcert_get_tree_flags(), data);
if(!ssl_window) return;
Modified: branches/jmb/treeview-redux/amiga/theme.c
URL: http://source.netsurf-browser.org/branches/jmb/treeview-redux/amiga/theme...
==============================================================================
--- branches/jmb/treeview-redux/amiga/theme.c (original)
+++ branches/jmb/treeview-redux/amiga/theme.c Thu Sep 23 17:59:28 2010
@@ -121,7 +121,7 @@
char throbberfile[1024];
Object *dto;
- ami_get_theme_filename(throbberfile,"theme_throbber");
+ ami_get_theme_filename(throbberfile,"theme_throbber",false);
throbber_frames=atoi(messages_get("theme_throbber_frames"));
throbber_update_interval = atoi(messages_get("theme_throbber_delay"));
if(throbber_update_interval == 0) throbber_update_interval = 100;
@@ -170,15 +170,20 @@
p96FreeBitMap(throbber);
}
-void ami_get_theme_filename(char *filename, char *themestring)
-{
+void ami_get_theme_filename(char *filename, char *themestring, bool protocol)
+{
+ if(protocol)
+ strcpy(filename,"file:///");
+ else
+ strcpy(filename,"");
+
if(messages_get(themestring)[0] == '*')
{
- strncpy(filename, messages_get(themestring) + 1, 100);
+ strncat(filename,messages_get(themestring)+1,100);
}
else
{
- strcpy(filename, option_theme);
+ strcat(filename, option_theme);
AddPart(filename, messages_get(themestring), 100);
}
}
@@ -273,7 +278,7 @@
if(option_truecolour_mouse_pointers)
{
- ami_get_theme_filename(&ptrfname,ptrs32[i]);
+ ami_get_theme_filename(&ptrfname,ptrs32[i], false);
if(dobj = GetIconTags(ptrfname,ICONGETA_UseFriendBitMap,TRUE,TAG_DONE))
{
if(IconControl(dobj, ICONCTRLA_GetImageDataFormat, &format, TAG_DONE))
@@ -325,7 +330,7 @@
if(!mouseptrobj[i])
{
- ami_get_theme_filename(ptrfname,ptrs[i]);
+ ami_get_theme_filename(ptrfname,ptrs[i], false);
if(ptrfile = Open(ptrfname,MODE_OLDFILE))
{
int mx,my;
Modified: branches/jmb/treeview-redux/amiga/theme.h
URL: http://source.netsurf-browser.org/branches/jmb/treeview-redux/amiga/theme...
==============================================================================
--- branches/jmb/treeview-redux/amiga/theme.h (original)
+++ branches/jmb/treeview-redux/amiga/theme.h Thu Sep 23 17:59:28 2010
@@ -27,7 +27,7 @@
ULONG throbber_width, throbber_height;
void ami_theme_init(void);
-void ami_get_theme_filename(char *filename, char *themestring);
+void ami_get_theme_filename(char *filename, char *themestring, bool protocol);
void ami_theme_throbber_setup(void);
void ami_theme_throbber_free(void);
12 years, 8 months
r10834 jmb - /branches/jmb/treeview-redux/gtk/res/history.glade
by netsurf@semichrome.net
Author: jmb
Date: Thu Sep 23 15:57:17 2010
New Revision: 10834
URL: http://source.netsurf-browser.org?rev=10834&view=rev
Log:
Squash warnings from GTK
Modified:
branches/jmb/treeview-redux/gtk/res/history.glade
Modified: branches/jmb/treeview-redux/gtk/res/history.glade
URL: http://source.netsurf-browser.org/branches/jmb/treeview-redux/gtk/res/his...
==============================================================================
--- branches/jmb/treeview-redux/gtk/res/history.glade (original)
+++ branches/jmb/treeview-redux/gtk/res/history.glade Thu Sep 23 15:57:17 2010
@@ -181,7 +181,6 @@
<widget class="GtkViewport" id="globalHistoryViewport">
<property name="visible">True</property>
<property name="resize_mode">GTK_RESIZE_QUEUE</property>
- <property name="row_spacing">5</property>
<child>
<widget class="GtkDrawingArea" id="globalHistoryDrawingArea">
<property name="visible">True</property>
@@ -191,14 +190,8 @@
</widget>
</child>
</widget>
- <packing>
- <property name="position">0</property>
- </packing>
</child>
</widget>
- <packing>
- <property name="position">1</property>
- </packing>
</child>
</widget>
</child>
12 years, 8 months
r10832 tlsa - /branches/jmb/treeview-redux/beos/beos_bitmap.cpp
by netsurf@semichrome.net
Author: tlsa
Date: Thu Sep 23 13:22:13 2010
New Revision: 10832
URL: http://source.netsurf-browser.org?rev=10832&view=rev
Log:
Implement bitmap_get_{width|height}() functions.
Modified:
branches/jmb/treeview-redux/beos/beos_bitmap.cpp
Modified: branches/jmb/treeview-redux/beos/beos_bitmap.cpp
URL: http://source.netsurf-browser.org/branches/jmb/treeview-redux/beos/beos_b...
==============================================================================
--- branches/jmb/treeview-redux/beos/beos_bitmap.cpp (original)
+++ branches/jmb/treeview-redux/beos/beos_bitmap.cpp Thu Sep 23 13:22:13 2010
@@ -312,6 +312,16 @@
struct bitmap *bitmap = (struct bitmap *)vbitmap;
}
+int bitmap_get_width(void *vbitmap){
+ struct bitmap *bitmap = (struct bitmap *)vbitmap;
+ return bitmap->primary->Bounds().Width() + 1;
+}
+
+int bitmap_get_height(void *vbitmap){
+ struct bitmap *bitmap = (struct bitmap *)vbitmap;
+ return bitmap->primary->Bounds().Height() + 1;
+}
+
static BBitmap *
nsbeos_bitmap_generate_pretile(BBitmap *primary, int repeat_x, int repeat_y)
{
12 years, 8 months
r10831 tlsa - /branches/jmb/treeview-redux/desktop/tree.c
by netsurf@semichrome.net
Author: tlsa
Date: Thu Sep 23 12:41:35 2010
New Revision: 10831
URL: http://source.netsurf-browser.org?rev=10831&view=rev
Log:
C89 for BeOS build.
Modified:
branches/jmb/treeview-redux/desktop/tree.c
Modified: branches/jmb/treeview-redux/desktop/tree.c
URL: http://source.netsurf-browser.org/branches/jmb/treeview-redux/desktop/tre...
==============================================================================
--- branches/jmb/treeview-redux/desktop/tree.c (original)
+++ branches/jmb/treeview-redux/desktop/tree.c Thu Sep 23 12:41:35 2010
@@ -448,9 +448,9 @@
*/
void tree_delink_node(struct tree *tree, struct node *node)
{
+ struct node *parent;
+
assert(node != NULL);
-
- struct node *parent;
/* do not remove the root */
if (tree != NULL && node == tree->root)
@@ -643,11 +643,6 @@
void tree_set_node_expanded(struct tree *tree, struct node *node, bool expanded,
bool folder, bool leaf)
{
- int width, height;
-
- width = tree->width;
- height = tree->height;
-
bool change = tree_set_node_expanded_internal(tree, node, expanded,
folder, leaf);
12 years, 8 months
r10829 tlsa - in /branches/jmb/treeview-redux: Makefile.sources beos/beos_gui.cpp beos/beos_history.cpp beos/beos_history.h beos/beos_scaffolding.cpp beos/beos_treeview.cpp
by netsurf@semichrome.net
Author: tlsa
Date: Thu Sep 23 11:57:42 2010
New Revision: 10829
URL: http://source.netsurf-browser.org?rev=10829&view=rev
Log:
Replace stubs for old treeviews with minimum needed to build with new treeview code. (BeOS.)
Removed:
branches/jmb/treeview-redux/beos/beos_history.cpp
branches/jmb/treeview-redux/beos/beos_history.h
Modified:
branches/jmb/treeview-redux/Makefile.sources
branches/jmb/treeview-redux/beos/beos_gui.cpp
branches/jmb/treeview-redux/beos/beos_scaffolding.cpp
branches/jmb/treeview-redux/beos/beos_treeview.cpp
Modified: branches/jmb/treeview-redux/Makefile.sources
URL: http://source.netsurf-browser.org/branches/jmb/treeview-redux/Makefile.so...
==============================================================================
--- branches/jmb/treeview-redux/Makefile.sources (original)
+++ branches/jmb/treeview-redux/Makefile.sources Thu Sep 23 11:57:42 2010
@@ -76,9 +76,8 @@
# S_BEOS are sources purely for the BeOS build
S_BEOS := beos_about.cpp beos_bitmap.cpp beos_fetch_rsrc.cpp \
- beos_filetype.cpp beos_font.cpp beos_gui.cpp beos_history.cpp \
- beos_login.cpp beos_options.cpp beos_plotters.cpp \
- beos_save_complete.cpp \
+ beos_filetype.cpp beos_font.cpp beos_gui.cpp beos_login.cpp \
+ beos_options.cpp beos_plotters.cpp beos_save_complete.cpp \
beos_scaffolding.cpp beos_search.cpp beos_schedule.cpp \
beos_thumbnail.cpp beos_treeview.cpp beos_throbber.cpp \
beos_window.cpp
Modified: branches/jmb/treeview-redux/beos/beos_gui.cpp
URL: http://source.netsurf-browser.org/branches/jmb/treeview-redux/beos/beos_g...
==============================================================================
--- branches/jmb/treeview-redux/beos/beos_gui.cpp (original)
+++ branches/jmb/treeview-redux/beos/beos_gui.cpp Thu Sep 23 11:57:42 2010
@@ -74,7 +74,6 @@
#include "beos/beos_window.h"
#include "beos/options.h"
#include "beos/beos_throbber.h"
-#include "beos/beos_history.h"
#include "beos/beos_filetype.h"
//#include "beos/beos_download.h"
#include "beos/beos_schedule.h"
@@ -641,7 +640,6 @@
urldb_load(option_url_file);
urldb_load_cookies(option_cookie_file);
- nsbeos_history_init();
//nsbeos_download_initialise();
if (!replicated)
@@ -1059,11 +1057,6 @@
exit(EXIT_FAILURE);
}
-
-void hotlist_visited(hlcache_handle *content)
-{
-}
-
void gui_cert_verify(const char *url, const struct ssl_cert_info *certs,
unsigned long num, nserror (*cb)(bool proceed, void *pw),
void *cbpw)
Removed: branches/jmb/treeview-redux/beos/beos_history.cpp
URL: http://source.netsurf-browser.org/branches/jmb/treeview-redux/beos/beos_h...
==============================================================================
--- branches/jmb/treeview-redux/beos/beos_history.cpp (original)
+++ branches/jmb/treeview-redux/beos/beos_history.cpp (removed)
@@ -1,183 +1,0 @@
-/*
- * Copyright 2008 François Revol <mmu_man(a)users.sourceforge.net>
- * Copyright 2006 Rob Kendrick <rjek(a)rjek.com>
- *
- * 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/>.
- */
-
-#define __STDBOOL_H__ 1
-extern "C" {
-#include "utils/log.h"
-#include "content/urldb.h"
-}
-
-#include "beos/beos_history.h"
-#include "beos/beos_gui.h"
-#include "beos/beos_window.h"
-
-#include <View.h>
-#include <Window.h>
-
-
-enum
-{
- COL_TITLE = 0,
- COL_ADDRESS,
- COL_LASTVISIT,
- COL_TOTALVISITS,
- COL_THUMBNAIL,
- COL_NCOLS
-};
-
-BWindow *wndHistory;
-#warning XXX
-#if 0 /* GTK */
-static GtkTreeView *treeview;
-static GtkTreeStore *history_tree;
-static GtkTreeSelection *selection;
-
-static bool nsgtk_history_add_internal(const char *, const struct url_data *);
-static void nsgtk_history_selection_changed(GtkTreeSelection *, gpointer);
-#endif
-
-void nsbeos_history_init(void)
-{
-#warning XXX
-#if 0 /* GTK */
- GtkCellRenderer *renderer;
-
- wndHistory = GTK_WINDOW(glade_xml_get_widget(gladeWindows,
- "wndHistory"));
- treeview = GTK_TREE_VIEW(glade_xml_get_widget(gladeWindows,
- "treeHistory"));
- history_tree = gtk_tree_store_new(COL_NCOLS,
- G_TYPE_STRING, /* title */
- G_TYPE_STRING, /* address */
- G_TYPE_STRING, /* last visit */
- G_TYPE_INT, /* nr. visits */
- GDK_TYPE_PIXBUF); /* thumbnail */
-
- selection = gtk_tree_view_get_selection(treeview);
- gtk_tree_selection_set_mode(selection, GTK_SELECTION_SINGLE);
- g_signal_connect(G_OBJECT(selection), "changed",
- G_CALLBACK(nsgtk_history_selection_changed), NULL);
-
- renderer = gtk_cell_renderer_text_new();
- gtk_tree_view_insert_column_with_attributes(treeview, -1, "Title",
- renderer,
- "text",
- COL_TITLE,
- NULL);
-
- gtk_tree_view_set_model(treeview, GTK_TREE_MODEL(history_tree));
-
-#endif
- nsbeos_history_update();
-}
-
-void nsbeos_history_update(void)
-{
-#warning XXX
-#if 0 /* GTK */
- gtk_tree_store_clear(history_tree);
- urldb_iterate_entries(nsgtk_history_add_internal);
-#endif
-}
-
-bool nsbeos_history_add_internal(const char *url, const struct url_data *data)
-{
-#warning XXX
-#if 0 /* GTK */
- GtkTreeIter iter;
-
- if (data->visits > 0)
- {
- gtk_tree_store_append(history_tree, &iter, NULL);
- gtk_tree_store_set(history_tree, &iter,
- COL_TITLE, data->title,
- COL_ADDRESS, url,
- COL_LASTVISIT, "Unknown",
- COL_TOTALVISITS, data->visits,
- -1);
- }
-
-#endif
- return true;
-}
-
-#warning XXX
-#if 0 /* GTK */
-void nsgtk_history_selection_changed(GtkTreeSelection *treesel, gpointer g)
-{
- GtkTreeIter iter;
- GtkTreeModel *model = GTK_TREE_MODEL(history_tree);
- if (gtk_tree_selection_get_selected(treesel, &model, &iter))
- {
- gchar *b;
- gint i;
- char buf[20];
-
- gtk_tree_model_get(model, &iter, COL_ADDRESS, &b, -1);
- gtk_label_set_text(GTK_LABEL(glade_xml_get_widget(gladeWindows,
- "labelHistoryAddress")), b);
-
- gtk_tree_model_get(model, &iter, COL_LASTVISIT, &b, -1);
- gtk_label_set_text(GTK_LABEL(glade_xml_get_widget(gladeWindows,
- "labelHistoryLastVisit")), b);
-
- gtk_tree_model_get(model, &iter, COL_TOTALVISITS,
- &i, -1);
- snprintf(buf, 20, "%d", i);
- gtk_label_set_text(GTK_LABEL(glade_xml_get_widget(gladeWindows,
- "labelHistoryVisits")), buf);
-
-
-
- }
- else
- {
-
- }
-}
-
-void nsgtk_history_row_activated(GtkTreeView *tv, GtkTreePath *path,
- GtkTreeViewColumn *column, gpointer g)
-{
- GtkTreeModel *model;
- GtkTreeIter iter;
-
- model = gtk_tree_view_get_model(tv);
- if (gtk_tree_model_get_iter(model, &iter, path))
- {
- gchar *b;
-
- gtk_tree_model_get(model, &iter, COL_ADDRESS, &b, -1);
-
- browser_window_create((const char *)b, NULL, NULL, true);
- }
-}
-#endif
-
-void global_history_add(const char *url)
-{
- const struct url_data *data;
-
- data = urldb_get_url_data(url);
- if (!data)
- return;
-
- nsbeos_history_add_internal(url, data);
-
-}
Removed: branches/jmb/treeview-redux/beos/beos_history.h
URL: http://source.netsurf-browser.org/branches/jmb/treeview-redux/beos/beos_h...
==============================================================================
--- branches/jmb/treeview-redux/beos/beos_history.h (original)
+++ branches/jmb/treeview-redux/beos/beos_history.h (removed)
@@ -1,36 +1,0 @@
-/*
- * Copyright 2008 François Revol <mmu_man(a)users.sourceforge.net>
- * Copyright 2006 Rob Kendrick <rjek(a)rjek.com>
- *
- * 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 __NSBEOS_HISTORY_H__
-#define __NSBEOS_HISTORY_H__
-
-#include <View.h>
-#include <Window.h>
-
-extern BWindow *wndHistory;
-
-void nsbeos_history_init(void);
-void nsbeos_history_update(void);
-#warning XXX
-#if 0 /* GTK */
-void nsbeos_history_row_activated(GtkTreeView *, GtkTreePath *,
- GtkTreeViewColumn *, gpointer);
-#endif
-
-#endif /* __NSGTK_HISTORY_H__ */
Modified: branches/jmb/treeview-redux/beos/beos_scaffolding.cpp
URL: http://source.netsurf-browser.org/branches/jmb/treeview-redux/beos/beos_s...
==============================================================================
--- branches/jmb/treeview-redux/beos/beos_scaffolding.cpp (original)
+++ branches/jmb/treeview-redux/beos/beos_scaffolding.cpp Thu Sep 23 11:57:42 2010
@@ -63,7 +63,6 @@
#include "beos/beos_options.h"
//#include "beos/beos_completion.h"
#include "beos/beos_throbber.h"
-//#include "beos/beos_history.h"
#include "beos/beos_window.h"
//#include "beos/beos_schedule.h"
//#include "beos/beos_download.h"
Modified: branches/jmb/treeview-redux/beos/beos_treeview.cpp
URL: http://source.netsurf-browser.org/branches/jmb/treeview-redux/beos/beos_t...
==============================================================================
--- branches/jmb/treeview-redux/beos/beos_treeview.cpp (original)
+++ branches/jmb/treeview-redux/beos/beos_treeview.cpp Thu Sep 23 11:57:42 2010
@@ -28,105 +28,56 @@
#include "desktop/tree.h"
}
+const char tree_directory_icon_name[] = "directory.png";
+const char tree_content_icon_name[] = "content.png";
-/**
- * Sets the origin variables to the correct values for a specified tree
- *
- * \param tree the tree to set the origin for
- */
-void tree_initialise_redraw(struct tree *tree) {
-}
+
/**
- * Informs the current window manager that an area requires updating.
+ * Translates a content_type to the name of a respective icon
*
- * \param tree the tree that is requesting a redraw
- * \param x the x co-ordinate of the redraw area
- * \param y the y co-ordinate of the redraw area
- * \param width the width of the redraw area
- * \param height the height of the redraw area
+ * \param content_type content type
+ * \param buffer buffer for the icon name
*/
-void tree_redraw_area(struct tree *tree, int x, int y, int width, int height) {
+void tree_icon_name_from_content_type(char *buffer, content_type type)
+{
+ // TODO: design/acquire icons
+ switch (type) {
+ case CONTENT_HTML:
+ case CONTENT_TEXTPLAIN:
+ case CONTENT_CSS:
+#if defined(WITH_MNG) || defined(WITH_PNG)
+ case CONTENT_PNG:
+#endif
+#ifdef WITH_MNG
+ case CONTENT_JNG:
+ case CONTENT_MNG:
+#endif
+#ifdef WITH_JPEG
+ case CONTENT_JPEG:
+#endif
+#ifdef WITH_GIF
+ case CONTENT_GIF:
+#endif
+#ifdef WITH_BMP
+ case CONTENT_BMP:
+ case CONTENT_ICO:
+#endif
+#ifdef WITH_SPRITE
+ case CONTENT_SPRITE:
+#endif
+#ifdef WITH_DRAW
+ case CONTENT_DRAW:
+#endif
+#ifdef WITH_ARTWORKS
+ case CONTENT_ARTWORKS:
+#endif
+#ifdef WITH_NS_SVG
+ case CONTENT_SVG:
+#endif
+ default:
+ sprintf(buffer, tree_content_icon_name);
+ break;
+ }
}
-
-
-/**
- * Draws a line.
- *
- * \param x the x co-ordinate
- * \param x the y co-ordinate
- * \param x the width of the line
- * \param x the height of the line
- */
-void tree_draw_line(int x, int y, int width, int height) {
-}
-
-
-/**
- * Draws an element, including any expansion icons
- *
- * \param tree the tree to draw an element for
- * \param element the element to draw
- */
-void tree_draw_node_element(struct tree *tree, struct node_element *element) {
-}
-
-
-/**
- * Draws an elements expansion icon
- *
- * \param tree the tree to draw the expansion for
- * \param element the element to draw the expansion for
- */
-void tree_draw_node_expansion(struct tree *tree, struct node *node) {
-}
-
-
-/**
- * Recalculates the dimensions of a node element.
- *
- * \param element the element to recalculate
- */
-void tree_recalculate_node_element(struct node_element *element) {
-}
-
-/**
- * Sets a node element as having a specific sprite.
- *
- * \param node the node to update
- * \param sprite the sprite to use
- * \param selected the expanded sprite name to use
- */
-void tree_set_node_sprite(struct node *node, const char *sprite,
- const char *expanded) {
-
-}
-
-/**
- * Sets a node element as having a folder sprite
- *
- * \param node the node to update
- */
-void tree_set_node_sprite_folder(struct node *node) {
-
-}
-
-/**
- * Updates the node details for a URL node.
- * The internal node dimensions are not updated.
- *
- * \param node the node to update
- */
-void tree_update_URL_node(struct node *node, const char *url,
- const struct url_data *data) {
-}
-
-
-/**
- * Updates the tree owner following a tree resize
- *
- * \param tree the tree to update the owner of
- */
-void tree_resized(struct tree *tree) {
-}
12 years, 8 months
r10828 tlsa - in /branches/jmb/treeview-redux: Makefile.sources windows/history.c windows/hotlist.c windows/tree.c
by netsurf@semichrome.net
Author: tlsa
Date: Thu Sep 23 11:34:37 2010
New Revision: 10828
URL: http://source.netsurf-browser.org?rev=10828&view=rev
Log:
Replace stubs for old treeviews with minimum needed to build with new treeview code.
Removed:
branches/jmb/treeview-redux/windows/history.c
branches/jmb/treeview-redux/windows/hotlist.c
Modified:
branches/jmb/treeview-redux/Makefile.sources
branches/jmb/treeview-redux/windows/tree.c
Modified: branches/jmb/treeview-redux/Makefile.sources
URL: http://source.netsurf-browser.org/branches/jmb/treeview-redux/Makefile.so...
==============================================================================
--- branches/jmb/treeview-redux/Makefile.sources (original)
+++ branches/jmb/treeview-redux/Makefile.sources Thu Sep 23 11:34:37 2010
@@ -69,9 +69,9 @@
# code in utils/container.ch is non-universal it seems
# S_WINDOWS are sources purely for the windows build
-S_WINDOWS := about.c bitmap.c download.c filetype.c findfile.c font.c \
- gui.c history.c hotlist.c localhistory.c login.c misc.c plot.c \
- prefs.c schedule.c thumbnail.c tree.c
+S_WINDOWS := about.c bitmap.c download.c filetype.c findfile.c font.c \
+ gui.c localhistory.c login.c misc.c plot.c prefs.c schedule.c \
+ thumbnail.c tree.c
S_WINDOWS := $(addprefix windows/,$(S_WINDOWS))
# S_BEOS are sources purely for the BeOS build
Removed: branches/jmb/treeview-redux/windows/history.c
URL: http://source.netsurf-browser.org/branches/jmb/treeview-redux/windows/his...
==============================================================================
--- branches/jmb/treeview-redux/windows/history.c (original)
+++ branches/jmb/treeview-redux/windows/history.c (removed)
@@ -1,41 +1,0 @@
-/*
- * Copyright 2008 Vincent Sanders <vince(a)simtec.co.uk>
- *
- * 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/>.
- */
-
-#include "content/urldb.h"
-#include "desktop/browser.h"
-
-void global_history_add(const char *url)
-{
- const struct url_data *data;
-
- data = urldb_get_url_data(url);
- if (!data)
- return;
-
-
-}
-
-void global_history_add_recent(const char *url)
-{
-}
-
-char **global_history_get_recent(int *count)
-{
- return NULL;
-}
-
Removed: branches/jmb/treeview-redux/windows/hotlist.c
URL: http://source.netsurf-browser.org/branches/jmb/treeview-redux/windows/hot...
==============================================================================
--- branches/jmb/treeview-redux/windows/hotlist.c (original)
+++ branches/jmb/treeview-redux/windows/hotlist.c (removed)
@@ -1,24 +1,0 @@
-/*
- * Copyright 2008 Vincent Sanders <vince(a)simtec.co.uk>
- *
- * 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/>.
- */
-
-#include "desktop/browser.h"
-#include "content/hlcache.h"
-
-void hotlist_visited(hlcache_handle *content)
-{
-}
Modified: branches/jmb/treeview-redux/windows/tree.c
URL: http://source.netsurf-browser.org/branches/jmb/treeview-redux/windows/tre...
==============================================================================
--- branches/jmb/treeview-redux/windows/tree.c (original)
+++ branches/jmb/treeview-redux/windows/tree.c Thu Sep 23 11:34:37 2010
@@ -18,45 +18,56 @@
#include "desktop/tree.h"
-void tree_initialise_redraw(struct tree *tree)
+const char tree_directory_icon_name[] = "directory.png";
+const char tree_content_icon_name[] = "content.png";
+
+
+
+
+/**
+ * Translates a content_type to the name of a respective icon
+ *
+ * \param content_type content type
+ * \param buffer buffer for the icon name
+ */
+void tree_icon_name_from_content_type(char *buffer, content_type type)
{
+ // TODO: design/acquire icons
+ switch (type) {
+ case CONTENT_HTML:
+ case CONTENT_TEXTPLAIN:
+ case CONTENT_CSS:
+#if defined(WITH_MNG) || defined(WITH_PNG)
+ case CONTENT_PNG:
+#endif
+#ifdef WITH_MNG
+ case CONTENT_JNG:
+ case CONTENT_MNG:
+#endif
+#ifdef WITH_JPEG
+ case CONTENT_JPEG:
+#endif
+#ifdef WITH_GIF
+ case CONTENT_GIF:
+#endif
+#ifdef WITH_BMP
+ case CONTENT_BMP:
+ case CONTENT_ICO:
+#endif
+#ifdef WITH_SPRITE
+ case CONTENT_SPRITE:
+#endif
+#ifdef WITH_DRAW
+ case CONTENT_DRAW:
+#endif
+#ifdef WITH_ARTWORKS
+ case CONTENT_ARTWORKS:
+#endif
+#ifdef WITH_NS_SVG
+ case CONTENT_SVG:
+#endif
+ default:
+ sprintf(buffer, tree_content_icon_name);
+ break;
+ }
}
-
-void tree_redraw_area(struct tree *tree, int x, int y, int width, int height)
-{
-}
-
-void tree_draw_line(int x, int y, int width, int height)
-{
-}
-
-void tree_draw_node_element(struct tree *tree, struct node_element *element)
-{
-}
-
-void tree_draw_node_expansion(struct tree *tree, struct node *node)
-{
-}
-
-void tree_recalculate_node_element(struct node_element *element)
-{
-}
-
-void tree_update_URL_node(struct node *node, const char *url,
- const struct url_data *data)
-{
-}
-
-void tree_resized(struct tree *tree)
-{
-}
-
-void tree_set_node_sprite_folder(struct node *node)
-{
-}
-
-void tree_set_node_sprite(struct node *node, const char *sprite,
- const char *expanded)
-{
-}
-
12 years, 8 months
r10827 tlsa - in /branches/jmb/treeview-redux: Makefile.sources framebuffer/history.c framebuffer/hotlist.c framebuffer/tree.c
by netsurf@semichrome.net
Author: tlsa
Date: Thu Sep 23 11:04:01 2010
New Revision: 10827
URL: http://source.netsurf-browser.org?rev=10827&view=rev
Log:
Replace stubs for old treeviews with minimum needed to build with new treeview code.
Removed:
branches/jmb/treeview-redux/framebuffer/history.c
branches/jmb/treeview-redux/framebuffer/hotlist.c
Modified:
branches/jmb/treeview-redux/Makefile.sources
branches/jmb/treeview-redux/framebuffer/tree.c
Modified: branches/jmb/treeview-redux/Makefile.sources
URL: http://source.netsurf-browser.org/branches/jmb/treeview-redux/Makefile.so...
==============================================================================
--- branches/jmb/treeview-redux/Makefile.sources (original)
+++ branches/jmb/treeview-redux/Makefile.sources Thu Sep 23 11:04:01 2010
@@ -103,9 +103,9 @@
# S_FRAMEBUFFER are sources purely for the framebuffer build
-S_FRAMEBUFFER := gui.c framebuffer.c tree.c history.c hotlist.c \
- save.c schedule.c thumbnail.c misc.c bitmap.c filetype.c \
- login.c findfile.c localhistory.c
+S_FRAMEBUFFER := gui.c framebuffer.c tree.c save.c schedule.c \
+ thumbnail.c misc.c bitmap.c filetype.c login.c findfile.c \
+ localhistory.c
S_FRAMEBUFFER_FBTK := fbtk.c event.c fill.c bitmap.c user.c window.c \
text.c scroll.c osk.c
Removed: branches/jmb/treeview-redux/framebuffer/history.c
URL: http://source.netsurf-browser.org/branches/jmb/treeview-redux/framebuffer...
==============================================================================
--- branches/jmb/treeview-redux/framebuffer/history.c (original)
+++ branches/jmb/treeview-redux/framebuffer/history.c (removed)
@@ -1,41 +1,0 @@
-/*
- * Copyright 2008 Vincent Sanders <vince(a)simtec.co.uk>
- *
- * 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/>.
- */
-
-#include "content/urldb.h"
-#include "desktop/browser.h"
-
-void global_history_add(const char *url)
-{
- const struct url_data *data;
-
- data = urldb_get_url_data(url);
- if (!data)
- return;
-
-
-}
-
-void global_history_add_recent(const char *url)
-{
-}
-
-char **global_history_get_recent(int *count)
-{
- return NULL;
-}
-
Removed: branches/jmb/treeview-redux/framebuffer/hotlist.c
URL: http://source.netsurf-browser.org/branches/jmb/treeview-redux/framebuffer...
==============================================================================
--- branches/jmb/treeview-redux/framebuffer/hotlist.c (original)
+++ branches/jmb/treeview-redux/framebuffer/hotlist.c (removed)
@@ -1,23 +1,0 @@
-/*
- * Copyright 2008 Vincent Sanders <vince(a)simtec.co.uk>
- *
- * 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/>.
- */
-
-#include "desktop/browser.h"
-
-void hotlist_visited(struct hlcache_handle *content)
-{
-}
Modified: branches/jmb/treeview-redux/framebuffer/tree.c
URL: http://source.netsurf-browser.org/branches/jmb/treeview-redux/framebuffer...
==============================================================================
--- branches/jmb/treeview-redux/framebuffer/tree.c (original)
+++ branches/jmb/treeview-redux/framebuffer/tree.c Thu Sep 23 11:04:01 2010
@@ -18,45 +18,56 @@
#include "desktop/tree.h"
-void tree_initialise_redraw(struct tree *tree)
+const char tree_directory_icon_name[] = "directory.png";
+const char tree_content_icon_name[] = "content.png";
+
+
+
+
+/**
+ * Translates a content_type to the name of a respective icon
+ *
+ * \param content_type content type
+ * \param buffer buffer for the icon name
+ */
+void tree_icon_name_from_content_type(char *buffer, content_type type)
{
+ // TODO: design/acquire icons
+ switch (type) {
+ case CONTENT_HTML:
+ case CONTENT_TEXTPLAIN:
+ case CONTENT_CSS:
+#if defined(WITH_MNG) || defined(WITH_PNG)
+ case CONTENT_PNG:
+#endif
+#ifdef WITH_MNG
+ case CONTENT_JNG:
+ case CONTENT_MNG:
+#endif
+#ifdef WITH_JPEG
+ case CONTENT_JPEG:
+#endif
+#ifdef WITH_GIF
+ case CONTENT_GIF:
+#endif
+#ifdef WITH_BMP
+ case CONTENT_BMP:
+ case CONTENT_ICO:
+#endif
+#ifdef WITH_SPRITE
+ case CONTENT_SPRITE:
+#endif
+#ifdef WITH_DRAW
+ case CONTENT_DRAW:
+#endif
+#ifdef WITH_ARTWORKS
+ case CONTENT_ARTWORKS:
+#endif
+#ifdef WITH_NS_SVG
+ case CONTENT_SVG:
+#endif
+ default:
+ sprintf(buffer, tree_content_icon_name);
+ break;
+ }
}
-
-void tree_redraw_area(struct tree *tree, int x, int y, int width, int height)
-{
-}
-
-void tree_draw_line(int x, int y, int width, int height)
-{
-}
-
-void tree_draw_node_element(struct tree *tree, struct node_element *element)
-{
-}
-
-void tree_draw_node_expansion(struct tree *tree, struct node *node)
-{
-}
-
-void tree_recalculate_node_element(struct node_element *element)
-{
-}
-
-void tree_update_URL_node(struct node *node, const char *url,
- const struct url_data *data)
-{
-}
-
-void tree_resized(struct tree *tree)
-{
-}
-
-void tree_set_node_sprite_folder(struct node *node)
-{
-}
-
-void tree_set_node_sprite(struct node *node, const char *sprite,
- const char *expanded)
-{
-}
-
12 years, 8 months