/programs/cmm/browser/WebView.c |
---|
307,6 → 307,9 |
void draw_window() |
{ |
int i; |
bool burger_active = false; |
if (menu_id == OPEN_FILE) burger_active = true; |
SetElementSizes(); |
DrawBar(0,0, Form.cwidth,PADDING, sc.work); |
316,9 → 319,9 |
DrawBar(0, PADDING, address_box.left-2, TSZE+1, sc.work); |
DrawBar(address_box.left+address_box.width+18, PADDING, Form.cwidth-address_box.left-address_box.width-18, TSZE+1, sc.work); |
DrawTopPanelButton(BACK_BUTTON, PADDING-1, PADDING, 30); |
DrawTopPanelButton(FORWARD_BUTTON, PADDING+TSZE+PADDING-2, PADDING, 31); |
DrawTopPanelButton(SANDWICH_BUTTON, Form.cwidth-PADDING-TSZE-3, PADDING, -1); //burger menu |
DrawTopPanelButton(BACK_BUTTON, PADDING-1, PADDING, 30, false); |
DrawTopPanelButton(FORWARD_BUTTON, PADDING+TSZE+PADDING-2, PADDING, 31, false); |
DrawTopPanelButton(SANDWICH_BUTTON, Form.cwidth-PADDING-TSZE-3, PADDING, -1, burger_active); //burger menu |
DrawBar(0,Form.cheight - STATUSBAR_H, Form.cwidth,1, sc.work_graph); |
763,12 → 766,14 |
void ProcessMenuClick() |
{ |
int click_id; |
if (menu_id) && (click_id = get_menu_click()) { |
if (menu_id) { |
if (click_id = get_menu_click()) { |
click_id += menu_id - 1; |
menu_id = NULL; |
ProcessEvent(click_id); |
} |
if (!menu_process_id) menu_id = NULL; |
} |
} |
void EventUpdateProgressBar() |
{ |
/programs/cmm/codeview/codeview.c |
---|
180,7 → 180,7 |
DrawEditBoxWebView(); |
} |
DrawRectangle(scroll_wv.start_x, scroll_wv.start_y, scroll_wv.size_x, scroll_wv.size_y-1, scroll_wv.bckg_col); |
DrawTopPanelButton(OPEN_PAGE, 10, address_box.top-3, 0); |
DrawTopPanelButton(OPEN_PAGE, 10, address_box.top-3, 0, false); |
} |
/programs/cmm/lib/gui.h |
---|
209,8 → 209,7 |
:void PutShadow(dword x,y,w,h,skinned,strength) |
{ |
proc_info wForm; |
dword shadow_buf, skin_height; |
shadow_buf = mem_Alloc(w*h*3); |
dword shadow_buf = mem_Alloc(w*h*3); |
GetProcessInfo(#wForm, SelfInfo); |
CopyScreen(shadow_buf, 5*skinned+x+wForm.left, GetSkinHeight()*skinned+y+wForm.top, w, h); |
ShadowImage(shadow_buf, w, h, strength); |
/programs/cmm/lib/patterns/toolbar_button.h |
---|
1,5 → 1,5 |
unsigned int DrawTopPanelButton(dword _button_id, _x, _y, signed int _icon_n) |
unsigned int DrawTopPanelButton(dword _button_id, _x, _y, signed int _icon_n, bool pressed) |
{ |
#define TSZE 25 |
static libimg_image top_icons; |
17,7 → 17,6 |
} |
DrawWideRectangle(_x+1, _y+1, TSZE, TSZE, 5, semi_white); |
DrawOvalBorder(_x, _y, TSZE, TSZE, bg_col_light, bg_col_dark, semi_white, sc.work); |
DefineHiddenButton(_x, _y, TSZE+1, TSZE+1, _button_id); |
if (_icon_n==-1) { |
24,7 → 23,15 |
DrawBar(_x+6, _y+5, 16, 16, semi_white); |
for (i=0; i<=2; i++) DrawBar(_x+6, i*5+_y+7, 15, 3, sc.work_graph); |
} else { |
img_draw stdcall(top_icons.image, _x+6, _y+5, 16, 16, 0, _icon_n*16); |
img_draw stdcall(top_icons.image, _x+6, _y+5+pressed, 16, 16, 0, _icon_n*16); |
} |
if (!pressed) { |
DrawOvalBorder(_x, _y, TSZE, TSZE, bg_col_light, bg_col_dark, semi_white, sc.work); |
} else { |
DrawOvalBorder(_x, _y, TSZE, TSZE, sc.work_graph, bg_col_light, semi_white, sc.work); |
PutShadow(_x+1, _y+1, TSZE, TSZE, true, 2); |
} |
return _x; |
} |