banshee r4584 - in trunk/banshee: . src/Libraries/Hyena.Gui/Hyena.Data.Gui/ListView
- From: abock svn gnome org
- To: svn-commits-list gnome org
- Subject: banshee r4584 - in trunk/banshee: . src/Libraries/Hyena.Gui/Hyena.Data.Gui/ListView
- Date: Mon, 22 Sep 2008 19:34:52 +0000 (UTC)
Author: abock
Date: Mon Sep 22 19:34:52 2008
New Revision: 4584
URL: http://svn.gnome.org/viewvc/banshee?rev=4584&view=rev
Log:
2008-09-22 Aaron Bockover <abock gnome org>
* src/Libraries/Hyena.Gui/Hyena.Data.Gui/ListView/ListView_Rendering.cs:
Only draw the header separator if the column can be resized, or a previous
header separator has already been drawn - this allows leading columns
to appear as one column
Modified:
trunk/banshee/ChangeLog
trunk/banshee/src/Libraries/Hyena.Gui/Hyena.Data.Gui/ListView/ListView_Rendering.cs
Modified: trunk/banshee/src/Libraries/Hyena.Gui/Hyena.Data.Gui/ListView/ListView_Rendering.cs
==============================================================================
--- trunk/banshee/src/Libraries/Hyena.Gui/Hyena.Data.Gui/ListView/ListView_Rendering.cs (original)
+++ trunk/banshee/src/Libraries/Hyena.Gui/Hyena.Data.Gui/ListView/ListView_Rendering.cs Mon Sep 22 19:34:52 2008
@@ -116,6 +116,8 @@
cell_context.Sensitive = true;
cell_context.TextAsForeground = true;
+ bool have_drawn_separator = false;
+
for (int ci = 0; ci < column_cache.Length; ci++) {
if (pressed_column_is_dragging && pressed_column_index == ci) {
continue;
@@ -123,19 +125,19 @@
cell_area.X = column_cache[ci].X1 + Theme.TotalBorderWidth + header_rendering_alloc.X - HadjustmentValue;
cell_area.Width = column_cache[ci].Width;
- PaintHeaderCell (cell_area, ci, false);
+ PaintHeaderCell (cell_area, ci, false, ref have_drawn_separator);
}
if (pressed_column_is_dragging && pressed_column_index >= 0) {
cell_area.X = pressed_column_x_drag + Allocation.X - HadjustmentValue;
cell_area.Width = column_cache[pressed_column_index].Width;
- PaintHeaderCell (cell_area, pressed_column_index, true);
+ PaintHeaderCell (cell_area, pressed_column_index, true, ref have_drawn_separator);
}
cairo_context.ResetClip ();
}
- private void PaintHeaderCell (Rectangle area, int ci, bool dragging)
+ private void PaintHeaderCell (Rectangle area, int ci, bool dragging, ref bool have_drawn_separator)
{
if (ci < 0 || column_cache.Length <= ci)
return;
@@ -166,7 +168,9 @@
cairo_context.Restore ();
}
- if (!dragging && ci < column_cache.Length - 1) {
+ if (!dragging && ci < column_cache.Length - 1 && (have_drawn_separator ||
+ column_cache[ci].MaxWidth != column_cache[ci].MinWidth)) {
+ have_drawn_separator = true;
Theme.DrawHeaderSeparator (cairo_context, area, area.Right);
}
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]