From 7d541185d2ed4a5d9e447cf22a7b5cf4504bf077 Mon Sep 17 00:00:00 2001 From: Andrew Hodgkinson <ahodgkin@gitlab.riscosopen.org> Date: Mon, 15 Sep 1997 12:41:33 +0000 Subject: [PATCH] Added 'save current location'. Res files updated appropriately. Version number taken to Beta-3; next will be 1.21, including K.Bracey's i18n code. --- Resources/UK/Browse/Messages | 2 +- Resources/UK/Browse/Res,fae | Bin 34168 -> 34288 bytes Resources/UK/Browse/User/Hotlist,faf | 98 +++++++++++++++++++++++++++ Resources/UK/Phoenix/Messages | 2 +- Resources/UK/Phoenix/Res,fae | Bin 30912 -> 30832 bytes Resources/UK/Ursula/Messages | 2 +- Resources/UK/Ursula/Res,fae | Bin 27864 -> 28000 bytes c/Menus | 8 +++ c/Protocols | 59 +++++++++++----- c/SaveFile | 31 +++++++++ h/Menus | 9 +-- 11 files changed, 187 insertions(+), 24 deletions(-) create mode 100644 Resources/UK/Browse/User/Hotlist,faf diff --git a/Resources/UK/Browse/Messages b/Resources/UK/Browse/Messages index 8eaee36..fe1f491 100644 --- a/Resources/UK/Browse/Messages +++ b/Resources/UK/Browse/Messages @@ -3,7 +3,7 @@ _TaskName:Browse _SpriName:!browse -Version:1.20 (12-Sep-97)ß +Version:1.20 (12-Sep-97) ß-3 # Errors # ====== diff --git a/Resources/UK/Browse/Res,fae b/Resources/UK/Browse/Res,fae index 529fad73c6deb9dc502da6f6e50fe0b9028f8f9d..61e7538c73e3f1ab212d1dc8052e6582258b6bf6 100644 GIT binary patch delta 251 zcmey-#q^<@X+j6z7bXUV2p~Sd#=sE3wsG1k!O03TENpui85kUxCU*%*ahd>SRTvl; zEGDlNl4oR}d{!t#B!q#1g^iIx9VjdY#2{(i$-KhSytY6VI}rZ|0<*~*1%ySJ6c`wo zfNEWUq9C;(74DNKDu}Z(uro45O%5y-p4=lW!k9OCp|JDh1VN$6PlTnJfr=)HsEY<C zmZd5rmlhSJ=9MVq<R>SVWaj5hRul1Hl$-pK@AGCCQ3Ed7IY7k@+8hilKsp781B&v~ fJ@eA?flP)8lPAjOaVR*YmL%#LF>L-XUzrL3uBSVS delta 201 zcmey+&Ge&-X+j6z1x5yjGeA6tm4V?1>&9uX1i2i5+y)^2z&N=}NQ(0bkg3AJz#uSr zt<+vKxCAtEdc49skd4C+8(b|C%_1S*p^3J6aw5a!_31B!?Nu{IE!0!2kQfD8t9 zMh2J33x(AgBPO2|cAhLJBF&gK*+xWta;1nnGXsOv<d1xpH*XO&;F6sJRPCV6!2q;` iAq9v7it^Jv^V0HxOooohj0$;746H!a!kc>(Qc?jy$}iCX diff --git a/Resources/UK/Browse/User/Hotlist,faf b/Resources/UK/Browse/User/Hotlist,faf new file mode 100644 index 0000000..cc11fdc --- /dev/null +++ b/Resources/UK/Browse/User/Hotlist,faf @@ -0,0 +1,98 @@ +<html> +<head><title>Hotlist</title></head> +<body> +<ul> +<li><a href="http://www.acorn.co.uk/">Acorn Home Page</a> +<li><a href="http://www.altavista.digital.com/">Alta Vista search</a> +<li><a href="http://www.unitedmedia.com/comics/dilbert">Dilbert</a> +<h4>Search engines</h4> +<ul> +<li><a href="http://www.dejanews.com/">DejaNews</a> +<li><a href="http://www.webcrawler.com/">WebCrawler Search</a> +<li><a href="http://www.yahoo.com/">Yahoo search</a> +<li><a href="http://www.infoseek.com/">Infoseek search</a> +<li><a href="http://www.excite.com/">Excite</a> +<li><a href="http://www.lycos.com/">Lycos search</a> +<li><a href="http://www.uktravel.com/index.html">UK Travel Guide</a> +<li><a href="http://www.yell.co.uk/">This is YELL</a> +<li><a href="http://www.whowhere.com/">WhoWhere</a> +</ul> +<h4>Acorn related</h4> +<ul> +<li><a href="http://www.xemplar.co.uk/">Xemplar Home Page</a> +<li><a href="http://www.cybervillage.co.uk/acorn/">The Acorn Cybervillage</a> +<li><a href="http://pink.idg.co.uk/acornuser/index.html">Acorn User Online</a> +<h4>FTP archives</h4> +<ul> +<li><a href="http://www.acorn.co.uk/ftp/">Acorn (WWW interface)</a> +<li><a href="ftp://micros.hensa.ac.uk/micros/arch/riscos/">Hensa Acorn archive</a> +<li><a href="ftp://ftp.uni-stuttgart.de/pub/systems/acorn">Stuttgart Acorn archive</a> +</ul> +</ul> +<h4>Information</h4> +<ul> +<h4>News</h4> +<ul> +<li><a href="http://www.the-telegraph.co.uk/">The Telegraph</a> +<li><a href="http://www.the-times.co.uk/">The Times</a> +<li><a href="http://www.guardian.co.uk/">The Guardian</a> +<li><a href="http://cnn.com/">CNN Interactive</a> +</ul> +<h4>Magazines</h4> +<ul> +<li><a href="http://www.newscientist.com/">New Scientist</a> +<li><a href="http://www.hotwired.com/">HotWired</a> +<li><a href="http://www.shiftcontrol.com/">Shift Control</a> +<li><a href="http://inkpot.com/">The Flying Inkpot</a> +<li><a href="http://www.forteantimes.com/">Fortean Times Online</a> +</ul> +<h4>HTML and the Internet</h4> +<ul> +<li><a href="http://www.w3.org/">World Wide Web consortium</a> +<li><a href="http://www.earth.com/bad-style/">HTML Bad Style Page</a> +<li><a href="http://www.nadn.navy.mil/html.html">HTML Resources</a> +<li><a href="http://www.microsoft.com/workshop/design/colors/X11_Hue.HTM">X11 Colour Names: Sorted by hue</a> +<li><a href="http://www.it.kth.se/docs/rfc/">List of RFCs</a> +</ul> +<h4>Miscellaneous</h4> +<ul> +<li><a href="http://www.inetgames.com/~eyezzz/">The Programming WareHouse</a> +<li><a href="http://www.comlab.ox.ac.uk/archive/other/rowing.html">The World Wide Web Virtual Library: Rowing</a> +<li><a href="http://www.aaa.com.au/A_Z/">Australian A to Z Animal Archive</a> +<li><a href="http://www.man.ac.uk/Geology/pwood/esenet/esintro.htm">Internet resources for Earth and Environmental Scientists</a> +</ul> +</ul> +<h4>Fun</h4> +<ul> +<h4>Film and television</h4> +<ul> +<li><a href="http://mrdata.simplenet.com/midi.htm">The Ultimate Theme Song MIDI Page</a> +<li><a href="http://www.like.it/vertigo/cliches.html">The Movie Cliches List</a> +<li><a href="http://www.users.dircon.co.uk/~bandc/a.wiseman/625/index.htm">6025 Television Room</a> +<li><a href="http://www.scifi.com/">Sci-Fi Channel: The Dominion</a> +<li><a href="http://moose.spesh.com/teletubbies/index.html">Time For Teletubbies</a> +<li><a href="http://www.tangh.demon.co.uk/tubbytoast/index.html">Teletubbies come to play!</a> +</ul> +<h4>Miscellaneous</h4> +<ul> +<li><a href="http://www.fibblesnork.com/lego/guide/">Fibblesnork</a> +<li><a href="http://www.planetquake.com/">Planet Quake</a> +<li><a href="http://www.netaxs.com/~cparker/front/hub.html">Charley Parker's virtual comic book - ARGON ZARK!</a> +<li><a href="http://animeonline.org/">AnimeOnline - Everything Anime</a> +<li><a href="http://www.theonion.com/">The ONION - Number One In News</a> +</ul> +</ul> +<h4>Weird</h4> +<ul> +<li><a href="http://www.mds.mdh.se/~elt94aem/kosida.htm">The Cow Liberation Army Faction</a> +<li><a href="http://iguana.images.com/">Iguana Images</a> +<li><a href="http://www.xmission.com/~grue/whale/">The Infamous Exploding Whale</a> +<li><a href="http://www.beyondweird.com/index.html">The OuterNet</a> +<li><a href="http://www.planet.com/dirtweb/dirt.html">Museum of Dirt</a> +<li><a href="http://www.owlnet.rice.edu/~gouge/twinkies.html">The T.W.I.N.K.I.E.S. Project</a> +<li><a href="http://infobahn.com/pages/anagram.html">Main Sanitary Nag (Anagram Insanity)</a> +<li><a href="http://www.conspire.com/">60 Greatest Conspiracies of All Time</a> +</ul> +</ul> +</body> +</html> diff --git a/Resources/UK/Phoenix/Messages b/Resources/UK/Phoenix/Messages index 6edb83f..bc8cbff 100644 --- a/Resources/UK/Phoenix/Messages +++ b/Resources/UK/Phoenix/Messages @@ -3,7 +3,7 @@ _TaskName:Phoenix _SpriName:!phoenix -Version:1.20 (12-Sep-97) ß-2 +Version:1.20 (12-Sep-97) ß-3 # Errors # ====== diff --git a/Resources/UK/Phoenix/Res,fae b/Resources/UK/Phoenix/Res,fae index 28d3ddc8a2ebbcefb70d49afcd7845cec750442f..a13ded77d7c3d43bd952e5007f2535b119ac8778 100644 GIT binary patch delta 197 zcmX@`k@3R^#tjBSoDz%-3^_o2VzQ->G}j&=OND`f;RVCwI3YPk*2%R(AtE6R3@mJn z4C+8}F(3xX>rUP)B+Y9JWU&MBe;_cMoG2h7qQJnw1XSt*6a*;+DR7^BQB-xZfS}6c zDZ<iB`Dv5a3u}l5CzhouB$pNyrRJ3=<m4wOmSpDVO}-{9$DEcXHhCf6_RT*;47eEQ hOxBc_W}GnDRX(57DYYa~*NB0E6(}vd`G)+92mq3DGW-Al delta 276 zcmezHf$_jc#tjBSoDPf(3=Kg1VX~!=G}jX#OND`fL4a{`oRAzN+vHlI5D^vz24*%! z26dn~I}rZ|0+q>$0>Yw93JeTPKp8!ts2C7y1F<PkM#K%sU|?rtZ~;;xKn&6X0w7_a zVPHOl&A`A2R2Ko{fDC}Bf~aF;V4iF*tUI|*SbFkoVU5W*g=KYJN^=VoO7gQ)^NJOc zDiv}v^HLem#EMIbQWJB5W=Tz6$ai`38W9sN#wC*<%1JZMnEY2RU(hk9AR|#BC^aWF Tu{c%1kbxDbOn7sL{EG+xNGDDe diff --git a/Resources/UK/Ursula/Messages b/Resources/UK/Ursula/Messages index 0cc4e4d..e86a1a6 100644 --- a/Resources/UK/Ursula/Messages +++ b/Resources/UK/Ursula/Messages @@ -3,7 +3,7 @@ _TaskName:Browse _SpriName:!browse -Version:1.20 (12-Sep-97)ß +Version:1.20 (12-Sep-97) ß-3 # Errors # ====== diff --git a/Resources/UK/Ursula/Res,fae b/Resources/UK/Ursula/Res,fae index df678469fb7ca3cd646a29a75eef82b8e9762948..104b03ddeb8c306f0f637b6783e1df95e9a639c3 100644 GIT binary patch delta 308 zcmca{lkveV#tj~VoDz%-3^_o2VsfCMG~=Ghg8agh8w5oJSs8#J1c=!f89;2Y$x8*5 z8Kozm6jZPQ3bO!()j`5QtOCTkK+K{5B!J*Q5P%sh3=GUbb+$kbJ5=0k@<M(Q5d{VY zCZL21P!MDQNP+w0kNlpKV}xYl85rC$b5a?C6U$N+(uxvuQx#yq%@`tDkXV$OR{~)t zmllCI3OV`7i6xo&c?_-<1^GoK3;{)%c_n&!dN93UKFGewfzq2dy9hUM%FY3D9ke+Z ofX-w{0pft7{B+N}w0t0wVZ!8xGI<;dPN^k{x<(9}{bf7-0X6DI$p8QV delta 231 zcmaEGi}A)y#tj~VlX6*D4Hy|1GA0KKN^`~lSt<++3<oBc3d#$z09gznK+ML-zzU=U zCNC9KW)z)#QcytzD8~#GRs;&O1Mz<#P?@}tUqnQKfq@Aqp#f44#M(e?I{72N`Q&Lr zGL~+cIjIc6iDjt@X+?>-sR{}TZpILPL1IyAUI~M1ML~X12}3|pW?qS&o}PjNn8hG8 zSx|WT<`cp-oU&7Z20CbSFn}DF0>lAD`RSf{Y571VL&xMq**qo&R-kI(&2MB&`~gQT BHd+7x diff --git a/c/Menus b/c/Menus index f1672dd..86aa5b8 100644 --- a/c/Menus +++ b/c/Menus @@ -213,6 +213,7 @@ int menus_show_utils(int eventcode, ToolboxEvent * event, IdBlock * idb, void *h int menus_show_file(int eventcode, ToolboxEvent * event, IdBlock * idb, void * handle) { browser_data * b; + char * url; #ifdef TRACE if (tl & (1u<<4)) Printf("menus_show_file: Called\n"); @@ -242,6 +243,13 @@ int menus_show_file(int eventcode, ToolboxEvent * event, IdBlock * idb, void * h if (b->nchildren) menu_set_fade(0, idb->self_id, FilePrint, 1); else menu_set_fade(0, idb->self_id, FilePrint, 0); + /* Do we have a current location? */ + + url = browser_current_url(b); + + if (url && *url) menu_set_fade(0, idb->self_id, FileSaveCurrentLocation, 0); + else menu_set_fade(0, idb->self_id, FileSaveCurrentLocation, 1); + #ifdef TRACE if (tl & (1u<<4)) Printf("menus_show_file: Successful\n"); #endif diff --git a/c/Protocols b/c/Protocols index eefa6db..052285a 100644 --- a/c/Protocols +++ b/c/Protocols @@ -555,16 +555,31 @@ _kernel_oserror * protocols_atats_got_ram_fetch(WimpMessage * m) } else if (m->hdr.your_ref == save_link_reference) { - /* Save a link as a URI file */ + if (is_known_browser(save_link_browser)) + { + if (save_link_token) + { + /* Save a link as a URI file */ - if ( - is_known_browser(save_link_browser) && - save_link_token - ) - return save_transfer_uri(save_link_token->anchor, - 0, - &save_link_transmitted, - m); + return save_transfer_uri(save_link_token->anchor, + 0, + &save_link_transmitted, + m); + } + else + { + /* Save the current location as a URI file */ + + char * url = browser_current_url(save_link_browser); + + if (!url) url = " "; + + return save_transfer_uri(url, + 0, + &save_link_transmitted, + m); + } + } } else if (m->hdr.your_ref == save_location_reference) { @@ -797,15 +812,25 @@ static _kernel_oserror * protocols_atats_got_data_save_ack(WimpMessage * m) } else if (m->hdr.your_ref == save_link_reference) { - /* Save a link as a URI file */ - - if ( - is_known_browser(save_link_browser) && - save_link_token - ) + if (is_known_browser(save_link_browser)) { - e = save_save_uri(path, save_link_token->anchor, 0); - if (!e) ok = 1; + if (save_link_token) + { + /* Save a link as a URI file */ + + e = save_save_uri(path, save_link_token->anchor, 0); + if (!e) ok = 1; + } + else + { + /* Save the current location as a URI file */ + + char * url = browser_current_url(save_link_browser); + + if (!url) url = " "; + + return save_save_uri(path, url, 0); + } } } else if (m->hdr.your_ref == save_location_reference) diff --git a/c/SaveFile b/c/SaveFile index be186d2..59ccb02 100644 --- a/c/SaveFile +++ b/c/SaveFile @@ -295,6 +295,24 @@ int savefile_to_be_shown(int eventcode, ToolboxEvent * event, IdBlock * idb, voi } break; + /* Save the current location as a URI file */ + + case FileSaveCurrentLocation: + { + char * url = browser_current_url(b); + + if (!url) url = " "; + + ChkError(savefile_set_leafname_from_url(idb->self_id, SaveFileWrit, url)); + ChkError(savefile_set_filetype(idb->self_id, SaveFileDrag, FileType_URI)); + + savefile_browser = b; + savefile_token = NULL; + + ok = 1; + } + break; + /* Export the link the pointer was over when the menu opened */ case ExportLink: @@ -642,6 +660,19 @@ static int savefile_drag_ended(int eventcode, ToolboxEvent * event, IdBlock * id } break; + /* Size of a URI file for the current location */ + + case FileSaveCurrentLocation: + { + char * url = browser_current_url(savefile_browser); + + if (!url) url = " "; + + saving = protocols_saving_link; + size = save_uri_size(url, 0); + } + break; + /* Size of a URI file */ case ExportLink: diff --git a/h/Menus b/h/Menus index 6690727..93607ae 100644 --- a/h/Menus +++ b/h/Menus @@ -65,10 +65,11 @@ /* File menu component IDs */ -#define FileSaveFrame 0x10600 /* Leading to Save dialogue for saving frame source */ -#define FileSaveParent 0x10601 /* Leading to Save dialogue for saving parent source */ -#define FilePrint 0x10602 /* Item leading to the Print dialogue */ -#define FileExport 0x10603 /* Item leading to the Export submenu */ +#define FileSaveFrame 0x10600 /* Leading to Save dialogue for saving frame source */ +#define FileSaveParent 0x10601 /* Leading to Save dialogue for saving parent source */ +#define FilePrint 0x10602 /* Item leading to the Print dialogue */ +#define FileExport 0x10603 /* Item leading to the Export submenu */ +#define FileSaveCurrentLocation 0x10604 /* Leading to Save dialogue for saving current location */ /* File menu event codes */ -- GitLab