Rev 7771 | Rev 7778 | Go to most recent revision | Show entire file | Regard whitespace | Details | Blame | Last modification | View Log | RSS feed
Rev 7771 | Rev 7775 | ||
---|---|---|---|
Line 67... | Line 67... | ||
67 | int tab_w = DEFAULT_TABW; |
67 | int tab_w = DEFAULT_TABW; |
68 | 68 | ||
Line 69... | Line 69... | ||
69 | int GetTabWidth() |
69 | int GetTabWidth() |
70 | { |
70 | { |
- | 71 | if (tab.count == TABS_MAX) return Form.cwidth / tab.count; |
|
71 | if (tab.count * DEFAULT_TABW + TAB_H < Form.cwidth) return DEFAULT_TABW; else |
72 | if (tab.count * DEFAULT_TABW + TAB_H < Form.cwidth) return DEFAULT_TABW; else |
72 | return Form.cwidth - TAB_H - 2 / tab.count; |
73 | return Form.cwidth - TAB_H - 2 / tab.count; |
73 | } |
74 | } |
Line 74... | Line 75... | ||
74 | 75 | ||
Line 113... | Line 114... | ||
113 | { |
114 | { |
114 | dword btn_light = MixColors(system.color.work_button, 0xFFFfff, 220); |
115 | dword btn_light = MixColors(system.color.work_button, 0xFFFfff, 220); |
115 | dword btn_dark = MixColors(system.color.work_button, 0, 180); |
116 | dword btn_dark = MixColors(system.color.work_button, 0, 180); |
116 | int xxx = tab.count * tab_w; |
117 | int xxx = tab.count * tab_w; |
117 | DrawBar(xxx, TOOLBAR_H, 1, TAB_H, system.color.work_graph); |
118 | |
- | 119 | if (tab.count < TABS_MAX) { |
|
- | 120 | DrawBar(xxx, TOOLBAR_H, 1, TAB_H, system.color.work_graph); |
|
118 | DrawBar(xxx+1, TOOLBAR_H, TAB_H, TAB_H-1, system.color.work_button); |
121 | DrawBar(xxx+1, TOOLBAR_H, TAB_H, TAB_H-1, system.color.work_button); |
119 | DrawRectangle3D(xxx+1, TOOLBAR_H, TAB_H, TAB_H-1, btn_light, btn_dark); |
122 | DrawRectangle3D(xxx+1, TOOLBAR_H, TAB_H, TAB_H-1, btn_light, btn_dark); |
120 | PutPixel(xxx+1+TAB_H, TOOLBAR_H, btn_dark); |
123 | PutPixel(xxx+1+TAB_H, TOOLBAR_H, btn_dark); |
121 | DefineHiddenButton(xxx+1, TOOLBAR_H, TAB_H-1, TAB_H-1, NEW_TAB); |
124 | DefineHiddenButton(xxx+1, TOOLBAR_H, TAB_H-1, TAB_H-1, NEW_TAB); |
122 | WriteText(xxx+7, TOOLBAR_H+2, 0x90, system.color.work_button_text, "+"); |
125 | WriteText(xxx+7, TOOLBAR_H+2, 0x90, system.color.work_button_text, "+"); |
123 | } |
126 | } |
124 | 127 | } |
|
- | 128 | ||
Line 125... | Line 129... | ||
125 | void DrawTabsBar() |
129 | void DrawTabsBar() |
126 | { |
130 | { |
127 | dword i; |
131 | dword i; |
128 | tab_w = GetTabWidth(); |
132 | tab_w = GetTabWidth(); |