From 415e0de80109ee63de1267f0de6bc364135e30a2 Mon Sep 17 00:00:00 2001 From: "Kirill Lipatov (Leency)" Date: Sun, 20 Oct 2013 22:47:10 +0000 Subject: [PATCH] Eolite 2.0a: fixes in OpenWith scroll, add End/Home key support git-svn-id: svn://kolibrios.org@4063 a494cfbc-eb01-0410-851d-a64ba20cac60 --- programs/cmm/eolite/imgs/png/icons.png | Bin 5810 -> 6486 bytes programs/cmm/eolite/include/open_with.h | 19 ++++++++++++++----- programs/cmm/lib/list_box.h | 24 +++++++++++++++++++++--- 3 files changed, 35 insertions(+), 8 deletions(-) diff --git a/programs/cmm/eolite/imgs/png/icons.png b/programs/cmm/eolite/imgs/png/icons.png index 017acd118c24c58b3a8ad5971181a8aea33c233d..c8f0b71aef9b3dab9c3d0601741a1a018fc9a07f 100644 GIT binary patch literal 6486 zcmV-c8L8%pP)sNkl`fI&ua zPzdr6MUeL}h#I&GQJ678kPuKp@RH^g6Y}c3E9vU4-yfB#?&_}YgoIhnz3c9^YE{)a z`};ln>{GkWsdG-ZLCTUOfSK?7C;nvqzdyw&DcURD)beYl^@{q=?00RxR`-@nM0MB*Yxd#w}lv^z5qutXcbk zs&CRGP_j%W`F`4C?Rh{*&dlZeS=!elZ5B147@!DKQ~Edcl- zaJK-wt?`8TA_kE27gd`tlzy&fqS?Anyz*OOm84Nt%(ADv6>)5)Zv2pWTiXfBIOO zk(4T(JoSU5=qra;FzHEX+hAUM?Roz4?nj)GE@<+aMG(?f3Fkj}krtOBG|Szb&hr6adLSqoW>073$}|!lO5msB8UXfwmCMk+ z5hTP7bQ_s?_s&Lu2ZEvzfb=XYfi=Yh))W)lH;nk0Csu`U- zcgAEg5gHb%rZw3+uU_+^w?-54f8qQuH`w0&$~?Zz`H_2v_9fwWtC~O9e)XMkbgZZ$ zqqGZYe|v^GlQ(l=!Gi!S`paRBHJ(PRK1ldwIBD+=hHL*I?cKp7By@H2iJx%(c<&1o zm9}Bbm>%r-yd%jk{=kmUIuJLeCxs;;q_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/include/open_with.h +++ b/programs/cmm/eolite/include/open_with.h @@ -106,14 +106,22 @@ void OpenWith() key = GetKey(); if (key==27) ExitProcess(); if (key==13) { RunProgram(#app_paths[app_list.current].item, #file_path); ExitProcess(); } - if (key==177) //down + if (key==177) { if (app_list.KeyDown()) DrawAppList(); } - if (key==178) //up + if (key==178) { if (app_list.KeyUp()) DrawAppList(); } + if (key==180) + { + if (app_list.KeyHome()) DrawAppList(); + } + if (key==181) + { + if (app_list.KeyEnd()) DrawAppList(); + } break; case evReDraw: _APP_LIST_DRAW: @@ -144,9 +152,10 @@ void DrawAppList() Put_icon(#app_paths[index+app_list.first].ext, app_list.x+4, index*app_list.line_h+app_list.y+2, col_bg, 6); WriteText(app_list.x+25, index*app_list.line_h+app_list.y+7, 0x80, 0, #app_paths[index+app_list.first].item); } - tiny_scroll.h = app_list.w*app_list.visible/app_list.count; tiny_scroll.x = app_list.x+app_list.w-SCROLL_WIDTH-1; - tiny_scroll.y = app_list.first * app_list.h / app_list.count + app_list.y; - if (tiny_scroll.y + tiny_scroll.h - app_list.y > app_list.h) tiny_scroll.y = app_list.y + app_list.h - tiny_scroll.h-1; + tiny_scroll.h = app_list.h * app_list.visible / app_list.count; + tiny_scroll.y = app_list.h * app_list.first / app_list.count + app_list.y; + debugi(tiny_scroll.y + tiny_scroll.h - app_list.y - app_list.h); + if (tiny_scroll.y + tiny_scroll.h - app_list.y - app_list.h >= 0) tiny_scroll.y = app_list.y + app_list.h - tiny_scroll.h-1; DrawBar(tiny_scroll.x, tiny_scroll.y, SCROLL_WIDTH, tiny_scroll.h, 0x555555); //scroll } \ No newline at end of file diff --git a/programs/cmm/lib/list_box.h b/programs/cmm/lib/list_box.h index e3a43190b2..6fde8e299b 100644 --- a/programs/cmm/lib/list_box.h +++ b/programs/cmm/lib/list_box.h @@ -8,6 +8,8 @@ struct llist void ClearList(); int KeyDown(); int KeyUp(); + int KeyHome(); + int KeyEnd(); void SetSizes(int xx, yy, ww, hh, min_hh, line_hh); int MouseScroll(dword scroll_state); }; @@ -51,12 +53,12 @@ int llist::KeyDown() { if (current-first+1=count) return -1; + if (current+1>=count) return 0; current++; } else { - if (visible+first>=count) return -1; + if (visible+first>=count) return 0; first++; current++; } @@ -71,9 +73,25 @@ int llist::KeyUp() } else { - if (first==0) return -1; + if (first==0) return 0; first--; current--; } return 1; +} + +int llist::KeyHome() +{ + if (current==0) && (first==0) return 0; + current=0; + first=0; + return 1; +} + +int llist::KeyEnd() +{ + if (current==count-1) && (first==count-visible) return 0; + current=count-1; + first=count-visible; + return 1; } \ No newline at end of file