WebView 1.94: code refactoring and bugfixing; also

- rework source code view, open it in a new tab
- fix tagparm parsing for case: src=./images/KolibriOS_logo2.jpg?sid=e8ece8b38b
- fix: show image text in multiple lines if need

git-svn-id: svn://kolibrios.org@7750 a494cfbc-eb01-0410-851d-a64ba20cac60
This commit is contained in:
2020-03-25 00:18:19 +00:00
parent eaed653ad3
commit e7484ebe37
12 changed files with 266 additions and 392 deletions
+9 -10
View File
@@ -193,7 +193,7 @@ void OpenPage()
if (!strncmp(#URL,"CodeView:",8))
{
SetPageDefaults();
if (!strcmp(#URL, URL_SERVICE_HOME)) WB1.LoadInternalPage(#homepage, sizeof(homepage));
if (!strcmp(#URL, URL_SERVICE_HOME)) LoadInternalPage(#homepage, sizeof(homepage));
DrawEditBoxWebView();
return;
}
@@ -208,7 +208,7 @@ void OpenPage()
SetPageDefaults();
ReadFile(0, bufsize, bufpointer, #URL);
ShowCodeSource();
WB1.LoadInternalPage(bufpointer, bufsize);
LoadInternalPage(bufpointer, bufsize);
}
ShowPage();
}
@@ -226,18 +226,17 @@ DrawEditBoxWebView()
img_draw stdcall(skin.image, address_box.left+address_box.width+1, address_box.top-3, 17, skin.h, skin_x_offset, SKIN_Y);
}
void LoadInternalPage(dword bufpos, in_filesize){
bufsize = in_filesize;
bufpointer = bufpos;
ShowPage();
}
void ShowPage()
{
DrawEditBoxWebView();
if (!bufsize)
{
WB1.LoadInternalPage(#page_not_found, sizeof(page_not_found));
}
else
{
WB1.Prepare();
}
if (!bufsize) LoadInternalPage(#page_not_found, sizeof(page_not_found));
WB1.Prepare();
}
void DrawStatusBar() {return;};