summaryrefslogtreecommitdiffstats
path: root/views/view.cc
diff options
context:
space:
mode:
authorjcampan@chromium.org <jcampan@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2009-12-01 01:06:12 +0000
committerjcampan@chromium.org <jcampan@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2009-12-01 01:06:12 +0000
commit0b2fa2b16961888c0936290b58435937de938b42 (patch)
treecfbd5b88232a447517c5cc1fa8eab810dc6f0a49 /views/view.cc
parent78cc12bfd89dbabb585fc658b508ff90de3ff473 (diff)
downloadchromium_src-0b2fa2b16961888c0936290b58435937de938b42.zip
chromium_src-0b2fa2b16961888c0936290b58435937de938b42.tar.gz
chromium_src-0b2fa2b16961888c0936290b58435937de938b42.tar.bz2
Porting the table view to Linux toolkit views.
It is the initial implementation, it is still missing: - row focusing - resizable columns - autosize columns BUG=None TEST=Run the unit-tests, play with the TableView2 tab in the view examples. Review URL: http://codereview.chromium.org/434066 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@33400 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'views/view.cc')
-rw-r--r--views/view.cc2
1 files changed, 2 insertions, 0 deletions
diff --git a/views/view.cc b/views/view.cc
index f4869ec..a8de837 100644
--- a/views/view.cc
+++ b/views/view.cc
@@ -518,6 +518,8 @@ void View::AddChildView(View* v) {
}
void View::AddChildView(int index, View* v) {
+ CHECK(v != this) << "You cannot add a view as its own child";
+
// Remove the view from its current parent if any.
if (v->GetParent())
v->GetParent()->RemoveChildView(v);