summaryrefslogblamecommitdiff
path: root/www-client/chromium/files/chromium-91-clipboard-ozone.patch
blob: 5aac0eeead109b957a7355c426838ed4e3b76e4b (plain) (tree)















































                                                                                                        
diff --git a/ui/base/clipboard/clipboard_factory_ozone.cc b/ui/base/clipboard/clipboard_factory_ozone.cc
index e2a061df8..5463e6bf9 100644
--- a/ui/base/clipboard/clipboard_factory_ozone.cc
+++ b/ui/base/clipboard/clipboard_factory_ozone.cc
@@ -50,7 +50,8 @@ Clipboard* Clipboard::Create() {
 #if defined(USE_X11) && BUILDFLAG(IS_CHROMEOS_LACROS)
   NOTREACHED() << "System clipboard integration should be in place.";
 #endif
-  return new ClipboardNonBacked;
+  return nullptr;
+  //return new ClipboardNonBacked;
 }
 
 }  // namespace ui
diff --git a/ui/base/clipboard/clipboard_non_backed.cc b/ui/base/clipboard/clipboard_non_backed.cc
index a6e85cd2f..734c7e961 100644
--- a/ui/base/clipboard/clipboard_non_backed.cc
+++ b/ui/base/clipboard/clipboard_non_backed.cc
@@ -688,6 +688,7 @@ void ClipboardNonBacked::ReadData(const ClipboardFormatType& format,
 #endif
 }
 
+#if defined(USE_OZONE)
 bool ClipboardNonBacked::IsSelectionBufferAvailable() const {
 #if BUILDFLAG(IS_CHROMEOS_ASH)
   return false;
@@ -695,6 +696,7 @@ bool ClipboardNonBacked::IsSelectionBufferAvailable() const {
   return true;
 #endif
 }
+#endif  // defined(USE_OZONE)
 
 void ClipboardNonBacked::WritePortableRepresentations(
     ClipboardBuffer buffer,
diff --git a/ui/base/clipboard/clipboard_non_backed.h b/ui/base/clipboard/clipboard_non_backed.h
index d14ff0ff6..702f02a84 100644
--- a/ui/base/clipboard/clipboard_non_backed.h
+++ b/ui/base/clipboard/clipboard_non_backed.h
@@ -97,7 +97,9 @@ class COMPONENT_EXPORT(UI_BASE_CLIPBOARD) ClipboardNonBacked
   void ReadData(const ClipboardFormatType& format,
                 const DataTransferEndpoint* data_dst,
                 std::string* result) const override;
+#if defined(USE_OZONE)
   bool IsSelectionBufferAvailable() const override;
+#endif  // defined(USE_OZONE)
   void WritePortableRepresentations(
       ClipboardBuffer buffer,
       const ObjectMap& objects,