From e33b239aec65c169fa47666558e61ed7e797ec99 Mon Sep 17 00:00:00 2001 From: "Kirill Lipatov (Leency)" Date: Wed, 23 Mar 2016 11:13:28 +0000 Subject: [PATCH] Aelia 0.36: port Download manager from WebView, fix two issues in it git-svn-id: svn://kolibrios.org@6366 a494cfbc-eb01-0410-851d-a64ba20cac60 --- programs/cmm/aelia/aelia.c | 14 ++++- programs/cmm/aelia/buidin_pages/about.htm | Bin 579 -> 579 bytes programs/cmm/browser/WebView.c | 2 - programs/cmm/browser/download_manager.h | 15 +++-- programs/cmm/browser/http_downloader.h | 66 ---------------------- 5 files changed, 21 insertions(+), 76 deletions(-) delete mode 100644 programs/cmm/browser/http_downloader.h diff --git a/programs/cmm/aelia/aelia.c b/programs/cmm/aelia/aelia.c index 571266b625..7070c168a5 100644 --- a/programs/cmm/aelia/aelia.c +++ b/programs/cmm/aelia/aelia.c @@ -15,6 +15,7 @@ #include "../lib/patterns/simple_open_dialog.h" #include "../lib/patterns/history.h" #include "../lib/patterns/http_downloader.h" +#include "../browser/download_manager.h" char default_dir[] = "/rd/1"; od_filter filter2 = {0,0}; @@ -68,7 +69,7 @@ dword CursorFile = FROM "pointer.cur"; #include "prepare_page.h" //#include "special_symbols.h" -#define SANDWICH_MENU "Refresh page\nEdit page\nHistory\nAbout" +#define SANDWICH_MENU "Refresh page\nEdit page\nHistory\nDownloader\nAbout" void InitDlls() { @@ -117,7 +118,8 @@ void main() if (menu.list.cur_y==0) EventPageRefresh(); if (menu.list.cur_y==1) EventRunEdit(); if (menu.list.cur_y==2) EventShowHistory(); - if (menu.list.cur_y==3) EventShowInfo(); + if (menu.list.cur_y==3) EventShowDownloader(); + if (menu.list.cur_y==4) EventShowInfo(); menu.list.cur_y = 0; } } @@ -391,6 +393,14 @@ void EventPageRefresh() EventOpenAddress(history.current()); } +void EventShowDownloader() +{ + if (!downloader_opened) { + downloader_edit = NULL; + CreateThread(#Downloader,#downloader_stak+4092); + } +} + /* ------------------------------------------- */ diff --git a/programs/cmm/aelia/buidin_pages/about.htm b/programs/cmm/aelia/buidin_pages/about.htm index 0dd4d3752d60a69aa3596eb4468b27365b69abff..67d8f7ada81e53ac941725cc28102ac0f17e3364 100644 GIT binary patch delta 12 TcmX@ia+qa85~JD1