blob: 33d51d70cf66b5da00b244cb2f7a7969025d27eb [file] [log] [blame]
// Copyright 2020 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/platform_window/extensions/wayland_extension.h"
#include "ui/base/class_property.h"
#include "ui/platform_window/platform_window.h"
DEFINE_UI_CLASS_PROPERTY_TYPE(ui::WaylandExtension*)
namespace ui {
DEFINE_UI_CLASS_PROPERTY_KEY(WaylandExtension*, kWaylandExtensionKey, nullptr)
WaylandExtension::~WaylandExtension() = default;
void WaylandExtension::SetWaylandExtension(PlatformWindow* window,
WaylandExtension* extension) {
window->SetProperty(kWaylandExtensionKey, extension);
}
WaylandExtension* GetWaylandExtension(const PlatformWindow& window) {
return window.GetProperty(kWaylandExtensionKey);
}
} // namespace ui