From e956e80c1fa1cc8aefcb1533e5acf5cf3c8ffdd9 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?R=C3=A9mi=20Verschelde?= Date: Sun, 10 May 2020 12:56:01 +0200 Subject: Style: clang-format: Disable AllowShortIfStatementsOnASingleLine Part of #33027, also discussed in #29848. Enforcing the use of brackets even on single line statements would be preferred, but `clang-format` doesn't have this functionality yet. --- platform/windows/display_server_windows.cpp | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) (limited to 'platform/windows/display_server_windows.cpp') diff --git a/platform/windows/display_server_windows.cpp b/platform/windows/display_server_windows.cpp index 701cf69207..5063a0929a 100644 --- a/platform/windows/display_server_windows.cpp +++ b/platform/windows/display_server_windows.cpp @@ -677,7 +677,8 @@ void DisplayServerWindows::window_set_position(const Point2i &p_position, Window ERR_FAIL_COND(!windows.has(p_window)); WindowData &wd = windows[p_window]; - if (wd.fullscreen) return; + if (wd.fullscreen) + return; #if 0 //wrong needs to account properly for decorations RECT r; @@ -1474,19 +1475,22 @@ DisplayServer::LatinKeyboardVariant DisplayServerWindows::get_latin_keyboard_var int i = 0; while (azerty[i] != 0) { - if (azerty[i] == hex) return LATIN_KEYBOARD_AZERTY; + if (azerty[i] == hex) + return LATIN_KEYBOARD_AZERTY; i++; } i = 0; while (qwertz[i] != 0) { - if (qwertz[i] == hex) return LATIN_KEYBOARD_QWERTZ; + if (qwertz[i] == hex) + return LATIN_KEYBOARD_QWERTZ; i++; } i = 0; while (dvorak[i] != 0) { - if (dvorak[i] == hex) return LATIN_KEYBOARD_DVORAK; + if (dvorak[i] == hex) + return LATIN_KEYBOARD_DVORAK; i++; } -- cgit v1.2.3 From 69de7ce38c40c57a1fabe12c9e5a3eab903a4035 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?R=C3=A9mi=20Verschelde?= Date: Sun, 10 May 2020 13:00:47 +0200 Subject: Style: clang-format: Disable AllowShortCaseLabelsOnASingleLine Part of #33027. --- platform/windows/display_server_windows.cpp | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'platform/windows/display_server_windows.cpp') diff --git a/platform/windows/display_server_windows.cpp b/platform/windows/display_server_windows.cpp index 5063a0929a..e794efb4fb 100644 --- a/platform/windows/display_server_windows.cpp +++ b/platform/windows/display_server_windows.cpp @@ -1058,7 +1058,8 @@ void DisplayServerWindows::window_set_flag(WindowFlags p_flag, bool p_enabled, W wd.no_focus = p_enabled; _update_window_style(p_window); } break; - case WINDOW_FLAG_MAX: break; + case WINDOW_FLAG_MAX: + break; } } @@ -1089,7 +1090,8 @@ bool DisplayServerWindows::window_get_flag(WindowFlags p_flag, WindowID p_window return wd.no_focus; } break; - case WINDOW_FLAG_MAX: break; + case WINDOW_FLAG_MAX: + break; } return false; -- cgit v1.2.3