12a99a7e74a7f215066514fe81d2bfa6639d9edddTorne (Richard Coles)// Copyright (c) 2012 The Chromium Authors. All rights reserved.
22a99a7e74a7f215066514fe81d2bfa6639d9edddTorne (Richard Coles)// Use of this source code is governed by a BSD-style license that can be
32a99a7e74a7f215066514fe81d2bfa6639d9edddTorne (Richard Coles)// found in the LICENSE file.
42a99a7e74a7f215066514fe81d2bfa6639d9edddTorne (Richard Coles)
52a99a7e74a7f215066514fe81d2bfa6639d9edddTorne (Richard Coles)#ifndef CHROME_BROWSER_CHROMEOS_INPUT_METHOD_INPUT_METHOD_CONFIGURATION_H_
62a99a7e74a7f215066514fe81d2bfa6639d9edddTorne (Richard Coles)#define CHROME_BROWSER_CHROMEOS_INPUT_METHOD_INPUT_METHOD_CONFIGURATION_H_
72a99a7e74a7f215066514fe81d2bfa6639d9edddTorne (Richard Coles)
82a99a7e74a7f215066514fe81d2bfa6639d9edddTorne (Richard Coles)#include "base/sequenced_task_runner.h"
92a99a7e74a7f215066514fe81d2bfa6639d9edddTorne (Richard Coles)
102a99a7e74a7f215066514fe81d2bfa6639d9edddTorne (Richard Coles)namespace chromeos {
112a99a7e74a7f215066514fe81d2bfa6639d9edddTorne (Richard Coles)namespace input_method {
122a99a7e74a7f215066514fe81d2bfa6639d9edddTorne (Richard Coles)
132a99a7e74a7f215066514fe81d2bfa6639d9edddTorne (Richard Coles)class InputMethodManager;
142a99a7e74a7f215066514fe81d2bfa6639d9edddTorne (Richard Coles)
152a99a7e74a7f215066514fe81d2bfa6639d9edddTorne (Richard Coles)// Initializes the InputMethodManager. Must be called before any calls to
162a99a7e74a7f215066514fe81d2bfa6639d9edddTorne (Richard Coles)// GetInstance(). We explicitly initialize and shut down the global instance,
172a99a7e74a7f215066514fe81d2bfa6639d9edddTorne (Richard Coles)// rather than making it a Singleton, to ensure clean startup and shutdown.
185f1c94371a64b3196d4be9466099bb892df9b88eTorne (Richard Coles)void Initialize();
192a99a7e74a7f215066514fe81d2bfa6639d9edddTorne (Richard Coles)
202a99a7e74a7f215066514fe81d2bfa6639d9edddTorne (Richard Coles)// Similar to Initialize(), but can inject an alternative
212a99a7e74a7f215066514fe81d2bfa6639d9edddTorne (Richard Coles)// InputMethodManager such as MockInputMethodManager for testing.
222a99a7e74a7f215066514fe81d2bfa6639d9edddTorne (Richard Coles)// The injected object will be owned by the internal pointer and deleted
232a99a7e74a7f215066514fe81d2bfa6639d9edddTorne (Richard Coles)// by Shutdown().
24b2df76ea8fec9e32f6f3718986dba0d95315b29cTorne (Richard Coles)// TODO(nona): Remove this and use InputMethodManager::Initialize instead.
252a99a7e74a7f215066514fe81d2bfa6639d9edddTorne (Richard Coles)void InitializeForTesting(InputMethodManager* mock_manager);
262a99a7e74a7f215066514fe81d2bfa6639d9edddTorne (Richard Coles)
276e8cce623b6e4fe0c9e4af605d675dd9d0338c38Torne (Richard Coles)// Disables the IME extension loading (e.g. for browser tests).
286e8cce623b6e4fe0c9e4af605d675dd9d0338c38Torne (Richard Coles)void DisableExtensionLoading();
296e8cce623b6e4fe0c9e4af605d675dd9d0338c38Torne (Richard Coles)
302a99a7e74a7f215066514fe81d2bfa6639d9edddTorne (Richard Coles)// Destroys the global InputMethodManager instance.
312a99a7e74a7f215066514fe81d2bfa6639d9edddTorne (Richard Coles)void Shutdown();
322a99a7e74a7f215066514fe81d2bfa6639d9edddTorne (Richard Coles)
332a99a7e74a7f215066514fe81d2bfa6639d9edddTorne (Richard Coles)}  // namespace input_method
342a99a7e74a7f215066514fe81d2bfa6639d9edddTorne (Richard Coles)}  // namespace chromeos
352a99a7e74a7f215066514fe81d2bfa6639d9edddTorne (Richard Coles)
362a99a7e74a7f215066514fe81d2bfa6639d9edddTorne (Richard Coles)#endif  // CHROME_BROWSER_CHROMEOS_INPUT_METHOD_INPUT_METHOD_CONFIGURATION_H_
37