Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'source/blender/editors')
-rw-r--r--source/blender/editors/interface/interface_templates.c21
1 files changed, 11 insertions, 10 deletions
diff --git a/source/blender/editors/interface/interface_templates.c b/source/blender/editors/interface/interface_templates.c
index 041dc56cf92..43824c59af4 100644
--- a/source/blender/editors/interface/interface_templates.c
+++ b/source/blender/editors/interface/interface_templates.c
@@ -4309,22 +4309,23 @@ void uiTemplateInputStatus(uiLayout *layout, struct bContext *C)
/* Otherwise should cursor keymap status. */
for (int i = 0; i < 3; i++) {
- uiLayout *box = uiLayoutRow(layout, true);
+ uiLayout *box = uiLayoutRow(layout, false);
+ uiLayout *col = uiLayoutColumn(box, false);
+ uiLayout *row = uiLayoutRow(col, true);
+ uiLayoutSetAlignment(row, UI_LAYOUT_ALIGN_LEFT);
const char *msg = WM_window_cursor_keymap_status_get(win, i, 0);
const char *msg_drag = WM_window_cursor_keymap_status_get(win, i, 1);
- if (msg || msg_drag) {
- uiItemL(box, msg ? msg : "", (ICON_MOUSE_LMB + i));
+ uiItemL(row, msg ? msg : "", (ICON_MOUSE_LMB + i));
- if (msg_drag) {
- uiItemL(box, msg_drag, ICON_MOUSE_DRAG);
- }
-
- if (i != 2) {
- uiItemS(layout);
- }
+ if (msg_drag) {
+ uiItemL(row, msg_drag, ICON_MOUSE_DRAG);
}
+
+ /* Use trick with empty string to keep icons in same position. */
+ row = uiLayoutRow(col, false);
+ uiItemL(row, " ", ICON_NONE);
}
}