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

Side by Side Diff: content/renderer/font_access/web_font_access_impl.h

Issue 1615133002: Implement API for accessing fonts installed locally on the system. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Addressing Nasko. Created 4 years, 10 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 unified diff | Download patch
« no previous file with comments | « content/content_tests.gypi ('k') | content/renderer/font_access/web_font_access_impl.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
(Empty)
1 // Copyright 2016 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
4
5 #ifndef CONTENT_RENDERER_FONT_ACCESS_WEB_FONT_ACCESS_IMPL_H_
6 #define CONTENT_RENDERER_FONT_ACCESS_WEB_FONT_ACCESS_IMPL_H_
7
8 #include "base/compiler_specific.h"
9 #include "content/common/content_export.h"
10 #include "content/common/font_access/font_access_service.mojom.h"
11 #include "mojo/public/cpp/bindings/lib/buffer.h"
12 #include "third_party/WebKit/public/platform/modules/font_access/WebFontAccess.h "
13
14 namespace content {
15
16 class CONTENT_EXPORT WebFontAccessImpl final
17 : NON_EXPORTED_BASE(public blink::WebFontAccess) {
18 public:
19 WebFontAccessImpl();
20 ~WebFontAccessImpl() override;
21
22 void getFonts(blink::FontAccessCallbacks*) override;
23 void getFontWebData(const blink::WebString& family,
24 const blink::WebString& style,
25 blink::FontDataCallbacks*) override;
26
27 private:
28 void FontListHasLoaded(scoped_ptr<blink::FontAccessCallbacks> callbacks,
29 mojo::Array<FontDescriptionPtr> fonts);
30 void FontDataHasLoaded(scoped_ptr<blink::FontDataCallbacks> callbacks,
31 mojo::ScopedSharedBufferHandle handle,
32 uint64_t size);
33
34 FontAccessServicePtr& GetService();
35
36 FontAccessServicePtr provider_;
37
38 DISALLOW_COPY_AND_ASSIGN(WebFontAccessImpl);
39 };
40
41 } // namespace content
42
43 #endif // CONTENT_RENDERER_FONT_ACCESS_WEB_FONT_ACCESS_IMPL_H_
OLDNEW
« no previous file with comments | « content/content_tests.gypi ('k') | content/renderer/font_access/web_font_access_impl.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698