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

Unified Diff: ui/events/ozone/layout/xkb/xkb_keyboard_layout_engine.h

Issue 823633003: Revert of ozone: xkb: Load keymaps on worker thread & cache them (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 11 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
« no previous file with comments | « ui/events/ozone/layout/xkb/scoped_xkb.h ('k') | ui/events/ozone/layout/xkb/xkb_keyboard_layout_engine.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ui/events/ozone/layout/xkb/xkb_keyboard_layout_engine.h
diff --git a/ui/events/ozone/layout/xkb/xkb_keyboard_layout_engine.h b/ui/events/ozone/layout/xkb/xkb_keyboard_layout_engine.h
index 8281b68af27c4fbdf6d1d471b00c64edc595d12a..d7a98545d3a435c884854f069798f9b72bcc1b4d 100644
--- a/ui/events/ozone/layout/xkb/xkb_keyboard_layout_engine.h
+++ b/ui/events/ozone/layout/xkb/xkb_keyboard_layout_engine.h
@@ -6,14 +6,10 @@
#define UI_EVENTS_OZONE_LAYOUT_XKB_XKB_KEYBOARD_LAYOUT_ENGINE_H_
#include <xkbcommon/xkbcommon.h>
-#include <vector>
#include "base/containers/hash_tables.h"
-#include "base/memory/ref_counted.h"
#include "base/memory/scoped_ptr.h"
-#include "base/memory/weak_ptr.h"
#include "base/strings/string16.h"
-#include "base/task_runner.h"
#include "ui/events/ozone/layout/events_ozone_layout_export.h"
#include "ui/events/ozone/layout/keyboard_layout_engine.h"
#include "ui/events/ozone/layout/xkb/scoped_xkb.h"
@@ -41,10 +37,6 @@
KeyboardCode* key_code,
uint32* platform_keycode) const override;
- // Gets the names of the RMLO rule for libxkbcommon.
- // Makes it protected for testing.
- scoped_ptr<xkb_rule_names> GetXkbRuleNames(const std::string& layout_name);
-
protected:
// Table for EventFlagsToXkbFlags().
struct XkbFlagMapEntry {
@@ -68,11 +60,6 @@
const XkbKeyCodeConverter& key_code_converter_;
private:
- struct XkbKeymapEntry {
- std::string layout_name;
- xkb_keymap* keymap;
- };
- std::vector<XkbKeymapEntry> xkb_keymaps_;
// Sets a new XKB keymap. This updates xkb_state_ (which takes ownership
// of the keymap), and updates xkb_flag_map_ for the new keymap.
void SetKeymap(xkb_keymap* keymap);
@@ -95,19 +82,10 @@
base::char16 base_character,
int ui_flags) const;
- // Callback when keymap file is loaded complete.
- void OnKeymapLoaded(const std::string& layout_name,
- scoped_ptr<xkb_keymap, XkbKeymapDeleter> keymap);
-
// libxkbcommon uses explicit reference counting for its structures,
// so we need to trigger its cleanup.
scoped_ptr<xkb_context, XkbContextDeleter> xkb_context_;
scoped_ptr<xkb_state, XkbStateDeleter> xkb_state_;
-
- std::string current_layout_name_;
-
- // Support weak pointers for attach & detach callbacks.
- base::WeakPtrFactory<XkbKeyboardLayoutEngine> weak_ptr_factory_;
};
} // namespace ui
« no previous file with comments | « ui/events/ozone/layout/xkb/scoped_xkb.h ('k') | ui/events/ozone/layout/xkb/xkb_keyboard_layout_engine.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698