From ce623ccaecf14dc68c5ee3d83d6aa8045b7d3702 Mon Sep 17 00:00:00 2001 From: "Kirill Lipatov (Leency)" Date: Fri, 24 Feb 2012 21:27:05 +0000 Subject: [PATCH] HTMLv 0.72: fully worked Internet pages, as in older versions. Tested, some fixes. git-svn-id: svn://kolibrios.org@2399 a494cfbc-eb01-0410-851d-a64ba20cac60 --- programs/network/htmlv/browser/HTMLv.c-- | 2 +- programs/network/htmlv/browser/History.txt | 4 ++++ programs/network/htmlv/browser/TWB.h-- | 20 +++++++++---------- .../network/htmlv/browser/include/history.h-- | 2 +- 4 files changed, 16 insertions(+), 12 deletions(-) diff --git a/programs/network/htmlv/browser/HTMLv.c-- b/programs/network/htmlv/browser/HTMLv.c-- index 896c79e0c8..a7f5bb3c84 100644 --- a/programs/network/htmlv/browser/HTMLv.c-- +++ b/programs/network/htmlv/browser/HTMLv.c-- @@ -144,7 +144,7 @@ void Draw_Window() WB1.top=44; WB1.width=Form.width-11; WB1.height=onTop(43,5); - WB1.Load(#URL); + WB1.ShowPage(#URL); } int onLeft(dword right,left) {return Form.width-right-left;} diff --git a/programs/network/htmlv/browser/History.txt b/programs/network/htmlv/browser/History.txt index 80c618679d..10843f5178 100644 --- a/programs/network/htmlv/browser/History.txt +++ b/programs/network/htmlv/browser/History.txt @@ -1,3 +1,7 @@ +24.02.12 -- v0.72 -- 11.? Кб +- просто починил эти самые интернеты. + + 26.09.11 -- v0.70с -- 11.4 Кб - универсальная обработка цветов; - улучшения в обработке title; diff --git a/programs/network/htmlv/browser/TWB.h-- b/programs/network/htmlv/browser/TWB.h-- index 4aceee48e8..a216319b94 100644 --- a/programs/network/htmlv/browser/TWB.h-- +++ b/programs/network/htmlv/browser/TWB.h-- @@ -1,4 +1,3 @@ -//http://jsbeautifier.org/ //Web-component, Leency & Veliant 2007-2009 //lev @@ -16,7 +15,7 @@ dword j, char download_path[]="/rd/1/.download"; //char search_path[]="http://nova.rambler.ru/search?words="; char search_path[]="http://nigma.ru/index.php?s="; - char version[]=" Text-based Browser 23.71"; + char version[]=" Text-based Browser 0.71"; struct TWebBrowser { @@ -25,7 +24,7 @@ struct TWebBrowser { width, height; void DrawScroller(); - void Load(); + void ShowPage(); void ParseHTML(dword, dword); void Scan(dword); void WhatTextStyle(int left1, top1, width1); @@ -78,7 +77,7 @@ void TWebBrowser::Scan(dword id) { if (!strcmp(get_URL_part(5),"http:"))) HttpLoad(); //Lee 21.02 } - Load(#URL); + ShowPage(#URL); Draw_Window(); return; } @@ -97,7 +96,7 @@ void TWebBrowser::Scan(dword id) { BrowserHistory.GoBack(); return; case FORWARD: - //RunProgram("@notify", "Forward button is not realized yet"); + RunProgram("@notify", "Forward button is not realized yet"); return; case 054: //F5 IF(edit1.flags == 66) break; @@ -111,24 +110,25 @@ void TWebBrowser::Scan(dword id) { MoveSize(190,80,OLD,OLD); RunProgram(#program_path, #URL); return; - case HOME: - copystr("/sys/index.htm", #editURL); case 052: //Нажата F3 IF(edit1.flags <> 66) IF (strcmp(get_URL_part(5),"http:")<>0) RunProgram("tinypad", #URL); ELSE RunProgram("tinypad", #download_path); return; + case HOME: + copystr("http://bash.org.ru", #editURL); case GOTOURL: case 0x0D: //enter copystr(#editURL, #URL); if (!strcmp(get_URL_part(5),"http:"))) HttpLoad(); - Load(#URL); + ShowPage(#URL); return; case 173: //ctrl+enter case SEARCHWEB: copystr(#search_path, #URL); copystr(#editURL, #URL + strlen(#URL)); - Load(#URL); + if (!strcmp(get_URL_part(5),"http:"))) HttpLoad(); + ShowPage(#URL); return; case ID1: //мотаем вверх @@ -213,7 +213,7 @@ void ReadHtml() -void TWebBrowser::Load(dword adress) { +void TWebBrowser::ShowPage(dword adress) { max_kolvo_stolbcov = width - 30 / 6; max_kolvo_strok = height - 3 / 10 - 2; copystr(#version, #header); diff --git a/programs/network/htmlv/browser/include/history.h-- b/programs/network/htmlv/browser/include/history.h-- index 0aed468c51..2b9533412b 100644 --- a/programs/network/htmlv/browser/include/history.h-- +++ b/programs/network/htmlv/browser/include/history.h-- @@ -18,7 +18,7 @@ void UrlsHistory::GoBack() j--; } UrlHistory[j] = 0x00; - WB1.Load(#URL); + WB1.ShowPage(#URL); } void UrlsHistory::AddUrl()