diff options
author | Alexey Yakovenko <waker@users.sourceforge.net> | 2014-01-15 22:29:52 +0100 |
---|---|---|
committer | Alexey Yakovenko <waker@users.sourceforge.net> | 2014-01-15 22:29:52 +0100 |
commit | 4ce5e51690756326965dc76bb733dd100d843557 (patch) | |
tree | df3e7d99fd624b4c10f57c6bbac180a32778d6e2 /plugins/gtkui | |
parent | 4bf3789ee387de86e1f3dac602089f041513e767 (diff) |
[gtkui] another fix to column autoresizing, now should work in gnome shell as well
Diffstat (limited to 'plugins/gtkui')
-rw-r--r-- | plugins/gtkui/ddblistview.c | 17 |
1 files changed, 3 insertions, 14 deletions
diff --git a/plugins/gtkui/ddblistview.c b/plugins/gtkui/ddblistview.c index 8296c192..af2e65e5 100644 --- a/plugins/gtkui/ddblistview.c +++ b/plugins/gtkui/ddblistview.c @@ -2435,20 +2435,9 @@ ddb_listview_header_configure_event (GtkWidget *widget, void ddb_listview_lock_columns (DdbListview *lv, gboolean lock) { lv->lock_columns = lock; - if (lock == 0) { - GtkAllocation a; - gtk_widget_get_allocation (GTK_WIDGET (lv), &a); - if (deadbeef->conf_get_int ("gtkui.autoresize_columns", 0)) { - DdbListviewColumn *c; - if (!lv->col_autoresize) { - for (c = lv->columns; c; c = c->next) { - c->fwidth = (float)c->width / (float)a.width; - } - lv->col_autoresize = 1; - } - } - lv->header_width = a.width; - } + + // NOTE: at this point, it's still not guaranteed that the allocation contains + // the final size, so we don't calc initial autoresize state here } |