Commit 170e9fbd authored by Olivier Yiptong's avatar Olivier Yiptong Committed by Commit Bot

FontAccess: Remove usage of DISALLOW_COPY_AND_ASSIGN

Given that DISALLOW_COPY_AND_ASSIGN is deprecated, using explicit
deletions instead.

Bug: 1043306
Change-Id: I1999fb65ef08d5ba89ce296f1a72504285b4c7b6
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2424659
Commit-Queue: Olivier Yiptong <oyiptong@chromium.org>
Auto-Submit: Olivier Yiptong <oyiptong@chromium.org>
Reviewed-by: default avatarJoshua Bell <jsbell@chromium.org>
Cr-Commit-Position: refs/heads/master@{#809991}
parent d9adaf63
...@@ -5,7 +5,6 @@ ...@@ -5,7 +5,6 @@
#ifndef CONTENT_BROWSER_FONT_ACCESS_FONT_ACCESS_MANAGER_IMPL_H_ #ifndef CONTENT_BROWSER_FONT_ACCESS_FONT_ACCESS_MANAGER_IMPL_H_
#define CONTENT_BROWSER_FONT_ACCESS_FONT_ACCESS_MANAGER_IMPL_H_ #define CONTENT_BROWSER_FONT_ACCESS_FONT_ACCESS_MANAGER_IMPL_H_
#include "base/macros.h"
#include "base/sequence_checker.h" #include "base/sequence_checker.h"
#include "content/common/content_export.h" #include "content/common/content_export.h"
#include "content/public/browser/global_routing_id.h" #include "content/public/browser/global_routing_id.h"
...@@ -21,6 +20,10 @@ class CONTENT_EXPORT FontAccessManagerImpl ...@@ -21,6 +20,10 @@ class CONTENT_EXPORT FontAccessManagerImpl
FontAccessManagerImpl(); FontAccessManagerImpl();
~FontAccessManagerImpl() override; ~FontAccessManagerImpl() override;
// Disallow copy and assign.
FontAccessManagerImpl(const FontAccessManagerImpl&) = delete;
FontAccessManagerImpl operator=(const FontAccessManagerImpl&) = delete;
struct BindingContext { struct BindingContext {
BindingContext(const url::Origin& origin, GlobalFrameRoutingId frame_id) BindingContext(const url::Origin& origin, GlobalFrameRoutingId frame_id)
: origin(origin), frame_id(frame_id) {} : origin(origin), frame_id(frame_id) {}
...@@ -45,7 +48,6 @@ class CONTENT_EXPORT FontAccessManagerImpl ...@@ -45,7 +48,6 @@ class CONTENT_EXPORT FontAccessManagerImpl
scoped_refptr<base::TaskRunner> results_task_runner_; scoped_refptr<base::TaskRunner> results_task_runner_;
SEQUENCE_CHECKER(sequence_checker_); SEQUENCE_CHECKER(sequence_checker_);
DISALLOW_COPY_AND_ASSIGN(FontAccessManagerImpl);
}; };
} // namespace content } // namespace content
......
...@@ -24,6 +24,12 @@ class CONTENT_EXPORT FontEnumerationCacheFontconfig ...@@ -24,6 +24,12 @@ class CONTENT_EXPORT FontEnumerationCacheFontconfig
FontEnumerationCacheFontconfig(); FontEnumerationCacheFontconfig();
~FontEnumerationCacheFontconfig(); ~FontEnumerationCacheFontconfig();
// Disallow copy and assign.
FontEnumerationCacheFontconfig(const FontEnumerationCacheFontconfig&) =
delete;
FontEnumerationCacheFontconfig operator=(
const FontEnumerationCacheFontconfig&) = delete;
static FontEnumerationCacheFontconfig* GetInstance(); static FontEnumerationCacheFontconfig* GetInstance();
protected: protected:
...@@ -37,8 +43,6 @@ class CONTENT_EXPORT FontEnumerationCacheFontconfig ...@@ -37,8 +43,6 @@ class CONTENT_EXPORT FontEnumerationCacheFontconfig
friend class FontEnumerationCache; friend class FontEnumerationCache;
void PrepareFontEnumerationCache(); void PrepareFontEnumerationCache();
DISALLOW_COPY_AND_ASSIGN(FontEnumerationCacheFontconfig);
}; };
} // namespace content } // namespace content
......
...@@ -25,7 +25,7 @@ class CONTENT_EXPORT FontEnumerationCacheMac : public FontEnumerationCache { ...@@ -25,7 +25,7 @@ class CONTENT_EXPORT FontEnumerationCacheMac : public FontEnumerationCache {
FontEnumerationCacheMac(); FontEnumerationCacheMac();
~FontEnumerationCacheMac(); ~FontEnumerationCacheMac();
// Disallow Copy and Assign // Disallow copy and assign.
FontEnumerationCacheMac(const FontEnumerationCacheMac&) = delete; FontEnumerationCacheMac(const FontEnumerationCacheMac&) = delete;
FontEnumerationCacheMac operator=(const FontEnumerationCacheMac&) = delete; FontEnumerationCacheMac operator=(const FontEnumerationCacheMac&) = delete;
......
...@@ -34,6 +34,10 @@ class CONTENT_EXPORT FontEnumerationCacheWin : public FontEnumerationCache { ...@@ -34,6 +34,10 @@ class CONTENT_EXPORT FontEnumerationCacheWin : public FontEnumerationCache {
FontEnumerationCacheWin(); FontEnumerationCacheWin();
~FontEnumerationCacheWin(); ~FontEnumerationCacheWin();
// Disallow copy and assign.
FontEnumerationCacheWin(const FontEnumerationCacheWin&) = delete;
FontEnumerationCacheWin operator=(const FontEnumerationCacheWin&) = delete;
// A data structure to hold font family results from DirectWrite. // A data structure to hold font family results from DirectWrite.
struct FamilyDataResult { struct FamilyDataResult {
std::vector<blink::FontEnumerationTable_FontMetadata> fonts; std::vector<blink::FontEnumerationTable_FontMetadata> fonts;
...@@ -70,8 +74,6 @@ class CONTENT_EXPORT FontEnumerationCacheWin : public FontEnumerationCache { ...@@ -70,8 +74,6 @@ class CONTENT_EXPORT FontEnumerationCacheWin : public FontEnumerationCache {
std::map<HRESULT, unsigned> enumeration_errors_; std::map<HRESULT, unsigned> enumeration_errors_;
std::unique_ptr<base::ElapsedTimer> enumeration_timer_; std::unique_ptr<base::ElapsedTimer> enumeration_timer_;
DISALLOW_COPY_AND_ASSIGN(FontEnumerationCacheWin);
}; };
} // namespace content } // namespace content
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment