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

Unified Diff: chromeos/ime/mock_ime_property_handler.h

Issue 23822002: Adding new mock classes for input method handlers (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 years, 4 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 side-by-side diff with in-line comments
Download patch
Index: chromeos/ime/mock_ime_property_handler.h
diff --git a/chromeos/ime/mock_ime_property_handler.h b/chromeos/ime/mock_ime_property_handler.h
new file mode 100644
index 0000000000000000000000000000000000000000..fdac268f13e2eb54d4960e2be54863c44e6b75d9
--- /dev/null
+++ b/chromeos/ime/mock_ime_property_handler.h
@@ -0,0 +1,40 @@
+// Copyright 2013 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 CHROMEOS_IME_MOCK_IME_PROPERTY_HANDLER_H_
+#define CHROMEOS_IME_MOCK_IME_PROPERTY_HANDLER_H_
+
+#include "chromeos/dbus/ibus/ibus_property.h"
+#include "chromeos/ime/ibus_bridge.h"
+
+namespace chromeos {
+
+class CHROMEOS_EXPORT MockPropertyHandler :
+ public IBusPanelPropertyHandlerInterface {
+ public:
+ MockPropertyHandler();
+ virtual ~MockPropertyHandler();
+
+ virtual void RegisterProperties(const IBusPropertyList& properties) OVERRIDE;
+ virtual void UpdateProperty(const IBusProperty& property) OVERRIDE;
+
+ int register_properties_call_count() {
+ return register_properties_call_count_;
+ }
+
+ const IBusPropertyList& last_registered_properties() {
+ return last_registered_properties_;
+ }
+
+ // Resets all call count.
+ void Reset();
+
+ private:
+ int register_properties_call_count_;
+ IBusPropertyList last_registered_properties_;
+};
+
+} // namespace chromeos
+
+#endif // CHROMEOS_IME_MOCK_IME_PROPERTY_HANDLER_H_

Powered by Google App Engine
This is Rietveld 408576698