Commit f75d1b97 authored by Shengsong Tan's avatar Shengsong Tan Committed by Chromium LUCI CQ

Adding metadata to LogoViewImpl

This is part of the "Views Posse" effort. See this document:
https://docs.google.com/document/d/1Rst3792TjXtVA8k8GXaPD8MnuB1JAneSOpIILdA4268/edit?usp=sharing

Bug: 1159562
Test: build
Change-Id: I447708cdb7a93afece8b11605b873d64a65db95e
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2600429Reviewed-by: default avatarAllen Bauer <kylixrd@chromium.org>
Reviewed-by: default avatarMitsuru Oshima <oshima@chromium.org>
Commit-Queue: Shengsong Tan <sstan@google.com>
Cr-Commit-Position: refs/heads/master@{#840878}
parent 7f465664
......@@ -16,6 +16,7 @@
#include "ui/gfx/geometry/insets.h"
#include "ui/gfx/geometry/rect_f.h"
#include "ui/gfx/geometry/vector2d.h"
#include "ui/views/metadata/metadata_impl_macros.h"
namespace ash {
......@@ -46,10 +47,6 @@ LogoViewImpl::~LogoViewImpl() {
state_animator_.StopAnimator();
}
const char* LogoViewImpl::GetClassName() const {
return "LogoViewImpl";
}
void LogoViewImpl::SetState(LogoView::State state, bool animate) {
StateModel::State animator_state;
switch (state) {
......@@ -224,4 +221,7 @@ void LogoViewImpl::VisibilityChanged(views::View* starting_from,
state_animator_.StopAnimator();
}
BEGIN_METADATA(LogoViewImpl, LogoView)
END_METADATA
} // namespace ash
......@@ -18,6 +18,7 @@
#include "chromeos/assistant/internal/logo_view/state_model.h"
#include "third_party/skia/include/core/SkColor.h"
#include "ui/compositor/compositor_animation_observer.h"
#include "ui/views/metadata/metadata_header_macros.h"
namespace chromeos {
namespace assistant {
......@@ -47,16 +48,18 @@ class LogoViewImpl : public LogoView,
public chromeos::assistant::StateAnimatorTimerDelegate,
public ui::CompositorAnimationObserver {
public:
METADATA_HEADER(LogoViewImpl);
using Dot = chromeos::assistant::Dot;
using Logo = chromeos::assistant::Logo;
using StateAnimator = chromeos::assistant::StateAnimator;
using StateModel = chromeos::assistant::StateModel;
LogoViewImpl();
LogoViewImpl(const LogoViewImpl&) = delete;
LogoViewImpl& operator=(const LogoViewImpl&) = delete;
~LogoViewImpl() override;
// LogoView:
const char* GetClassName() const override;
void SetState(State state, bool animate) override;
void SetSpeechLevel(float speech_level) override;
......@@ -98,8 +101,6 @@ class LogoViewImpl : public LogoView,
chromeos::assistant::SoundLevelInputValueProvider
sound_level_input_value_provider_;
DISALLOW_COPY_AND_ASSIGN(LogoViewImpl);
};
} // namespace ash
......
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