diff options
author | Brecht Van Lommel <brechtvanlommel@gmail.com> | 2018-11-27 18:09:02 +0300 |
---|---|---|
committer | Brecht Van Lommel <brechtvanlommel@gmail.com> | 2018-11-28 13:36:13 +0300 |
commit | edbf15d3c044e719749b4874275c72b42838b00f (patch) | |
tree | 5fa404ffaf5c7c6ed0bdef2ccb625e1853b89352 /source/blender/blenkernel/intern/keyconfig.c | |
parent | 9c8d31520db6c675d05bdf41d21c89701088d99e (diff) |
Defaults: left click select is now the default.
A few reasons motivating this change:
* It works well for all devices: mouse, trackpad, and tablet pens.
* For beginners or users coming from other software, it's easier to get
started and avoids an initial stumbling block.
* Many users in 2.7 (about half?) were already using left click select, so
combined with the above advantages it makes for a practical default.
Note that we continue to support right click select, as many experienced
Blender users (and developers) see efficiency advantages in this approach.
The option to switch is in the first time setup splash screen, and in the
user preferences.
Diffstat (limited to 'source/blender/blenkernel/intern/keyconfig.c')
-rw-r--r-- | source/blender/blenkernel/intern/keyconfig.c | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/source/blender/blenkernel/intern/keyconfig.c b/source/blender/blenkernel/intern/keyconfig.c index 755c9e1582d..f2db375f3ec 100644 --- a/source/blender/blenkernel/intern/keyconfig.c +++ b/source/blender/blenkernel/intern/keyconfig.c @@ -120,4 +120,18 @@ void BKE_keyconfig_pref_type_free(void) global_keyconfigpreftype_hash = NULL; } +/* Set select mouse, for versioning code. */ +void BKE_keyconfig_pref_set_select_mouse(UserDef *userdef, int value, bool override) +{ + wmKeyConfigPref *kpt = BKE_keyconfig_pref_ensure(userdef, WM_KEYCONFIG_STR_DEFAULT); + IDProperty *idprop = IDP_GetPropertyFromGroup(kpt->prop, "select_mouse"); + if (!idprop) { + IDPropertyTemplate tmp = { .i = value }; + IDP_AddToGroup(kpt->prop, IDP_New(IDP_INT, &tmp, "select_mouse")); + } + else if (override) { + IDP_Int(idprop) = value; + } +} + /** \} */ |