summaryrefslogtreecommitdiff
path: root/plugins
diff options
context:
space:
mode:
authorGravatar Alexey Yakovenko <wakeroid@gmail.com>2010-09-13 19:40:37 +0200
committerGravatar Alexey Yakovenko <wakeroid@gmail.com>2010-09-13 19:40:37 +0200
commit7140de0a5ee5e9758a5db0db37202ee473d25c0b (patch)
tree3a8508eb918ef8800a8f8233af5dd6818318ac06 /plugins
parent8b598119813219ccc1a887c01a4a6bd006f8134d (diff)
added 3px to virtual tabstrip width when scrolling
Diffstat (limited to 'plugins')
-rw-r--r--plugins/gtkui/ddbtabstrip.c9
1 files changed, 3 insertions, 6 deletions
diff --git a/plugins/gtkui/ddbtabstrip.c b/plugins/gtkui/ddbtabstrip.c
index 561616a6..909378e7 100644
--- a/plugins/gtkui/ddbtabstrip.c
+++ b/plugins/gtkui/ddbtabstrip.c
@@ -381,7 +381,7 @@ tabstrip_need_arrows (DdbTabStrip *ts) {
return 1;
}
}
- w += tab_overlap_size;
+ w += tab_overlap_size + 3;
if (w >= widget->allocation.width) {
return 1;
}
@@ -400,7 +400,7 @@ tabstrip_adjust_hscroll (DdbTabStrip *ts) {
for (int idx = 0; idx < cnt; idx++) {
w += ddb_tabstrip_get_tab_width (ts, idx) - tab_overlap_size;
}
- w += tab_overlap_size;
+ w += tab_overlap_size + 3;
if (ts->hscrollpos > w - (widget->allocation.width - arrow_widget_width*2)) {
ts->hscrollpos = w - (widget->allocation.width - arrow_widget_width*2);
deadbeef->conf_set_int ("gtkui.tabscroll", ts->hscrollpos);
@@ -452,7 +452,6 @@ tabstrip_render (DdbTabStrip *ts) {
int need_draw_moving = 0;
int idx;
int widths[cnt];
- int fullwidth = 0;
for (idx = 0; idx < cnt; idx++) {
char title[100];
plt_get_title_wrapper (idx, title, sizeof (title));
@@ -462,9 +461,7 @@ tabstrip_render (DdbTabStrip *ts) {
if (widths[idx] < min_tab_size) {
widths[idx] = min_tab_size;
}
- fullwidth += widths[idx] - tab_overlap_size;
}
- fullwidth += tab_overlap_size;
x = -hscroll + tabs_left_margin;
@@ -756,7 +753,7 @@ on_tabstrip_button_press_event (GtkWidget *widget,
for (int idx = 0; idx < cnt; idx++) {
w += ddb_tabstrip_get_tab_width (ts, idx) - tab_overlap_size;
}
- w += tab_overlap_size;
+ w += tab_overlap_size + 3;
if (ts->hscrollpos > w - (widget->allocation.width - arrow_widget_width*2)) {
ts->hscrollpos = w - (widget->allocation.width - arrow_widget_width*2);
}