blob: dccae839144b3bb247ec3e745f3b3904376d417c [file] [log] [blame]
// Copyright 2017 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 "chrome/browser/vr/model/toolbar_state.h"
namespace vr {
ToolbarState::ToolbarState()
: gurl(GURL()),
security_level(security_state::SecurityLevel::NONE),
vector_icon(nullptr),
should_display_url(true),
offline_page(false) {}
ToolbarState::ToolbarState(const GURL& url,
security_state::SecurityLevel level,
const gfx::VectorIcon* icon,
bool display_url,
bool offline)
: gurl(url),
security_level(level),
vector_icon(icon),
should_display_url(display_url),
offline_page(offline) {}
ToolbarState::ToolbarState(const ToolbarState& other) = default;
bool ToolbarState::operator==(const ToolbarState& other) const {
return (gurl == other.gurl && security_level == other.security_level &&
vector_icon == other.vector_icon &&
should_display_url == other.should_display_url &&
offline_page == other.offline_page);
}
bool ToolbarState::operator!=(const ToolbarState& other) const {
return !(*this == other);
}
} // namespace vr