diff options
author | Lars Knoll <lars.knoll@qt.io> | 2016-08-18 22:25:08 +0200 |
---|---|---|
committer | Lars Knoll <lars.knoll@qt.io> | 2016-08-19 04:27:29 +0000 |
commit | 56ee007b3f44eb3276b244a630f55482c2b02228 (patch) | |
tree | 349a978e664592f51d26563603219e5a537d3cfc /src/plugins/platforms/xcb/qxcbkeyboard.cpp | |
parent | 606924132ff1f11b9d7b4357251f07ccabb8bdb6 (diff) |
Rework privateFeature
privateFeature would add QT_NO_FEATURE to the DEFINES in the private
.pri file, which was somewhat inelegant.
Additionally, it would add the feature to the _public_ QT_CONFIG
variable, which was plain wrong.
Replace the implementation with the one just introduced for
publicFeature, with the difference that the features are written to the
private files instead.
As this entirely disposes of the old system, all usages in the project
files need to be replaced atomically as well.
Change-Id: I506b5d41054410659ea503bc6901736cd5edec6e
Reviewed-by: Lars Knoll <lars.knoll@qt.io>
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
Diffstat (limited to 'src/plugins/platforms/xcb/qxcbkeyboard.cpp')
-rw-r--r-- | src/plugins/platforms/xcb/qxcbkeyboard.cpp | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/src/plugins/platforms/xcb/qxcbkeyboard.cpp b/src/plugins/platforms/xcb/qxcbkeyboard.cpp index 811ef4251a..07932ceeb8 100644 --- a/src/plugins/platforms/xcb/qxcbkeyboard.cpp +++ b/src/plugins/platforms/xcb/qxcbkeyboard.cpp @@ -711,7 +711,7 @@ void QXcbKeyboard::updateKeymap() xkb_keymap = 0; struct xkb_state *new_state = 0; -#ifndef QT_NO_XKB +#if QT_CONFIG(xkb) if (connection()->hasXKB()) { xkb_keymap = xkb_x11_keymap_new_from_device(xkb_context, xcb_connection(), core_device_id, (xkb_keymap_compile_flags)0); if (xkb_keymap) { @@ -754,7 +754,7 @@ void QXcbKeyboard::updateKeymap() checkForLatinLayout(); } -#ifndef QT_NO_XKB +#if QT_CONFIG(xkb) void QXcbKeyboard::updateXKBState(xcb_xkb_state_notify_event_t *state) { if (m_config && connection()->hasXKB()) { @@ -1140,7 +1140,7 @@ QXcbKeyboard::QXcbKeyboard(QXcbConnection *connection) , m_hasLatinLayout(false) { memset(&xkb_names, 0, sizeof(xkb_names)); -#ifndef QT_NO_XKB +#if QT_CONFIG(xkb) core_device_id = 0; if (connection->hasXKB()) { updateVModMapping(); @@ -1154,7 +1154,7 @@ QXcbKeyboard::QXcbKeyboard(QXcbConnection *connection) #endif m_key_symbols = xcb_key_symbols_alloc(xcb_connection()); updateModifiers(); -#ifndef QT_NO_XKB +#if QT_CONFIG(xkb) } #endif updateKeymap(); @@ -1173,7 +1173,7 @@ QXcbKeyboard::~QXcbKeyboard() void QXcbKeyboard::updateVModMapping() { -#ifndef QT_NO_XKB +#if QT_CONFIG(xkb) xcb_xkb_get_names_cookie_t names_cookie; xcb_xkb_get_names_reply_t *name_reply; xcb_xkb_get_names_value_list_t names_list; @@ -1242,7 +1242,7 @@ void QXcbKeyboard::updateVModMapping() void QXcbKeyboard::updateVModToRModMapping() { -#ifndef QT_NO_XKB +#if QT_CONFIG(xkb) xcb_xkb_get_map_cookie_t map_cookie; xcb_xkb_get_map_reply_t *map_reply; xcb_xkb_get_map_map_t map; |