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

Unified Diff: components/bookmarks/browser/bookmark_utils_unittest.cc

Issue 1892483005: SelectionOwner: add support for TIMESTAMP target (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: ugh Created 4 years, 8 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: components/bookmarks/browser/bookmark_utils_unittest.cc
diff --git a/components/bookmarks/browser/bookmark_utils_unittest.cc b/components/bookmarks/browser/bookmark_utils_unittest.cc
index f27676d8041dc392f055f221c33729b30bff869e..0587aed4162a9d86b4f3fbdbb549a091f647ade2 100644
--- a/components/bookmarks/browser/bookmark_utils_unittest.cc
+++ b/components/bookmarks/browser/bookmark_utils_unittest.cc
@@ -20,6 +20,11 @@
#include "ui/base/clipboard/clipboard.h"
#include "ui/base/clipboard/scoped_clipboard_writer.h"
+#if defined(USE_X11)
+#include "ui/events/platform/x11/x11_event_source_glib.h"
+#include "ui/gfx/x/x11_types.h"
+#endif // defined(USE_X11)
+
using base::ASCIIToUTF16;
using std::string;
@@ -31,7 +36,14 @@ class BookmarkUtilsTest : public testing::Test,
public:
BookmarkUtilsTest()
: grouped_changes_beginning_count_(0),
- grouped_changes_ended_count_(0) {}
+#if defined(USE_X11)
+ grouped_changes_ended_count_(0),
+ event_source_(gfx::GetXDisplay()) {
+ }
+#else
+ grouped_changes_ended_count_(0) {
+ }
+#endif // defined(USE_x11)
~BookmarkUtilsTest() override {}
// Copy and paste is not yet supported on iOS. http://crbug.com/228147
@@ -73,6 +85,11 @@ class BookmarkUtilsTest : public testing::Test,
// Clipboard requires a message loop.
base::MessageLoopForUI loop_;
+#if defined(USE_X11)
+ // On Linux, Clipboard also depends on an event source being present, to get
+ // the timestamp.
+ ui::X11EventSourceGlib event_source_;
dcheng 2016/04/20 00:55:26 I'm pretty sure the existing bookmark clipboard te
+#endif // defined(USE_X11)
DISALLOW_COPY_AND_ASSIGN(BookmarkUtilsTest);
};

Powered by Google App Engine
This is Rietveld 408576698