blob: 5eb1673a60aa6655b81d7eba52566dc9727ddbc8 [file] [log] [blame]
/*
Copyright (C) 2008 Nokia Corporation and/or its subsidiary(-ies)
This library is free software; you can redistribute it and/or
modify it under the terms of the GNU Library General Public
License as published by the Free Software Foundation; either
version 2 of the License, or (at your option) any later version.
This library is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
Library General Public License for more details.
You should have received a copy of the GNU Library General Public License
along with this library; see the file COPYING.LIB. If not, write to
the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
Boston, MA 02110-1301, USA.
*/
#ifndef THIRD_PARTY_BLINK_RENDERER_CORE_FRAME_NAVIGATOR_H_
#define THIRD_PARTY_BLINK_RENDERER_CORE_FRAME_NAVIGATOR_H_
#include "third_party/blink/public/common/user_agent/user_agent_metadata.h"
#include "third_party/blink/renderer/core/core_export.h"
#include "third_party/blink/renderer/core/execution_context/navigator_base.h"
#include "third_party/blink/renderer/platform/heap/handle.h"
#include "third_party/blink/renderer/platform/supplementable.h"
#include "third_party/blink/renderer/platform/wtf/forward.h"
namespace blink {
class CORE_EXPORT Navigator final : public NavigatorBase,
public Supplementable<Navigator> {
DEFINE_WRAPPERTYPEINFO();
public:
explicit Navigator(ExecutionContext*);
// NavigatorCookies
bool cookieEnabled() const;
bool webdriver() const {
return RuntimeEnabledFeatures::AutomationControlledEnabled();
}
String productSub() const;
String vendor() const;
String vendorSub() const;
String platform() const override;
String GetAcceptLanguages() override;
void SetUserAgentMetadataForTesting(UserAgentMetadata);
void Trace(Visitor*) const override;
private:
UserAgentMetadata metadata_;
};
} // namespace blink
#endif // THIRD_PARTY_BLINK_RENDERER_CORE_FRAME_NAVIGATOR_H_