Commit b8ce5f07 authored by Robert Liao's avatar Robert Liao Committed by Commit Bot

Fix Lint Errors in ui/views

BUG=940744
TBR=sky@chromium.org

Change-Id: Icc3035d8a5f07933abd6b6630a5e4470b46bc49a
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/1618174Reviewed-by: default avatarScott Violet <sky@chromium.org>
Commit-Queue: Robert Liao <robliao@chromium.org>
Cr-Commit-Position: refs/heads/master@{#661385}
parent 793bf499
...@@ -124,7 +124,7 @@ class EmptyBorder : public Border { ...@@ -124,7 +124,7 @@ class EmptyBorder : public Border {
// Overridden from Border: // Overridden from Border:
void Paint(const View& view, gfx::Canvas* canvas) override; void Paint(const View& view, gfx::Canvas* canvas) override;
gfx::Insets GetInsets() const override ; gfx::Insets GetInsets() const override;
gfx::Size GetMinimumSize() const override; gfx::Size GetMinimumSize() const override;
private: private:
......
...@@ -21,7 +21,7 @@ class BridgedNativeWidgetHostImpl; ...@@ -21,7 +21,7 @@ class BridgedNativeWidgetHostImpl;
class VIEWS_EXPORT TextInputHost class VIEWS_EXPORT TextInputHost
: public views_bridge_mac::mojom::TextInputHost { : public views_bridge_mac::mojom::TextInputHost {
public: public:
TextInputHost(BridgedNativeWidgetHostImpl* host_impl); explicit TextInputHost(BridgedNativeWidgetHostImpl* host_impl);
~TextInputHost() override; ~TextInputHost() override;
void BindRequest( void BindRequest(
views_bridge_mac::mojom::TextInputHostAssociatedRequest request); views_bridge_mac::mojom::TextInputHostAssociatedRequest request);
......
...@@ -223,7 +223,7 @@ class VIEWS_EXPORT Button : public InkDropHostView, ...@@ -223,7 +223,7 @@ class VIEWS_EXPORT Button : public InkDropHostView,
// TODO(cyan): Consider having Button implement ButtonControllerDelegate. // TODO(cyan): Consider having Button implement ButtonControllerDelegate.
class DefaultButtonControllerDelegate : public ButtonControllerDelegate { class DefaultButtonControllerDelegate : public ButtonControllerDelegate {
public: public:
DefaultButtonControllerDelegate(Button* button); explicit DefaultButtonControllerDelegate(Button* button);
~DefaultButtonControllerDelegate() override; ~DefaultButtonControllerDelegate() override;
// views::ButtonControllerDelegate: // views::ButtonControllerDelegate:
......
...@@ -13,7 +13,7 @@ class Button; ...@@ -13,7 +13,7 @@ class Button;
// ButtonController between different Button types. // ButtonController between different Button types.
class VIEWS_EXPORT ButtonControllerDelegate { class VIEWS_EXPORT ButtonControllerDelegate {
public: public:
ButtonControllerDelegate(Button* button) : button_(button) {} explicit ButtonControllerDelegate(Button* button) : button_(button) {}
virtual ~ButtonControllerDelegate() {} virtual ~ButtonControllerDelegate() {}
......
...@@ -27,4 +27,4 @@ class VIEWS_EXPORT TableGrouper { ...@@ -27,4 +27,4 @@ class VIEWS_EXPORT TableGrouper {
} // namespace views } // namespace views
#endif // UI_VIEWS_CONTROLS_TABLE_GROUP_TABLE_VIEW_H_ #endif // UI_VIEWS_CONTROLS_TABLE_TABLE_GROUPER_H_
...@@ -441,4 +441,4 @@ class VIEWS_EXPORT TreeView : public View, ...@@ -441,4 +441,4 @@ class VIEWS_EXPORT TreeView : public View,
} // namespace views } // namespace views
#endif // UI_VIEWS_CONTROLS_TREE_TREE_VIEW_VIEWS_H_ #endif // UI_VIEWS_CONTROLS_TREE_TREE_VIEW_H_
...@@ -44,4 +44,4 @@ class VIEWS_EXPORT TreeViewDrawingProvider { ...@@ -44,4 +44,4 @@ class VIEWS_EXPORT TreeViewDrawingProvider {
} // namespace views } // namespace views
#endif // UI_VIEWS_CONTROLS_TREE_TREE_VIEW_DISPLAY_PROVIDER_H_ #endif // UI_VIEWS_CONTROLS_TREE_TREE_VIEW_DRAWING_PROVIDER_H_
...@@ -58,4 +58,4 @@ class VIEWS_EXPORT StatusIconLinux { ...@@ -58,4 +58,4 @@ class VIEWS_EXPORT StatusIconLinux {
} // namespace views } // namespace views
#endif // UI_LINUX_UI_STATUS_ICON_LINUX_H_ #endif // UI_VIEWS_LINUX_UI_STATUS_ICON_LINUX_H_
...@@ -40,7 +40,8 @@ struct EnumStrings { ...@@ -40,7 +40,8 @@ struct EnumStrings {
base::string16 str_value; base::string16 str_value;
}; };
EnumStrings(std::vector<EnumString> init_val) : pairs(std::move(init_val)) {} explicit EnumStrings(std::vector<EnumString> init_val)
: pairs(std::move(init_val)) {}
const std::vector<EnumString> pairs; const std::vector<EnumString> pairs;
}; };
......
...@@ -47,4 +47,4 @@ class ComboboxTestApi { ...@@ -47,4 +47,4 @@ class ComboboxTestApi {
} // namespace views } // namespace views
#endif // UI_VIEWS_TEST_MENU_RUNNER_TEST_API_H_ #endif // UI_VIEWS_TEST_COMBOBOX_TEST_API_H_
...@@ -28,4 +28,4 @@ class DesktopTestViewsDelegate : public TestViewsDelegate { ...@@ -28,4 +28,4 @@ class DesktopTestViewsDelegate : public TestViewsDelegate {
} // namespace views } // namespace views
#endif #endif // UI_VIEWS_TEST_DESKTOP_TEST_VIEWS_DELEGATE_H_
...@@ -697,7 +697,6 @@ class TestTouchEditable : public ui::TouchEditable { ...@@ -697,7 +697,6 @@ class TestTouchEditable : public ui::TouchEditable {
gfx::Rect bounds_; gfx::Rect bounds_;
// Cursor position inside the client view. // Cursor position inside the client view.
//gfx::Rect cursor_rect_;
gfx::SelectionBound cursor_bound_; gfx::SelectionBound cursor_bound_;
DISALLOW_COPY_AND_ASSIGN(TestTouchEditable); DISALLOW_COPY_AND_ASSIGN(TestTouchEditable);
......
...@@ -67,7 +67,7 @@ class VIEWS_EXPORT DesktopScreenX11 : public display::Screen, ...@@ -67,7 +67,7 @@ class VIEWS_EXPORT DesktopScreenX11 : public display::Screen,
friend class test::DesktopScreenX11TestApi; friend class test::DesktopScreenX11TestApi;
// Constructor used in tests. // Constructor used in tests.
DesktopScreenX11(const std::vector<display::Display>& test_displays); explicit DesktopScreenX11(const std::vector<display::Display>& test_displays);
// Removes |delayed_configuration_task_| from the task queue (if // Removes |delayed_configuration_task_| from the task queue (if
// it's in the queue) and adds it back at the end of the queue. // it's in the queue) and adds it back at the end of the queue.
......
...@@ -247,8 +247,8 @@ TEST_F(DesktopWindowTreeHostX11Test, InputMethodFocus) { ...@@ -247,8 +247,8 @@ TEST_F(DesktopWindowTreeHostX11Test, InputMethodFocus) {
EXPECT_FALSE(widget->IsActive()); EXPECT_FALSE(widget->IsActive());
// TODO(shuchen): uncomment the below check once the // TODO(shuchen): uncomment the below check once the
// "default-focused-input-method" logic is removed in aura::WindowTreeHost. // "default-focused-input-method" logic is removed in aura::WindowTreeHost.
//EXPECT_EQ(ui::TEXT_INPUT_TYPE_NONE, // EXPECT_EQ(ui::TEXT_INPUT_TYPE_NONE,
// widget->GetInputMethod()->GetTextInputType()); // widget->GetInputMethod()->GetTextInputType());
widget->Activate(); widget->Activate();
ActivationWaiter waiter( ActivationWaiter waiter(
......
...@@ -23,4 +23,4 @@ class VIEWS_EXPORT X11DesktopHandlerObserver { ...@@ -23,4 +23,4 @@ class VIEWS_EXPORT X11DesktopHandlerObserver {
} // namespace views } // namespace views
#endif // UI_DISPLAY_DESKTOP_OBSERVER_H_ #endif // UI_VIEWS_WIDGET_DESKTOP_AURA_X11_DESKTOP_HANDLER_OBSERVER_H_
...@@ -50,6 +50,6 @@ class VIEWS_EXPORT X11TopmostWindowFinder ...@@ -50,6 +50,6 @@ class VIEWS_EXPORT X11TopmostWindowFinder
DISALLOW_COPY_AND_ASSIGN(X11TopmostWindowFinder); DISALLOW_COPY_AND_ASSIGN(X11TopmostWindowFinder);
}; };
} // namespace } // namespace views
#endif // UI_VIEWS_WIDGET_DESKTOP_AURA_X11_TOPMOST_WINDOW_FINDER_H_ #endif // UI_VIEWS_WIDGET_DESKTOP_AURA_X11_TOPMOST_WINDOW_FINDER_H_
...@@ -98,9 +98,9 @@ TEST_F(NativeWidgetAuraTest, CenterWindowLargeParent) { ...@@ -98,9 +98,9 @@ TEST_F(NativeWidgetAuraTest, CenterWindowLargeParent) {
NativeWidgetAura* window = Init(parent.get(), widget.get()); NativeWidgetAura* window = Init(parent.get(), widget.get());
window->CenterWindow(gfx::Size(100, 100)); window->CenterWindow(gfx::Size(100, 100));
EXPECT_EQ(gfx::Rect( (640 - 100) / 2, EXPECT_EQ(gfx::Rect((640 - 100) / 2,
(480 - 100) / 2, (480 - 100) / 2,
100, 100), 100, 100),
window->GetNativeWindow()->bounds()); window->GetNativeWindow()->bounds());
widget->CloseNow(); widget->CloseNow();
} }
...@@ -115,9 +115,9 @@ TEST_F(NativeWidgetAuraTest, CenterWindowSmallParent) { ...@@ -115,9 +115,9 @@ TEST_F(NativeWidgetAuraTest, CenterWindowSmallParent) {
NativeWidgetAura* window = Init(parent.get(), widget.get()); NativeWidgetAura* window = Init(parent.get(), widget.get());
window->CenterWindow(gfx::Size(100, 100)); window->CenterWindow(gfx::Size(100, 100));
EXPECT_EQ(gfx::Rect( (480 - 100) / 2, EXPECT_EQ(gfx::Rect((480 - 100) / 2,
(320 - 100) / 2, (320 - 100) / 2,
100, 100), 100, 100),
window->GetNativeWindow()->bounds()); window->GetNativeWindow()->bounds());
widget->CloseNow(); widget->CloseNow();
} }
......
...@@ -17,4 +17,4 @@ VIEWS_EXPORT gfx::NativeWindow GetRootWindow(const Widget* widget); ...@@ -17,4 +17,4 @@ VIEWS_EXPORT gfx::NativeWindow GetRootWindow(const Widget* widget);
} // namespace views } // namespace views
#endif // UI_VIEWS_WIDGET_WIDGET_H_ #endif // UI_VIEWS_WIDGET_WIDGET_UTILS_H_
...@@ -13,4 +13,4 @@ gfx::Size GetWindowSizeForClientSize(Widget* widget, const gfx::Size& size); ...@@ -13,4 +13,4 @@ gfx::Size GetWindowSizeForClientSize(Widget* widget, const gfx::Size& size);
} // namespace views } // namespace views
#endif // UI_VIEWS_WIDGET_WIDGET_UTILS_MAC_H_ #endif // UI_VIEWS_WIDGET_WIDGET_UTILS_MAC_H_
\ No newline at end of file
...@@ -103,4 +103,4 @@ void WindowResizeUtils::SizeRectToAspectRatio(HitTest param, ...@@ -103,4 +103,4 @@ void WindowResizeUtils::SizeRectToAspectRatio(HitTest param,
rect->SetByBounds(left, top, right, bottom); rect->SetByBounds(left, top, right, bottom);
} }
} // namespace views } // namespace views
\ No newline at end of file
...@@ -53,4 +53,4 @@ class VIEWS_EXPORT WindowResizeUtils { ...@@ -53,4 +53,4 @@ class VIEWS_EXPORT WindowResizeUtils {
} // namespace views } // namespace views
#endif // UI_VIEWS_WINDOW_WINDOW_RESIZE_UTILS_H_ #endif // UI_VIEWS_WINDOW_WINDOW_RESIZE_UTILS_H_
\ No newline at end of file
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment