Chromium Code Reviews| Index: content/browser/renderer_host/fontmgr_message_filter.h |
| =================================================================== |
| --- content/browser/renderer_host/fontmgr_message_filter.h (revision 0) |
| +++ content/browser/renderer_host/fontmgr_message_filter.h (working copy) |
| @@ -0,0 +1,66 @@ |
| +// Copyright (c) 2012 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 CONTENT_BROWSER_RENDERER_HOST_FONTMGR_MESSAGE_FILTER_H_ |
| +#define CONTENT_BROWSER_RENDERER_HOST_FONTMGR_MESSAGE_FILTER_H_ |
| + |
| +#include <string> |
| +#include <vector> |
| + |
| +#include "base/basictypes.h" |
| +#include "content/public/browser/browser_message_filter.h" |
| +#include "skia/ext/refptr.h" |
| +#include "third_party/skia/include/core/SkString.h" |
| +#include "third_party/skia/include/ports/SkFontStyle.h" |
| + |
| +struct SkFontIdentity; |
| + |
| +class SkDataTable; |
| +class SkRemotableFontIdentitySet; |
| +class SkRemotableFontMgr; |
| +class SkStream; |
| + |
| +namespace content { |
| + |
| +class FontMgrMessageFilter : public BrowserMessageFilter { |
| + public: |
| + FontMgrMessageFilter(SkRemotableFontMgr*); |
| + |
| + virtual bool OnMessageReceived(const IPC::Message& message, |
| + bool* message_was_ok) OVERRIDE; |
| + private: |
| + virtual ~FontMgrMessageFilter(); |
| + |
| + void OnFontMsg_GetFamilyNames(skia::RefPtr<SkDataTable>* familyNames); |
| + |
|
brettw
2014/03/11 21:38:15
I usually don't add blank lines in between IPC mes
bungeman-chromium
2014/03/13 22:33:31
Since almost all of these are multi-line, I find i
|
| + void OnFontMsg_GetIndexIdentities( |
| + int familyIndex, |
|
brettw
2014/03/11 21:38:15
Args should use Chrome-style throughout (family_in
bungeman-chromium
2014/03/13 22:33:31
Done.
|
| + skia::RefPtr<SkRemotableFontIdentitySet>* styles); |
| + |
| + void OnFontMsg_MatchIndexStyle(int familyIndex, SkFontStyle, SkFontIdentity*); |
| + |
| + void OnFontMsg_MatchName(SkString familyName, |
| + skia::RefPtr<SkRemotableFontIdentitySet>* styles); |
| + |
| + void OnFontMsg_MatchNameStyle(SkString familyName, |
| + SkFontStyle, |
|
brettw
2014/03/11 21:38:15
We usually name these args.
bungeman-chromium
2014/03/13 22:33:31
Done. Arg, I always get confused because Blink exp
|
| + SkFontIdentity*); |
| + |
| + void OnFontMsg_MatchNameStyleCharacter(SkString familyName, |
| + SkFontStyle, |
| + SkString bpc47, |
| + uint32_t character, |
| + SkFontIdentity*); |
| + |
| + void OnFontMsg_GetData(uint32_t dataId, |
| + skia::RefPtr<SkStream>* fontData); |
| + |
| + DISALLOW_COPY_AND_ASSIGN(FontMgrMessageFilter); |
|
brettw
2014/03/11 21:38:15
This should be last.
bungeman-chromium
2014/03/13 22:33:31
Done.
|
| + |
| + skia::RefPtr<SkRemotableFontMgr> fm; |
| +}; |
| + |
| +} // namespace content |
| + |
| +#endif // CONTENT_BROWSER_RENDERER_HOST_CLIPBOARD_MESSAGE_FILTER_H_ |