Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1764)

Unified Diff: ui/views/layout/grid_layout.h

Issue 2625083003: Implement Harmony-style consistent button widths for Collected Cookies. (Closed)
Patch Set: respond to comments Created 3 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « chrome/browser/ui/views/harmony/layout_delegate.cc ('k') | ui/views/layout/grid_layout.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ui/views/layout/grid_layout.h
diff --git a/ui/views/layout/grid_layout.h b/ui/views/layout/grid_layout.h
index e6a1ee35496efa63e064a1b845fde3f87f061fa0..197d101705caa195f5fd7c98fc20ab973187dc93 100644
--- a/ui/views/layout/grid_layout.h
+++ b/ui/views/layout/grid_layout.h
@@ -300,6 +300,11 @@ class VIEWS_EXPORT ColumnSet {
// LinkColumnSizes(0, 1, -1);
void LinkColumnSizes(int first, ...);
+ // When sizing linked columns, columns wider than |size_limit| are ignored.
+ void set_linked_column_size_limit(int size_limit) {
+ linked_column_size_limit_ = size_limit;
+ }
+
// ID of this ColumnSet.
int id() const { return id_; }
@@ -325,7 +330,7 @@ class VIEWS_EXPORT ColumnSet {
void AccumulateMasterColumns();
// Sets the size of each linked column to be the same.
- void UnifySameSizedColumnSizes();
+ void UnifyLinkedColumnSizes();
// Updates the remaining width field of the ViewState from that of the
// columns the view spans.
@@ -355,6 +360,10 @@ class VIEWS_EXPORT ColumnSet {
// ID for this columnset.
const int id_;
+ // Columns wider than this limit will be ignored when computing linked
+ // columns' sizes.
+ int linked_column_size_limit_;
+
// The columns.
std::vector<std::unique_ptr<Column>> columns_;
« no previous file with comments | « chrome/browser/ui/views/harmony/layout_delegate.cc ('k') | ui/views/layout/grid_layout.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698