summaryrefslogtreecommitdiffstats
path: root/views
diff options
context:
space:
mode:
authortfarina@chromium.org <tfarina@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2011-01-13 00:20:58 +0000
committertfarina@chromium.org <tfarina@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2011-01-13 00:20:58 +0000
commit31ae9addcfc81537293f5c4fc6c12ac9d8006159 (patch)
tree67a5714bfd0c20331dc2f2a2ddf4424849975d31 /views
parent3181ce55a4940ace32a7eaac7118c1e276765751 (diff)
downloadchromium_src-31ae9addcfc81537293f5c4fc6c12ac9d8006159.zip
chromium_src-31ae9addcfc81537293f5c4fc6c12ac9d8006159.tar.gz
chromium_src-31ae9addcfc81537293f5c4fc6c12ac9d8006159.tar.bz2
views: Implement NativeTableGtk::SetColumnWidth method.
BUG=None TEST=export GYP_DEFINES="toolkit_views" && gclient runhooks && make -j4 -k views_examples out/Debug/views_examples, everything should work as before. Review URL: http://codereview.chromium.org/6166011 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@71262 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'views')
-rw-r--r--views/controls/table/native_table_gtk.cc8
1 files changed, 7 insertions, 1 deletions
diff --git a/views/controls/table/native_table_gtk.cc b/views/controls/table/native_table_gtk.cc
index 0200c1b..633705b 100644
--- a/views/controls/table/native_table_gtk.cc
+++ b/views/controls/table/native_table_gtk.cc
@@ -80,7 +80,13 @@ int NativeTableGtk::GetColumnWidth(int column_index) const {
}
void NativeTableGtk::SetColumnWidth(int column_index, int width) {
- NOTIMPLEMENTED();
+ GtkTreeViewColumn* column = gtk_tree_view_get_column(tree_view_,
+ column_index);
+ column->width = width;
+ column->resized_width = width;
+ column->use_resized_width = TRUE;
+ // Needed for use_resized_width to be effective.
+ gtk_widget_queue_resize(GTK_WIDGET(tree_view_));
}
int NativeTableGtk::GetSelectedRowCount() const {