Re-enable index-basics-workers test to see if still times
[chromium-blink-merge.git] / content / public / utility / utility_thread.h
blobcf2fe97393028b49b90481fc2668b7c9a92ef1d9
1 // Copyright (c) 2012 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.
5 #ifndef CONTENT_PUBLIC_UTILITY_UTILITY_THREAD_H_
6 #define CONTENT_PUBLIC_UTILITY_UTILITY_THREAD_H_
8 #include "base/basictypes.h"
9 #include "content/common/content_export.h"
10 #include "ipc/ipc_sender.h"
12 #if defined(OS_WIN)
13 #include <windows.h>
14 #endif
16 namespace content {
18 class CONTENT_EXPORT UtilityThread : public IPC::Sender {
19 public:
20 // Returns the one utility thread for this process. Note that this can only
21 // be accessed when running on the utility thread itself.
22 static UtilityThread* Get();
24 UtilityThread();
25 virtual ~UtilityThread();
27 // Releases the process if we are not (or no longer) in batch mode.
28 virtual void ReleaseProcessIfNeeded() = 0;
30 #if defined(OS_WIN)
31 // Request that the given font be loaded by the browser so it's cached by the
32 // OS. Please see ChildProcessHost::PreCacheFont for details.
33 virtual void PreCacheFont(const LOGFONT& log_font) = 0;
35 // Release cached font.
36 virtual void ReleaseCachedFonts() = 0;
37 #endif
40 } // namespace content
42 #endif // CONTENT_PUBLIC_UTILITY_UTILITY_THREAD_H_