| Index: ui/views/layout/layout_delegate.cc
|
| diff --git a/ui/views/layout/layout_delegate.cc b/ui/views/layout/layout_delegate.cc
|
| new file mode 100644
|
| index 0000000000000000000000000000000000000000..247158fcc8ae2da22003870006daf89e76f85907
|
| --- /dev/null
|
| +++ b/ui/views/layout/layout_delegate.cc
|
| @@ -0,0 +1,40 @@
|
| +// Copyright 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/layout/layout_constants.h"
|
| +#include "ui/views/layout/layout_delegate.h"
|
| +
|
| +namespace views {
|
| +
|
| +int LayoutDelegate::GetLayoutDistance(LayoutDistanceType type) const {
|
| + switch (type) {
|
| + case PANEL_VERT_MARGIN:
|
| + return kPanelVertMargin;
|
| + case RELATED_BUTTON_HORIZONTAL_SPACING:
|
| + return kRelatedButtonHSpacing;
|
| + case RELATED_CONTROL_HORIZONTAL_SPACING:
|
| + return kRelatedControlHorizontalSpacing;
|
| + case RELATED_CONTROL_VERTICAL_SPACING:
|
| + return kRelatedControlVerticalSpacing;
|
| + case UNRELATED_CONTROL_VERTICAL_SPACING:
|
| + return kUnrelatedControlVerticalSpacing;
|
| + case UNRELATED_CONTROL_LARGE_VERTICAL_SPACING:
|
| + return kUnrelatedControlLargeVerticalSpacing;
|
| + case BUTTON_VEDGE_MARGIN_NEW:
|
| + return kButtonVEdgeMarginNew;
|
| + case BUTTON_HEDGE_MARGIN_NEW:
|
| + return kButtonHEdgeMarginNew;
|
| + }
|
| + return 0;
|
| +}
|
| +
|
| +GridLayout::Alignment LayoutDelegate::GetControlLabelGridAlignment() const {
|
| + return kControlLabelGridAlignment;
|
| +}
|
| +
|
| +bool LayoutDelegate::UseExtraDialogPadding() const {
|
| + return true;
|
| +}
|
| +
|
| +} // namespace views
|
|
|