From d76e6273410100f4b301be1742a55968107d5795 Mon Sep 17 00:00:00 2001 From: Paul Cornett Date: Thu, 2 Nov 2017 08:56:29 -0700 Subject: [PATCH] More use of wxFALLTHROUGH --- src/gtk/settings.cpp | 8 ++++---- tests/datetime/datetimetest.cpp | 1 + 2 files changed, 5 insertions(+), 4 deletions(-) diff --git a/src/gtk/settings.cpp b/src/gtk/settings.cpp index 843a8a8834..afe2368633 100644 --- a/src/gtk/settings.cpp +++ b/src/gtk/settings.cpp @@ -354,7 +354,7 @@ static void bg(GtkStyleContext* sc, wxColour& color, int state = GTK_STATE_FLAG_ { case CAIRO_FORMAT_ARGB32: a = guchar(pixel >> 24); - // fallthrough + wxFALLTHROUGH; case CAIRO_FORMAT_RGB24: r = guchar(pixel >> 16); g = guchar(pixel >> 8); @@ -451,7 +451,7 @@ wxColour wxSystemSettingsNative::GetColour(wxSystemColour index) break; } #endif - // fall through + wxFALLTHROUGH; case wxSYS_COLOUR_3DLIGHT: case wxSYS_COLOUR_ACTIVEBORDER: case wxSYS_COLOUR_BTNFACE: @@ -491,7 +491,7 @@ wxColour wxSystemSettingsNative::GetColour(wxSystemColour index) break; } #endif - // fall through + wxFALLTHROUGH; case wxSYS_COLOUR_BTNTEXT: sc = ButtonLabelContext(path); fg(sc, color); @@ -505,7 +505,7 @@ wxColour wxSystemSettingsNative::GetColour(wxSystemColour index) break; } #endif - // fall through + wxFALLTHROUGH; case wxSYS_COLOUR_GRAYTEXT: sc = StyleContext(path, GTK_TYPE_LABEL, "label"); fg(sc, color, GTK_STATE_FLAG_INSENSITIVE); diff --git a/tests/datetime/datetimetest.cpp b/tests/datetime/datetimetest.cpp index ff10973ea7..9cf114e9bc 100644 --- a/tests/datetime/datetimetest.cpp +++ b/tests/datetime/datetimetest.cpp @@ -800,6 +800,7 @@ void DateTimeTestCase::TestTimeFormat() dt2.SetYear(dt.GetYear()); } // fall through and compare everything + wxFALLTHROUGH; case CompareBoth: CPPUNIT_ASSERT_EQUAL( dt, dt2 );