Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(478)

Unified Diff: ui/ozone/platform/wayland/wayland_display.h

Issue 2147523003: Rename WaylandDisplay to WaylandConnection (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: add argument name Created 4 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: ui/ozone/platform/wayland/wayland_display.h
diff --git a/ui/ozone/platform/wayland/wayland_display.h b/ui/ozone/platform/wayland/wayland_display.h
deleted file mode 100644
index d63945a8a69050d9af00fc92489600ac0ddede6b..0000000000000000000000000000000000000000
--- a/ui/ozone/platform/wayland/wayland_display.h
+++ /dev/null
@@ -1,87 +0,0 @@
-// Copyright 2016 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.
-
-#ifndef UI_OZONE_PLATFORM_WAYLAND_WAYLAND_DISPLAY_H_
-#define UI_OZONE_PLATFORM_WAYLAND_WAYLAND_DISPLAY_H_
-
-#include <map>
-
-#include "base/message_loop/message_pump_libevent.h"
-#include "ui/events/platform/platform_event_source.h"
-#include "ui/gfx/native_widget_types.h"
-#include "ui/ozone/platform/wayland/wayland_object.h"
-#include "ui/ozone/platform/wayland/wayland_pointer.h"
-
-namespace ui {
-
-class WaylandWindow;
-
-class WaylandDisplay : public PlatformEventSource,
- public base::MessagePumpLibevent::Watcher {
- public:
- WaylandDisplay();
- ~WaylandDisplay() override;
-
- bool Initialize();
- bool StartProcessingEvents();
-
- // Schedules a flush of the Wayland connection.
- void ScheduleFlush();
-
- wl_display* display() { return display_.get(); }
- wl_compositor* compositor() { return compositor_.get(); }
- wl_shm* shm() { return shm_.get(); }
- xdg_shell* shell() { return shell_.get(); }
-
- WaylandWindow* GetWindow(gfx::AcceleratedWidget widget);
- void AddWindow(gfx::AcceleratedWidget widget, WaylandWindow* window);
- void RemoveWindow(gfx::AcceleratedWidget widget);
-
- private:
- void Flush();
- void DispatchUiEvent(Event* event);
-
- // PlatformEventSource
- void OnDispatcherListChanged() override;
-
- // base::MessagePumpLibevent::Watcher
- void OnFileCanReadWithoutBlocking(int fd) override;
- void OnFileCanWriteWithoutBlocking(int fd) override;
-
- // wl_registry_listener
- static void Global(void* data,
- wl_registry* registry,
- uint32_t name,
- const char* interface,
- uint32_t version);
- static void GlobalRemove(void* data, wl_registry* registry, uint32_t name);
-
- // wl_seat_listener
- static void Capabilities(void* data, wl_seat* seat, uint32_t capabilities);
- static void Name(void* data, wl_seat* seat, const char* name);
-
- // xdg_shell_listener
- static void Ping(void* data, xdg_shell* shell, uint32_t serial);
-
- std::map<gfx::AcceleratedWidget, WaylandWindow*> window_map_;
-
- wl::Object<wl_display> display_;
- wl::Object<wl_registry> registry_;
- wl::Object<wl_compositor> compositor_;
- wl::Object<wl_seat> seat_;
- wl::Object<wl_shm> shm_;
- wl::Object<xdg_shell> shell_;
-
- std::unique_ptr<WaylandPointer> pointer_;
-
- bool scheduled_flush_ = false;
- bool watching_ = false;
- base::MessagePumpLibevent::FileDescriptorWatcher controller_;
-
- DISALLOW_COPY_AND_ASSIGN(WaylandDisplay);
-};
-
-} // namespace ui
-
-#endif // UI_OZONE_PLATFORM_WAYLAND_WAYLAND_DISPLAY_H_
« no previous file with comments | « ui/ozone/platform/wayland/wayland_connection_unittest.cc ('k') | ui/ozone/platform/wayland/wayland_display.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698