| Index: ui/views/fill_attribute.cc
|
| diff --git a/ui/views/fill_attribute.cc b/ui/views/fill_attribute.cc
|
| new file mode 100644
|
| index 0000000000000000000000000000000000000000..50b86d737904e76d22e7b09dbaa68bdd2ea890fb
|
| --- /dev/null
|
| +++ b/ui/views/fill_attribute.cc
|
| @@ -0,0 +1,26 @@
|
| +// Copyright (c) 2016 The Chromium Authors. All rights reserved.
|
| +// Use of this source code is governed by a BSD-style license that can be
|
| +// found in the LICENSE file.
|
| +
|
| +#include "ui/views/fill_attribute.h"
|
| +#include "ui/views/anchor_attribute.h"
|
| +
|
| +namespace views {
|
| +
|
| +AttributeId FillAttribute::Identity() const {
|
| + return GetAttributeId<FillAttribute>();
|
| +}
|
| +
|
| +void FillAttribute::SetFill(Fill fill) {
|
| + if (this->fill() != fill) {
|
| + this->GetContent() = fill;
|
| + View *view = this->view();
|
| + if (view) {
|
| + AnchorAttribute *anchors = nullptr;
|
| + if (view->attributes().Find(anchors))
|
| + anchors->Notification(Attribute::NotifyType::AttributeAdded, this);
|
| + }
|
| + }
|
| +}
|
| +
|
| +} // namespace views
|
|
|