adding wxFALLTHROUGH where until now we had comments, allows for code-analysis support
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76399 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -784,7 +784,7 @@ static wxOrientation GetOrientation(long style)
|
|||||||
return wxVERTICAL;
|
return wxVERTICAL;
|
||||||
default:
|
default:
|
||||||
wxFAIL_MSG("toolbar cannot be locked in both horizontal and vertical orientations (maybe no lock was intended?)");
|
wxFAIL_MSG("toolbar cannot be locked in both horizontal and vertical orientations (maybe no lock was intended?)");
|
||||||
// fall through
|
wxFALLTHROUGH;
|
||||||
case 0:
|
case 0:
|
||||||
return wxBOTH;
|
return wxBOTH;
|
||||||
}
|
}
|
||||||
|
@@ -265,7 +265,7 @@ wxTangoArtProvider::CreateBitmap(const wxArtID& id,
|
|||||||
{
|
{
|
||||||
default:
|
default:
|
||||||
wxFAIL_MSG( "Unsupported Tango bitmap size" );
|
wxFAIL_MSG( "Unsupported Tango bitmap size" );
|
||||||
// fall through
|
wxFALLTHROUGH;
|
||||||
|
|
||||||
case TangoSize_16:
|
case TangoSize_16:
|
||||||
data = entry.data16;
|
data = entry.data16;
|
||||||
|
@@ -127,7 +127,7 @@ wxBase64Decode(void *dst_, size_t dstLen,
|
|||||||
case WSP:
|
case WSP:
|
||||||
if ( mode == wxBase64DecodeMode_SkipWS )
|
if ( mode == wxBase64DecodeMode_SkipWS )
|
||||||
continue;
|
continue;
|
||||||
// fall through
|
wxFALLTHROUGH;
|
||||||
|
|
||||||
case INV:
|
case INV:
|
||||||
if ( mode == wxBase64DecodeMode_Relaxed )
|
if ( mode == wxBase64DecodeMode_Relaxed )
|
||||||
|
@@ -166,11 +166,11 @@ wxRect wxBookCtrlBase::GetPageRect() const
|
|||||||
{
|
{
|
||||||
default:
|
default:
|
||||||
wxFAIL_MSG( wxT("unexpected alignment") );
|
wxFAIL_MSG( wxT("unexpected alignment") );
|
||||||
// fall through
|
wxFALLTHROUGH;
|
||||||
|
|
||||||
case wxBK_TOP:
|
case wxBK_TOP:
|
||||||
rectPage.y = size.y + GetInternalBorder();
|
rectPage.y = size.y + GetInternalBorder();
|
||||||
// fall through
|
wxFALLTHROUGH;
|
||||||
|
|
||||||
case wxBK_BOTTOM:
|
case wxBK_BOTTOM:
|
||||||
rectPage.height -= size.y + GetInternalBorder();
|
rectPage.height -= size.y + GetInternalBorder();
|
||||||
@@ -180,7 +180,7 @@ wxRect wxBookCtrlBase::GetPageRect() const
|
|||||||
|
|
||||||
case wxBK_LEFT:
|
case wxBK_LEFT:
|
||||||
rectPage.x = size.x + GetInternalBorder();
|
rectPage.x = size.x + GetInternalBorder();
|
||||||
// fall through
|
wxFALLTHROUGH;
|
||||||
|
|
||||||
case wxBK_RIGHT:
|
case wxBK_RIGHT:
|
||||||
rectPage.width -= size.x + GetInternalBorder();
|
rectPage.width -= size.x + GetInternalBorder();
|
||||||
@@ -225,7 +225,7 @@ void wxBookCtrlBase::DoSize()
|
|||||||
{
|
{
|
||||||
default:
|
default:
|
||||||
wxFAIL_MSG( wxT("unexpected alignment") );
|
wxFAIL_MSG( wxT("unexpected alignment") );
|
||||||
// fall through
|
wxFALLTHROUGH;
|
||||||
|
|
||||||
case wxBK_TOP:
|
case wxBK_TOP:
|
||||||
case wxBK_LEFT:
|
case wxBK_LEFT:
|
||||||
|
@@ -626,7 +626,7 @@ void wxCmdLineParser::SetDesc(const wxCmdLineEntryDesc *desc)
|
|||||||
|
|
||||||
default:
|
default:
|
||||||
wxFAIL_MSG( wxT("unknown command line entry type") );
|
wxFAIL_MSG( wxT("unknown command line entry type") );
|
||||||
// still fall through
|
wxFALLTHROUGH;
|
||||||
|
|
||||||
case wxCMD_LINE_NONE:
|
case wxCMD_LINE_NONE:
|
||||||
return;
|
return;
|
||||||
@@ -1089,7 +1089,7 @@ int wxCmdLineParser::Parse(bool showUsage)
|
|||||||
{
|
{
|
||||||
default:
|
default:
|
||||||
wxFAIL_MSG( wxT("unknown option type") );
|
wxFAIL_MSG( wxT("unknown option type") );
|
||||||
// still fall through
|
wxFALLTHROUGH;
|
||||||
|
|
||||||
case wxCMD_LINE_VAL_STRING:
|
case wxCMD_LINE_VAL_STRING:
|
||||||
opt.SetStrVal(value);
|
opt.SetStrVal(value);
|
||||||
@@ -1470,7 +1470,7 @@ static wxString GetTypeName(wxCmdLineParamType type)
|
|||||||
{
|
{
|
||||||
default:
|
default:
|
||||||
wxFAIL_MSG( wxT("unknown option type") );
|
wxFAIL_MSG( wxT("unknown option type") );
|
||||||
// still fall through
|
wxFALLTHROUGH;
|
||||||
|
|
||||||
case wxCMD_LINE_VAL_STRING:
|
case wxCMD_LINE_VAL_STRING:
|
||||||
s = _("str");
|
s = _("str");
|
||||||
|
@@ -494,7 +494,7 @@ wxString wxExpandEnvVars(const wxString& str)
|
|||||||
|
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
//else: fall through
|
wxFALLTHROUGH;
|
||||||
|
|
||||||
default:
|
default:
|
||||||
strResult += str[n];
|
strResult += str[n];
|
||||||
|
@@ -255,7 +255,7 @@ void wxItemContainer::AssignNewItemClientData(unsigned int pos,
|
|||||||
|
|
||||||
default:
|
default:
|
||||||
wxFAIL_MSG( wxT("unknown client data type") );
|
wxFAIL_MSG( wxT("unknown client data type") );
|
||||||
// fall through
|
wxFALLTHROUGH;
|
||||||
|
|
||||||
case wxClientData_None:
|
case wxClientData_None:
|
||||||
// nothing to do
|
// nothing to do
|
||||||
|
@@ -712,7 +712,7 @@ wxString wxDateTime::Format(const wxString& formatp, const TimeZone& tz) const
|
|||||||
// no, it wasn't the width
|
// no, it wasn't the width
|
||||||
wxFAIL_MSG(wxT("unknown format specifier"));
|
wxFAIL_MSG(wxT("unknown format specifier"));
|
||||||
|
|
||||||
// fall through and just copy it nevertheless
|
wxFALLTHROUGH;
|
||||||
|
|
||||||
case wxT('%'): // a percent sign
|
case wxT('%'): // a percent sign
|
||||||
res += *p;
|
res += *p;
|
||||||
@@ -1495,7 +1495,7 @@ wxDateTime::ParseFormat(const wxString& date,
|
|||||||
case 0: // the end of string
|
case 0: // the end of string
|
||||||
wxFAIL_MSG(wxT("unexpected format end"));
|
wxFAIL_MSG(wxT("unexpected format end"));
|
||||||
|
|
||||||
// fall through
|
wxFALLTHROUGH;
|
||||||
|
|
||||||
default: // not a known format spec
|
default: // not a known format spec
|
||||||
return false;
|
return false;
|
||||||
@@ -2262,7 +2262,7 @@ wxString wxTimeSpan::Format(const wxString& format) const
|
|||||||
{
|
{
|
||||||
default:
|
default:
|
||||||
wxFAIL_MSG( wxT("invalid format character") );
|
wxFAIL_MSG( wxT("invalid format character") );
|
||||||
// fall through
|
wxFALLTHROUGH;
|
||||||
|
|
||||||
case wxT('%'):
|
case wxT('%'):
|
||||||
str += ch;
|
str += ch;
|
||||||
|
@@ -126,7 +126,7 @@ size_t wxDir::Traverse(wxDirTraverser& sink,
|
|||||||
{
|
{
|
||||||
default:
|
default:
|
||||||
wxFAIL_MSG(wxT("unexpected OnDir() return value") );
|
wxFAIL_MSG(wxT("unexpected OnDir() return value") );
|
||||||
// fall through
|
wxFALLTHROUGH;
|
||||||
|
|
||||||
case wxDIR_STOP:
|
case wxDIR_STOP:
|
||||||
cont = false;
|
cont = false;
|
||||||
@@ -154,11 +154,11 @@ size_t wxDir::Traverse(wxDirTraverser& sink,
|
|||||||
{
|
{
|
||||||
default:
|
default:
|
||||||
wxFAIL_MSG(wxT("unexpected OnOpenError() return value") );
|
wxFAIL_MSG(wxT("unexpected OnOpenError() return value") );
|
||||||
// fall through
|
wxFALLTHROUGH;
|
||||||
|
|
||||||
case wxDIR_STOP:
|
case wxDIR_STOP:
|
||||||
cont = false;
|
cont = false;
|
||||||
// fall through
|
wxFALLTHROUGH;
|
||||||
|
|
||||||
case wxDIR_IGNORE:
|
case wxDIR_IGNORE:
|
||||||
tryagain = false;
|
tryagain = false;
|
||||||
|
@@ -442,7 +442,7 @@ bool wxDialogBase::SendCloseButtonClickEvent()
|
|||||||
if ( EmulateButtonClickIfPresent(wxID_CANCEL) )
|
if ( EmulateButtonClickIfPresent(wxID_CANCEL) )
|
||||||
return true;
|
return true;
|
||||||
idCancel = GetAffirmativeId();
|
idCancel = GetAffirmativeId();
|
||||||
// fall through
|
wxFALLTHROUGH;
|
||||||
|
|
||||||
default:
|
default:
|
||||||
// translate Esc to button press for the button with given id
|
// translate Esc to button press for the button with given id
|
||||||
|
@@ -601,7 +601,7 @@ bool wxMouseEvent::ButtonDClick(int but) const
|
|||||||
{
|
{
|
||||||
default:
|
default:
|
||||||
wxFAIL_MSG(wxT("invalid parameter in wxMouseEvent::ButtonDClick"));
|
wxFAIL_MSG(wxT("invalid parameter in wxMouseEvent::ButtonDClick"));
|
||||||
// fall through
|
wxFALLTHROUGH;
|
||||||
|
|
||||||
case wxMOUSE_BTN_ANY:
|
case wxMOUSE_BTN_ANY:
|
||||||
return (LeftDClick() || MiddleDClick() || RightDClick() ||
|
return (LeftDClick() || MiddleDClick() || RightDClick() ||
|
||||||
@@ -631,7 +631,7 @@ bool wxMouseEvent::ButtonDown(int but) const
|
|||||||
{
|
{
|
||||||
default:
|
default:
|
||||||
wxFAIL_MSG(wxT("invalid parameter in wxMouseEvent::ButtonDown"));
|
wxFAIL_MSG(wxT("invalid parameter in wxMouseEvent::ButtonDown"));
|
||||||
// fall through
|
wxFALLTHROUGH;
|
||||||
|
|
||||||
case wxMOUSE_BTN_ANY:
|
case wxMOUSE_BTN_ANY:
|
||||||
return (LeftDown() || MiddleDown() || RightDown() ||
|
return (LeftDown() || MiddleDown() || RightDown() ||
|
||||||
@@ -661,7 +661,7 @@ bool wxMouseEvent::ButtonUp(int but) const
|
|||||||
{
|
{
|
||||||
default:
|
default:
|
||||||
wxFAIL_MSG(wxT("invalid parameter in wxMouseEvent::ButtonUp"));
|
wxFAIL_MSG(wxT("invalid parameter in wxMouseEvent::ButtonUp"));
|
||||||
// fall through
|
wxFALLTHROUGH;
|
||||||
|
|
||||||
case wxMOUSE_BTN_ANY:
|
case wxMOUSE_BTN_ANY:
|
||||||
return (LeftUp() || MiddleUp() || RightUp() ||
|
return (LeftUp() || MiddleUp() || RightUp() ||
|
||||||
@@ -691,7 +691,7 @@ bool wxMouseEvent::Button(int but) const
|
|||||||
{
|
{
|
||||||
default:
|
default:
|
||||||
wxFAIL_MSG(wxT("invalid parameter in wxMouseEvent::Button"));
|
wxFAIL_MSG(wxT("invalid parameter in wxMouseEvent::Button"));
|
||||||
// fall through
|
wxFALLTHROUGH;
|
||||||
|
|
||||||
case wxMOUSE_BTN_ANY:
|
case wxMOUSE_BTN_ANY:
|
||||||
return ButtonUp(wxMOUSE_BTN_ANY) ||
|
return ButtonUp(wxMOUSE_BTN_ANY) ||
|
||||||
|
@@ -195,7 +195,7 @@ bool wxFFile::Seek(wxFileOffset ofs, wxSeekMode mode)
|
|||||||
{
|
{
|
||||||
default:
|
default:
|
||||||
wxFAIL_MSG(wxT("unknown seek mode"));
|
wxFAIL_MSG(wxT("unknown seek mode"));
|
||||||
// still fall through
|
wxFALLTHROUGH;
|
||||||
|
|
||||||
case wxFromStart:
|
case wxFromStart:
|
||||||
origin = SEEK_SET;
|
origin = SEEK_SET;
|
||||||
|
@@ -147,7 +147,7 @@ bool wxFile::Access(const wxString& name, OpenMode mode)
|
|||||||
{
|
{
|
||||||
default:
|
default:
|
||||||
wxFAIL_MSG(wxT("bad wxFile::Access mode parameter."));
|
wxFAIL_MSG(wxT("bad wxFile::Access mode parameter."));
|
||||||
// fall through
|
wxFALLTHROUGH;
|
||||||
|
|
||||||
case read:
|
case read:
|
||||||
how = R_OK;
|
how = R_OK;
|
||||||
@@ -232,6 +232,7 @@ bool wxFile::Open(const wxString& fileName, OpenMode mode, int accessMode)
|
|||||||
}
|
}
|
||||||
//else: fall through as write_append is the same as write if the
|
//else: fall through as write_append is the same as write if the
|
||||||
// file doesn't exist
|
// file doesn't exist
|
||||||
|
wxFALLTHROUGH;
|
||||||
|
|
||||||
case write:
|
case write:
|
||||||
flags |= O_WRONLY | O_CREAT | O_TRUNC;
|
flags |= O_WRONLY | O_CREAT | O_TRUNC;
|
||||||
@@ -406,7 +407,7 @@ wxFileOffset wxFile::Seek(wxFileOffset ofs, wxSeekMode mode)
|
|||||||
switch ( mode ) {
|
switch ( mode ) {
|
||||||
default:
|
default:
|
||||||
wxFAIL_MSG(wxT("unknown seek origin"));
|
wxFAIL_MSG(wxT("unknown seek origin"));
|
||||||
|
wxFALLTHROUGH;
|
||||||
case wxFromStart:
|
case wxFromStart:
|
||||||
origin = SEEK_SET;
|
origin = SEEK_SET;
|
||||||
break;
|
break;
|
||||||
|
@@ -2056,7 +2056,7 @@ static wxString FilterOutValue(const wxString& str)
|
|||||||
c = wxT('"');
|
c = wxT('"');
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
//else: fall through
|
wxFALLTHROUGH;
|
||||||
|
|
||||||
default:
|
default:
|
||||||
strResult += str[n];
|
strResult += str[n];
|
||||||
|
@@ -495,7 +495,7 @@ void wxFileName::SetPath( const wxString& pathOrig, wxPathFormat format )
|
|||||||
|
|
||||||
default:
|
default:
|
||||||
wxFAIL_MSG( wxT("Unknown path format") );
|
wxFAIL_MSG( wxT("Unknown path format") );
|
||||||
// !! Fall through !!
|
wxFALLTHROUGH;
|
||||||
|
|
||||||
case wxPATH_UNIX:
|
case wxPATH_UNIX:
|
||||||
m_relative = leadingChar != wxT('/');
|
m_relative = leadingChar != wxT('/');
|
||||||
@@ -1890,7 +1890,7 @@ wxString wxFileName::GetForbiddenChars(wxPathFormat format)
|
|||||||
{
|
{
|
||||||
default :
|
default :
|
||||||
wxFAIL_MSG( wxT("Unknown path format") );
|
wxFAIL_MSG( wxT("Unknown path format") );
|
||||||
// !! Fall through !!
|
wxFALLTHROUGH;
|
||||||
|
|
||||||
case wxPATH_UNIX:
|
case wxPATH_UNIX:
|
||||||
break;
|
break;
|
||||||
@@ -1945,7 +1945,7 @@ wxString wxFileName::GetPathSeparators(wxPathFormat format)
|
|||||||
|
|
||||||
default:
|
default:
|
||||||
wxFAIL_MSG( wxT("Unknown wxPATH_XXX style") );
|
wxFAIL_MSG( wxT("Unknown wxPATH_XXX style") );
|
||||||
// fall through
|
wxFALLTHROUGH;
|
||||||
|
|
||||||
case wxPATH_UNIX:
|
case wxPATH_UNIX:
|
||||||
seps = wxFILE_SEP_PATH_UNIX;
|
seps = wxFILE_SEP_PATH_UNIX;
|
||||||
@@ -2094,7 +2094,7 @@ wxString wxFileName::GetPath( int flags, wxPathFormat format ) const
|
|||||||
|
|
||||||
default:
|
default:
|
||||||
wxFAIL_MSG( wxT("Unknown path format") );
|
wxFAIL_MSG( wxT("Unknown path format") );
|
||||||
// fall through
|
wxFALLTHROUGH;
|
||||||
|
|
||||||
case wxPATH_UNIX:
|
case wxPATH_UNIX:
|
||||||
if ( !m_relative )
|
if ( !m_relative )
|
||||||
@@ -2143,7 +2143,7 @@ wxString wxFileName::GetPath( int flags, wxPathFormat format ) const
|
|||||||
|
|
||||||
default:
|
default:
|
||||||
wxFAIL_MSG( wxT("Unexpected path format") );
|
wxFAIL_MSG( wxT("Unexpected path format") );
|
||||||
// still fall through
|
wxFALLTHROUGH;
|
||||||
|
|
||||||
case wxPATH_DOS:
|
case wxPATH_DOS:
|
||||||
case wxPATH_UNIX:
|
case wxPATH_UNIX:
|
||||||
|
@@ -808,7 +808,7 @@ wxString wxNativeFontInfo::ToUserString() const
|
|||||||
{
|
{
|
||||||
default:
|
default:
|
||||||
wxFAIL_MSG( wxT("unknown font weight") );
|
wxFAIL_MSG( wxT("unknown font weight") );
|
||||||
// fall through
|
wxFALLTHROUGH;
|
||||||
|
|
||||||
case wxFONTWEIGHT_NORMAL:
|
case wxFONTWEIGHT_NORMAL:
|
||||||
break;
|
break;
|
||||||
@@ -826,7 +826,7 @@ wxString wxNativeFontInfo::ToUserString() const
|
|||||||
{
|
{
|
||||||
default:
|
default:
|
||||||
wxFAIL_MSG( wxT("unknown font style") );
|
wxFAIL_MSG( wxT("unknown font style") );
|
||||||
// fall through
|
wxFALLTHROUGH;
|
||||||
|
|
||||||
case wxFONTSTYLE_NORMAL:
|
case wxFONTSTYLE_NORMAL:
|
||||||
break;
|
break;
|
||||||
|
@@ -388,7 +388,7 @@ bool wxFTP::SetTransferMode(TransferMode transferMode)
|
|||||||
{
|
{
|
||||||
default:
|
default:
|
||||||
wxFAIL_MSG(wxT("unknown FTP transfer mode"));
|
wxFAIL_MSG(wxT("unknown FTP transfer mode"));
|
||||||
// fall through
|
wxFALLTHROUGH;
|
||||||
|
|
||||||
case BINARY:
|
case BINARY:
|
||||||
mode = wxT('I');
|
mode = wxT('I');
|
||||||
|
@@ -204,18 +204,18 @@ bool wxBMPHandler::SaveDib(wxImage *image,
|
|||||||
{
|
{
|
||||||
default:
|
default:
|
||||||
wxFAIL_MSG( wxT("unexpected image resolution units") );
|
wxFAIL_MSG( wxT("unexpected image resolution units") );
|
||||||
// fall through
|
wxFALLTHROUGH;
|
||||||
|
|
||||||
case wxIMAGE_RESOLUTION_NONE:
|
case wxIMAGE_RESOLUTION_NONE:
|
||||||
hres =
|
hres =
|
||||||
vres = 72;
|
vres = 72;
|
||||||
// fall through to convert it to correct units
|
wxFALLTHROUGH;// fall through to convert it to correct units
|
||||||
|
|
||||||
case wxIMAGE_RESOLUTION_INCHES:
|
case wxIMAGE_RESOLUTION_INCHES:
|
||||||
// convert resolution in inches to resolution in centimeters
|
// convert resolution in inches to resolution in centimeters
|
||||||
hres = (int)(10*mm2inches*hres);
|
hres = (int)(10*mm2inches*hres);
|
||||||
vres = (int)(10*mm2inches*vres);
|
vres = (int)(10*mm2inches*vres);
|
||||||
// fall through to convert it to resolution in meters
|
wxFALLTHROUGH;// fall through to convert it to resolution in meters
|
||||||
|
|
||||||
case wxIMAGE_RESOLUTION_CM:
|
case wxIMAGE_RESOLUTION_CM:
|
||||||
// convert resolution in centimeters to resolution in meters
|
// convert resolution in centimeters to resolution in meters
|
||||||
|
@@ -387,12 +387,12 @@ void CopyDataFromPNG(wxImage *image,
|
|||||||
// using the mask at all
|
// using the mask at all
|
||||||
wxASSERT_MSG( IsOpaque(a), wxT("logic error") );
|
wxASSERT_MSG( IsOpaque(a), wxT("logic error") );
|
||||||
|
|
||||||
// fall through
|
wxFALLTHROUGH;
|
||||||
|
|
||||||
case Transparency_Alpha:
|
case Transparency_Alpha:
|
||||||
if ( alpha )
|
if ( alpha )
|
||||||
*alpha++ = a;
|
*alpha++ = a;
|
||||||
// fall through
|
wxFALLTHROUGH;
|
||||||
|
|
||||||
case Transparency_None:
|
case Transparency_None:
|
||||||
*ptrDst++ = g;
|
*ptrDst++ = g;
|
||||||
@@ -466,12 +466,12 @@ void CopyDataFromPNG(wxImage *image,
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// fall through
|
wxFALLTHROUGH;
|
||||||
|
|
||||||
case Transparency_Alpha:
|
case Transparency_Alpha:
|
||||||
if ( alpha )
|
if ( alpha )
|
||||||
*alpha++ = a;
|
*alpha++ = a;
|
||||||
// fall through
|
wxFALLTHROUGH;
|
||||||
|
|
||||||
case Transparency_None:
|
case Transparency_None:
|
||||||
*ptrDst++ = r;
|
*ptrDst++ = r;
|
||||||
@@ -612,7 +612,7 @@ wxPNGHandler::LoadFile(wxImage *image,
|
|||||||
{
|
{
|
||||||
default:
|
default:
|
||||||
wxLogWarning(_("Unknown PNG resolution unit %d"), unitType);
|
wxLogWarning(_("Unknown PNG resolution unit %d"), unitType);
|
||||||
// fall through
|
wxFALLTHROUGH;
|
||||||
|
|
||||||
case PNG_RESOLUTION_UNKNOWN:
|
case PNG_RESOLUTION_UNKNOWN:
|
||||||
image->SetOption(wxIMAGE_OPTION_RESOLUTIONX, resX);
|
image->SetOption(wxIMAGE_OPTION_RESOLUTIONX, resX);
|
||||||
@@ -1004,7 +1004,7 @@ bool wxPNGHandler::SaveFile( wxImage *image, wxOutputStream& stream, bool verbos
|
|||||||
{
|
{
|
||||||
default:
|
default:
|
||||||
wxFAIL_MSG( wxT("unknown wxPNG_TYPE_XXX") );
|
wxFAIL_MSG( wxT("unknown wxPNG_TYPE_XXX") );
|
||||||
// fall through
|
wxFALLTHROUGH;
|
||||||
|
|
||||||
case wxPNG_TYPE_COLOUR:
|
case wxPNG_TYPE_COLOUR:
|
||||||
*pData++ = clr.red;
|
*pData++ = clr.red;
|
||||||
|
@@ -531,7 +531,7 @@ bool wxTIFFHandler::LoadFile( wxImage *image, wxInputStream& stream, bool verbos
|
|||||||
default:
|
default:
|
||||||
wxLogWarning(_("Unknown TIFF resolution unit %d ignored"),
|
wxLogWarning(_("Unknown TIFF resolution unit %d ignored"),
|
||||||
tiffRes);
|
tiffRes);
|
||||||
// fall through
|
wxFALLTHROUGH;
|
||||||
|
|
||||||
case RESUNIT_NONE:
|
case RESUNIT_NONE:
|
||||||
resUnit = wxIMAGE_RESOLUTION_NONE;
|
resUnit = wxIMAGE_RESOLUTION_NONE;
|
||||||
@@ -628,7 +628,7 @@ bool wxTIFFHandler::SaveFile( wxImage *image, wxOutputStream& stream, bool verbo
|
|||||||
{
|
{
|
||||||
default:
|
default:
|
||||||
wxFAIL_MSG( wxT("unknown image resolution units") );
|
wxFAIL_MSG( wxT("unknown image resolution units") );
|
||||||
// fall through
|
wxFALLTHROUGH;
|
||||||
|
|
||||||
case wxIMAGE_RESOLUTION_NONE:
|
case wxIMAGE_RESOLUTION_NONE:
|
||||||
tiffRes = RESUNIT_NONE;
|
tiffRes = RESUNIT_NONE;
|
||||||
|
@@ -386,7 +386,7 @@ bool wxMarkupParser::Parse(const wxString& text)
|
|||||||
|
|
||||||
if ( n < WXSIZEOF(xmlEntities) )
|
if ( n < WXSIZEOF(xmlEntities) )
|
||||||
break;
|
break;
|
||||||
//else: fall through, '&' is not special
|
wxFALLTHROUGH;//else: fall through, '&' is not special
|
||||||
}
|
}
|
||||||
|
|
||||||
default:
|
default:
|
||||||
|
@@ -608,7 +608,7 @@ void wxPopupWindowHandler::OnLeftDown(wxMouseEvent& event)
|
|||||||
default:
|
default:
|
||||||
// forgot to update the switch after adding a new hit test code?
|
// forgot to update the switch after adding a new hit test code?
|
||||||
wxFAIL_MSG( wxT("unexpected HitTest() return value") );
|
wxFAIL_MSG( wxT("unexpected HitTest() return value") );
|
||||||
// fall through
|
wxFALLTHROUGH;
|
||||||
|
|
||||||
case wxHT_WINDOW_CORNER:
|
case wxHT_WINDOW_CORNER:
|
||||||
// don't actually know if this one is good for anything, but let it
|
// don't actually know if this one is good for anything, but let it
|
||||||
|
@@ -169,7 +169,7 @@ bool wxProcess::Exists(int pid)
|
|||||||
case wxKILL_ERROR:
|
case wxKILL_ERROR:
|
||||||
case wxKILL_BAD_SIGNAL:
|
case wxKILL_BAD_SIGNAL:
|
||||||
wxFAIL_MSG( wxT("unexpected wxProcess::Kill() return code") );
|
wxFAIL_MSG( wxT("unexpected wxProcess::Kill() return code") );
|
||||||
// fall through
|
wxFALLTHROUGH;
|
||||||
|
|
||||||
case wxKILL_NO_PROCESS:
|
case wxKILL_NO_PROCESS:
|
||||||
return false;
|
return false;
|
||||||
|
@@ -349,7 +349,7 @@ wxString wxRadioBoxBase::DoGetHelpTextAtPoint(const wxWindow *derived,
|
|||||||
|
|
||||||
default:
|
default:
|
||||||
wxFAIL_MSG( "unknown help even origin" );
|
wxFAIL_MSG( "unknown help even origin" );
|
||||||
// fall through
|
wxFALLTHROUGH;
|
||||||
|
|
||||||
case wxHelpEvent::Origin_Unknown:
|
case wxHelpEvent::Origin_Unknown:
|
||||||
// this value is used when we're called from GetHelpText() for the
|
// this value is used when we're called from GetHelpText() for the
|
||||||
|
@@ -433,7 +433,7 @@ bool wxRegExImpl::Matches(const wxRegChar *str,
|
|||||||
// an error occurred
|
// an error occurred
|
||||||
wxLogError(_("Failed to find match for regular expression: %s"),
|
wxLogError(_("Failed to find match for regular expression: %s"),
|
||||||
GetErrorMsg(rc, !str).c_str());
|
GetErrorMsg(rc, !str).c_str());
|
||||||
// fall through
|
wxFALLTHROUGH;
|
||||||
|
|
||||||
case REG_NOMATCH:
|
case REG_NOMATCH:
|
||||||
// no match
|
// no match
|
||||||
|
@@ -2201,7 +2201,7 @@ bool wxString::Matches(const wxString& mask) const
|
|||||||
// (however note that we don't quote '[' and ']' to allow
|
// (however note that we don't quote '[' and ']' to allow
|
||||||
// using them for Unix shell like matching)
|
// using them for Unix shell like matching)
|
||||||
pattern += wxT('\\');
|
pattern += wxT('\\');
|
||||||
// fall through
|
wxFALLTHROUGH;
|
||||||
|
|
||||||
default:
|
default:
|
||||||
pattern += *pszMask;
|
pattern += *pszMask;
|
||||||
|
@@ -211,7 +211,7 @@ public:
|
|||||||
format++;
|
format++;
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
//else: fall through
|
wxFALLTHROUGH;
|
||||||
|
|
||||||
default:
|
default:
|
||||||
size = Size_Default;
|
size = Size_Default;
|
||||||
|
@@ -52,7 +52,7 @@ const wxChar *wxTextBuffer::GetEOL(wxTextFileType type)
|
|||||||
switch ( type ) {
|
switch ( type ) {
|
||||||
default:
|
default:
|
||||||
wxFAIL_MSG(wxT("bad buffer type in wxTextBuffer::GetEOL."));
|
wxFAIL_MSG(wxT("bad buffer type in wxTextBuffer::GetEOL."));
|
||||||
// fall through nevertheless - we must return something...
|
wxFALLTHROUGH; // fall through nevertheless - we must return something...
|
||||||
|
|
||||||
case wxTextFileType_None: return wxEmptyString;
|
case wxTextFileType_None: return wxEmptyString;
|
||||||
case wxTextFileType_Unix: return wxT("\n");
|
case wxTextFileType_Unix: return wxT("\n");
|
||||||
|
@@ -64,7 +64,7 @@ bool wxTextFile::OnOpen(const wxString &strBufferName, wxTextBufferOpenMode Open
|
|||||||
{
|
{
|
||||||
default:
|
default:
|
||||||
wxFAIL_MSG( wxT("unknown open mode in wxTextFile::Open") );
|
wxFAIL_MSG( wxT("unknown open mode in wxTextFile::Open") );
|
||||||
// fall through
|
wxFALLTHROUGH;
|
||||||
|
|
||||||
case ReadAccess :
|
case ReadAccess :
|
||||||
FileOpenMode = wxFile::read;
|
FileOpenMode = wxFile::read;
|
||||||
|
@@ -190,7 +190,7 @@ bool wxStringTokenizer::DoHasMoreTokens() const
|
|||||||
case wxTOKEN_INVALID:
|
case wxTOKEN_INVALID:
|
||||||
case wxTOKEN_DEFAULT:
|
case wxTOKEN_DEFAULT:
|
||||||
wxFAIL_MSG( wxT("unexpected tokenizer mode") );
|
wxFAIL_MSG( wxT("unexpected tokenizer mode") );
|
||||||
// fall through
|
wxFALLTHROUGH;
|
||||||
|
|
||||||
case wxTOKEN_STRTOK:
|
case wxTOKEN_STRTOK:
|
||||||
// never return empty delimiters
|
// never return empty delimiters
|
||||||
|
@@ -359,7 +359,7 @@ void wxTreeCtrlBase::OnCharHook(wxKeyEvent& event)
|
|||||||
{
|
{
|
||||||
case WXK_ESCAPE:
|
case WXK_ESCAPE:
|
||||||
discardChanges = true;
|
discardChanges = true;
|
||||||
// fall through
|
wxFALLTHROUGH;
|
||||||
|
|
||||||
case WXK_RETURN:
|
case WXK_RETURN:
|
||||||
EndEditLabel(GetFocusedItem(), discardChanges);
|
EndEditLabel(GetFocusedItem(), discardChanges);
|
||||||
|
@@ -92,7 +92,7 @@ wxChar wxTextInputStream::NextChar()
|
|||||||
// loop iteration we shouldn't be able to decode 2 or more of
|
// loop iteration we shouldn't be able to decode 2 or more of
|
||||||
// them with an extra single byte, something fishy is going on
|
// them with an extra single byte, something fishy is going on
|
||||||
wxFAIL_MSG("unexpected decoding result");
|
wxFAIL_MSG("unexpected decoding result");
|
||||||
// fall through nevertheless and return at least something
|
wxFALLTHROUGH;// fall through nevertheless and return at least something
|
||||||
|
|
||||||
case 1:
|
case 1:
|
||||||
// we finally decoded a character
|
// we finally decoded a character
|
||||||
@@ -457,7 +457,7 @@ void wxTextOutputStream::WriteString(const wxString& string)
|
|||||||
|
|
||||||
default:
|
default:
|
||||||
wxFAIL_MSG( wxT("unknown EOL mode in wxTextOutputStream") );
|
wxFAIL_MSG( wxT("unknown EOL mode in wxTextOutputStream") );
|
||||||
// fall through
|
wxFALLTHROUGH;
|
||||||
|
|
||||||
case wxEOL_UNIX:
|
case wxEOL_UNIX:
|
||||||
// don't treat '\n' specially
|
// don't treat '\n' specially
|
||||||
|
@@ -1378,7 +1378,7 @@ void wxGenericCalendarCtrl::OnClick(wxMouseEvent& event)
|
|||||||
|
|
||||||
default:
|
default:
|
||||||
wxFAIL_MSG(wxT("unknown hittest code"));
|
wxFAIL_MSG(wxT("unknown hittest code"));
|
||||||
// fall through
|
wxFALLTHROUGH;
|
||||||
|
|
||||||
case wxCAL_HITTEST_NOWHERE:
|
case wxCAL_HITTEST_NOWHERE:
|
||||||
event.Skip();
|
event.Skip();
|
||||||
|
@@ -4958,7 +4958,7 @@ void wxGrid::OnKeyDown( wxKeyEvent& event )
|
|||||||
MoveCursorRight(false);
|
MoveCursorRight(false);
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
//else: fall through
|
wxFALLTHROUGH;
|
||||||
|
|
||||||
default:
|
default:
|
||||||
event.Skip();
|
event.Skip();
|
||||||
@@ -5173,7 +5173,7 @@ wxGrid::UpdateBlockBeingSelected(int topRow, int leftCol,
|
|||||||
{
|
{
|
||||||
default:
|
default:
|
||||||
wxFAIL_MSG( "unknown selection mode" );
|
wxFAIL_MSG( "unknown selection mode" );
|
||||||
// fall through
|
wxFALLTHROUGH;
|
||||||
|
|
||||||
case wxGridSelectCells:
|
case wxGridSelectCells:
|
||||||
// arbitrary blocks selection allowed so just use the cell
|
// arbitrary blocks selection allowed so just use the cell
|
||||||
|
@@ -379,7 +379,7 @@ void wxGridSelection::SelectBlock( int topRow, int leftCol,
|
|||||||
{
|
{
|
||||||
default:
|
default:
|
||||||
wxFAIL_MSG( "unknown selection mode" );
|
wxFAIL_MSG( "unknown selection mode" );
|
||||||
// fall through
|
wxFALLTHROUGH;
|
||||||
|
|
||||||
case wxGrid::wxGridSelectCells:
|
case wxGrid::wxGridSelectCells:
|
||||||
// nothing to do -- in this mode arbitrary blocks can be selected
|
// nothing to do -- in this mode arbitrary blocks can be selected
|
||||||
|
@@ -154,7 +154,7 @@ wxShowEffect wxInfoBarGeneric::GetShowEffect() const
|
|||||||
|
|
||||||
default:
|
default:
|
||||||
wxFAIL_MSG( "unknown info bar placement" );
|
wxFAIL_MSG( "unknown info bar placement" );
|
||||||
// fall through
|
wxFALLTHROUGH;
|
||||||
|
|
||||||
case BarPlacement_Unknown:
|
case BarPlacement_Unknown:
|
||||||
return wxSHOW_EFFECT_NONE;
|
return wxSHOW_EFFECT_NONE;
|
||||||
@@ -176,7 +176,7 @@ wxShowEffect wxInfoBarGeneric::GetHideEffect() const
|
|||||||
|
|
||||||
default:
|
default:
|
||||||
wxFAIL_MSG( "unknown info bar placement" );
|
wxFAIL_MSG( "unknown info bar placement" );
|
||||||
// fall through
|
wxFALLTHROUGH;
|
||||||
|
|
||||||
case BarPlacement_Unknown:
|
case BarPlacement_Unknown:
|
||||||
return wxSHOW_EFFECT_NONE;
|
return wxSHOW_EFFECT_NONE;
|
||||||
|
@@ -1110,7 +1110,7 @@ void wxListHeaderWindow::OnPaint( wxPaintEvent &WXUNUSED(event) )
|
|||||||
{
|
{
|
||||||
default:
|
default:
|
||||||
wxFAIL_MSG( wxT("unknown list item format") );
|
wxFAIL_MSG( wxT("unknown list item format") );
|
||||||
// fall through
|
wxFALLTHROUGH;
|
||||||
|
|
||||||
case wxLIST_FORMAT_LEFT:
|
case wxLIST_FORMAT_LEFT:
|
||||||
xAligned = x;
|
xAligned = x;
|
||||||
|
@@ -238,7 +238,7 @@ wxString wxLogGui::GetTitle() const
|
|||||||
|
|
||||||
default:
|
default:
|
||||||
wxFAIL_MSG( "unexpected icon severity" );
|
wxFAIL_MSG( "unexpected icon severity" );
|
||||||
// fall through
|
wxFALLTHROUGH;
|
||||||
|
|
||||||
case wxICON_INFORMATION:
|
case wxICON_INFORMATION:
|
||||||
titleFormat = _("%s Information");
|
titleFormat = _("%s Information");
|
||||||
@@ -396,7 +396,7 @@ void wxLogGui::DoLogRecord(wxLogLevel level,
|
|||||||
#endif // wxUSE_LOG_DIALOG
|
#endif // wxUSE_LOG_DIALOG
|
||||||
m_bErrors = true;
|
m_bErrors = true;
|
||||||
}
|
}
|
||||||
// fall through
|
wxFALLTHROUGH;
|
||||||
|
|
||||||
case wxLOG_Warning:
|
case wxLOG_Warning:
|
||||||
if ( !m_bErrors ) {
|
if ( !m_bErrors ) {
|
||||||
|
@@ -882,7 +882,7 @@ void wxAnyScrollHelperBase::HandleOnChar(wxKeyEvent& event)
|
|||||||
|
|
||||||
case WXK_LEFT:
|
case WXK_LEFT:
|
||||||
newEvent.SetOrientation(wxHORIZONTAL);
|
newEvent.SetOrientation(wxHORIZONTAL);
|
||||||
// fall through
|
wxFALLTHROUGH;
|
||||||
|
|
||||||
case WXK_UP:
|
case WXK_UP:
|
||||||
newEvent.SetEventType(wxEVT_SCROLLWIN_LINEUP);
|
newEvent.SetEventType(wxEVT_SCROLLWIN_LINEUP);
|
||||||
@@ -890,7 +890,7 @@ void wxAnyScrollHelperBase::HandleOnChar(wxKeyEvent& event)
|
|||||||
|
|
||||||
case WXK_RIGHT:
|
case WXK_RIGHT:
|
||||||
newEvent.SetOrientation(wxHORIZONTAL);
|
newEvent.SetOrientation(wxHORIZONTAL);
|
||||||
// fall through
|
wxFALLTHROUGH;
|
||||||
|
|
||||||
case WXK_DOWN:
|
case WXK_DOWN:
|
||||||
newEvent.SetEventType(wxEVT_SCROLLWIN_LINEDOWN);
|
newEvent.SetEventType(wxEVT_SCROLLWIN_LINEDOWN);
|
||||||
@@ -1292,7 +1292,7 @@ wxScrollHelper::DoAdjustScrollbar(int orient,
|
|||||||
|
|
||||||
default:
|
default:
|
||||||
wxFAIL_MSG( wxS("unknown scrollbar visibility") );
|
wxFAIL_MSG( wxS("unknown scrollbar visibility") );
|
||||||
// fall through
|
wxFALLTHROUGH;
|
||||||
|
|
||||||
case wxSHOW_SB_DEFAULT:
|
case wxSHOW_SB_DEFAULT:
|
||||||
range = scrollUnits;
|
range = scrollUnits;
|
||||||
|
@@ -680,7 +680,7 @@ wxString wxSpinCtrl::DoValueToText(double val)
|
|||||||
|
|
||||||
default:
|
default:
|
||||||
wxFAIL_MSG( wxS("Unsupported spin control base") );
|
wxFAIL_MSG( wxS("Unsupported spin control base") );
|
||||||
// Fall through
|
wxFALLTHROUGH;
|
||||||
|
|
||||||
case 10:
|
case 10:
|
||||||
return wxString::Format("%ld", static_cast<long>(val));
|
return wxString::Format("%ld", static_cast<long>(val));
|
||||||
|
@@ -3122,7 +3122,7 @@ void wxGenericTreeCtrl::OnChar( wxKeyEvent &event )
|
|||||||
ExpandAllChildren(m_current);
|
ExpandAllChildren(m_current);
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
//else: fall through to Collapse() it
|
wxFALLTHROUGH;//else: fall through to Collapse() it
|
||||||
|
|
||||||
case '-':
|
case '-':
|
||||||
case WXK_SUBTRACT:
|
case WXK_SUBTRACT:
|
||||||
@@ -3236,7 +3236,7 @@ void wxGenericTreeCtrl::OnChar( wxKeyEvent &event )
|
|||||||
//else: don't try to expand hidden root item (which can be the
|
//else: don't try to expand hidden root item (which can be the
|
||||||
// current one when the tree is empty)
|
// current one when the tree is empty)
|
||||||
|
|
||||||
// fall through
|
wxFALLTHROUGH;
|
||||||
|
|
||||||
case WXK_DOWN:
|
case WXK_DOWN:
|
||||||
{
|
{
|
||||||
|
@@ -918,7 +918,7 @@ bool wxHtmlHelpWindow::KeywordSearch(const wxString& keyword,
|
|||||||
{
|
{
|
||||||
default:
|
default:
|
||||||
wxFAIL_MSG( wxT("unknown help search mode") );
|
wxFAIL_MSG( wxT("unknown help search mode") );
|
||||||
// fall back
|
wxFALLTHROUGH;
|
||||||
|
|
||||||
case wxHELP_SEARCH_ALL:
|
case wxHELP_SEARCH_ALL:
|
||||||
{
|
{
|
||||||
|
@@ -276,7 +276,7 @@ void wxHtmlTagsCache::QueryTag(const wxString::const_iterator& at,
|
|||||||
|
|
||||||
case wxHtmlCacheItem::Type_EndingTag:
|
case wxHtmlCacheItem::Type_EndingTag:
|
||||||
wxFAIL_MSG("QueryTag called for ending tag - can't be");
|
wxFAIL_MSG("QueryTag called for ending tag - can't be");
|
||||||
// but if it does happen, fall through, better than crashing
|
wxFALLTHROUGH;// but if it does happen, fall through, better than crashing
|
||||||
|
|
||||||
case wxHtmlCacheItem::Type_NoMatchingEndingTag:
|
case wxHtmlCacheItem::Type_NoMatchingEndingTag:
|
||||||
// If input HTML is invalid and there's no closing tag for this
|
// If input HTML is invalid and there's no closing tag for this
|
||||||
|
@@ -57,7 +57,7 @@ static wxString LINKAGEMODE HtmlizeLinebreaks(const wxString& str)
|
|||||||
if ( j != end && *j == '\n' )
|
if ( j != end && *j == '\n' )
|
||||||
i = j;
|
i = j;
|
||||||
}
|
}
|
||||||
// fall through
|
wxFALLTHROUGH;
|
||||||
case '\n':
|
case '\n':
|
||||||
out << "<br>";
|
out << "<br>";
|
||||||
break;
|
break;
|
||||||
|
@@ -249,7 +249,7 @@ SetBezelStyleFromBorderFlags(NSButton *v,
|
|||||||
|
|
||||||
default:
|
default:
|
||||||
wxFAIL_MSG( "Unknown border style" );
|
wxFAIL_MSG( "Unknown border style" );
|
||||||
// fall through
|
wxFALLTHROUGH;
|
||||||
|
|
||||||
case 0:
|
case 0:
|
||||||
case wxBORDER_STATIC:
|
case wxBORDER_STATIC:
|
||||||
|
@@ -3338,7 +3338,7 @@ void wxDataViewColumn::SetWidth(int width)
|
|||||||
|
|
||||||
case wxCOL_WIDTH_DEFAULT:
|
case wxCOL_WIDTH_DEFAULT:
|
||||||
width = wxDVC_DEFAULT_WIDTH;
|
width = wxDVC_DEFAULT_WIDTH;
|
||||||
// fall through
|
wxFALLTHROUGH;
|
||||||
|
|
||||||
default:
|
default:
|
||||||
[m_NativeDataPtr->GetNativeColumnPtr() setWidth:width];
|
[m_NativeDataPtr->GetNativeColumnPtr() setWidth:width];
|
||||||
|
@@ -173,28 +173,28 @@ void wxMacCocoaMenuItemSetAccelerator( NSMenuItem* menuItem, wxAcceleratorEntry*
|
|||||||
|
|
||||||
case WXK_NUMPAD_LEFT :
|
case WXK_NUMPAD_LEFT :
|
||||||
modifiers |= NSNumericPadKeyMask;
|
modifiers |= NSNumericPadKeyMask;
|
||||||
// pass through
|
wxFALLTHROUGH;
|
||||||
case WXK_LEFT :
|
case WXK_LEFT :
|
||||||
shortcut = NSLeftArrowFunctionKey ;
|
shortcut = NSLeftArrowFunctionKey ;
|
||||||
break ;
|
break ;
|
||||||
|
|
||||||
case WXK_NUMPAD_UP :
|
case WXK_NUMPAD_UP :
|
||||||
modifiers |= NSNumericPadKeyMask;
|
modifiers |= NSNumericPadKeyMask;
|
||||||
// pass through
|
wxFALLTHROUGH;
|
||||||
case WXK_UP :
|
case WXK_UP :
|
||||||
shortcut = NSUpArrowFunctionKey ;
|
shortcut = NSUpArrowFunctionKey ;
|
||||||
break ;
|
break ;
|
||||||
|
|
||||||
case WXK_NUMPAD_RIGHT :
|
case WXK_NUMPAD_RIGHT :
|
||||||
modifiers |= NSNumericPadKeyMask;
|
modifiers |= NSNumericPadKeyMask;
|
||||||
// pass through
|
wxFALLTHROUGH;
|
||||||
case WXK_RIGHT :
|
case WXK_RIGHT :
|
||||||
shortcut = NSRightArrowFunctionKey ;
|
shortcut = NSRightArrowFunctionKey ;
|
||||||
break ;
|
break ;
|
||||||
|
|
||||||
case WXK_NUMPAD_DOWN :
|
case WXK_NUMPAD_DOWN :
|
||||||
modifiers |= NSNumericPadKeyMask;
|
modifiers |= NSNumericPadKeyMask;
|
||||||
// pass through
|
wxFALLTHROUGH;
|
||||||
case WXK_DOWN :
|
case WXK_DOWN :
|
||||||
shortcut = NSDownArrowFunctionKey ;
|
shortcut = NSDownArrowFunctionKey ;
|
||||||
break ;
|
break ;
|
||||||
|
@@ -46,7 +46,7 @@ CGEventType CGEventTypeForMouseButton(int button, bool isDown)
|
|||||||
// want to check for invalid parameters so assert first
|
// want to check for invalid parameters so assert first
|
||||||
default:
|
default:
|
||||||
wxFAIL_MSG("Unsupported button passed in.");
|
wxFAIL_MSG("Unsupported button passed in.");
|
||||||
// fall back to the only known remaining case
|
wxFALLTHROUGH;// fall back to the only known remaining case
|
||||||
|
|
||||||
case wxMOUSE_BTN_MIDDLE:
|
case wxMOUSE_BTN_MIDDLE:
|
||||||
return isDown ? kCGEventOtherMouseDown : kCGEventOtherMouseUp;
|
return isDown ? kCGEventOtherMouseDown : kCGEventOtherMouseUp;
|
||||||
@@ -69,7 +69,7 @@ CGEventType CGEventTypeForMouseDrag(int button)
|
|||||||
// want to check for invalid parameters so assert first
|
// want to check for invalid parameters so assert first
|
||||||
default:
|
default:
|
||||||
wxFAIL_MSG("Unsupported button passed in.");
|
wxFAIL_MSG("Unsupported button passed in.");
|
||||||
// fall back to the only known remaining case
|
wxFALLTHROUGH;// fall back to the only known remaining case
|
||||||
|
|
||||||
case wxMOUSE_BTN_MIDDLE:
|
case wxMOUSE_BTN_MIDDLE:
|
||||||
return kCGEventOtherMouseDragged;
|
return kCGEventOtherMouseDragged;
|
||||||
@@ -92,7 +92,7 @@ CGMouseButton CGButtonForMouseButton(int button)
|
|||||||
// want to check for invalid parameters so assert first
|
// want to check for invalid parameters so assert first
|
||||||
default:
|
default:
|
||||||
wxFAIL_MSG("Unsupported button passed in.");
|
wxFAIL_MSG("Unsupported button passed in.");
|
||||||
// fall back to the only known remaining case
|
wxFALLTHROUGH;// fall back to the only known remaining case
|
||||||
|
|
||||||
case wxMOUSE_BTN_MIDDLE:
|
case wxMOUSE_BTN_MIDDLE:
|
||||||
return kCGMouseButtonCenter;
|
return kCGMouseButtonCenter;
|
||||||
|
@@ -3053,7 +3053,7 @@ bool wxRibbonMSWArtProvider::GetButtonBarButtonSize(
|
|||||||
break;
|
break;
|
||||||
case wxRIBBON_BUTTON_HYBRID:
|
case wxRIBBON_BUTTON_HYBRID:
|
||||||
dropdown_region->SetX(dropdown_region->GetX() + text_size);
|
dropdown_region->SetX(dropdown_region->GetX() + text_size);
|
||||||
// no break
|
wxFALLTHROUGH;// no break
|
||||||
case wxRIBBON_BUTTON_NORMAL:
|
case wxRIBBON_BUTTON_NORMAL:
|
||||||
case wxRIBBON_BUTTON_TOGGLE:
|
case wxRIBBON_BUTTON_TOGGLE:
|
||||||
normal_region->SetWidth(normal_region->GetWidth() + text_size);
|
normal_region->SetWidth(normal_region->GetWidth() + text_size);
|
||||||
|
@@ -95,12 +95,14 @@ public:
|
|||||||
*size = wxRIBBON_BUTTONBAR_BUTTON_MEDIUM;
|
*size = wxRIBBON_BUTTONBAR_BUTTON_MEDIUM;
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
wxFALLTHROUGH;
|
||||||
case wxRIBBON_BUTTONBAR_BUTTON_MEDIUM:
|
case wxRIBBON_BUTTONBAR_BUTTON_MEDIUM:
|
||||||
if(sizes[wxRIBBON_BUTTONBAR_BUTTON_SMALL].is_supported)
|
if(sizes[wxRIBBON_BUTTONBAR_BUTTON_SMALL].is_supported)
|
||||||
{
|
{
|
||||||
*size = wxRIBBON_BUTTONBAR_BUTTON_SMALL;
|
*size = wxRIBBON_BUTTONBAR_BUTTON_SMALL;
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
wxFALLTHROUGH;
|
||||||
case wxRIBBON_BUTTONBAR_BUTTON_SMALL:
|
case wxRIBBON_BUTTONBAR_BUTTON_SMALL:
|
||||||
default:
|
default:
|
||||||
return false;
|
return false;
|
||||||
|
@@ -1005,13 +1005,13 @@ int ScintillaWX::DoKeyDown(const wxKeyEvent& evt, bool* consumed)
|
|||||||
case WXK_ESCAPE: key = SCK_ESCAPE; break;
|
case WXK_ESCAPE: key = SCK_ESCAPE; break;
|
||||||
case WXK_BACK: key = SCK_BACK; break;
|
case WXK_BACK: key = SCK_BACK; break;
|
||||||
case WXK_TAB: key = SCK_TAB; break;
|
case WXK_TAB: key = SCK_TAB; break;
|
||||||
case WXK_NUMPAD_ENTER: // fall through
|
case WXK_NUMPAD_ENTER: wxFALLTHROUGH;
|
||||||
case WXK_RETURN: key = SCK_RETURN; break;
|
case WXK_RETURN: key = SCK_RETURN; break;
|
||||||
case WXK_ADD: // fall through
|
case WXK_ADD: wxFALLTHROUGH;
|
||||||
case WXK_NUMPAD_ADD: key = SCK_ADD; break;
|
case WXK_NUMPAD_ADD: key = SCK_ADD; break;
|
||||||
case WXK_SUBTRACT: // fall through
|
case WXK_SUBTRACT: wxFALLTHROUGH;
|
||||||
case WXK_NUMPAD_SUBTRACT: key = SCK_SUBTRACT; break;
|
case WXK_NUMPAD_SUBTRACT: key = SCK_SUBTRACT; break;
|
||||||
case WXK_DIVIDE: // fall through
|
case WXK_DIVIDE: wxFALLTHROUGH;
|
||||||
case WXK_NUMPAD_DIVIDE: key = SCK_DIVIDE; break;
|
case WXK_NUMPAD_DIVIDE: key = SCK_DIVIDE; break;
|
||||||
case WXK_CONTROL: key = 0; break;
|
case WXK_CONTROL: key = 0; break;
|
||||||
case WXK_ALT: key = 0; break;
|
case WXK_ALT: key = 0; break;
|
||||||
|
@@ -178,7 +178,7 @@ void wxSocketImplUnix::OnReadWaiting()
|
|||||||
|
|
||||||
default:
|
default:
|
||||||
wxFAIL_MSG( "unexpected CheckForInput() return value" );
|
wxFAIL_MSG( "unexpected CheckForInput() return value" );
|
||||||
// fall through
|
wxFALLTHROUGH;
|
||||||
|
|
||||||
case -1:
|
case -1:
|
||||||
if ( GetLastError() == wxSOCKET_WOULDBLOCK )
|
if ( GetLastError() == wxSOCKET_WOULDBLOCK )
|
||||||
|
@@ -237,7 +237,7 @@ wxMutexInternal::wxMutexInternal(wxMutexType mutexType)
|
|||||||
|
|
||||||
default:
|
default:
|
||||||
wxFAIL_MSG( wxT("unknown mutex type") );
|
wxFAIL_MSG( wxT("unknown mutex type") );
|
||||||
// fall through
|
wxFALLTHROUGH;
|
||||||
|
|
||||||
case wxMUTEX_DEFAULT:
|
case wxMUTEX_DEFAULT:
|
||||||
err = pthread_mutex_init(&m_mutex, NULL);
|
err = pthread_mutex_init(&m_mutex, NULL);
|
||||||
@@ -1543,7 +1543,7 @@ wxThreadError wxThread::Delete(ExitCode *rc, wxThreadWait WXUNUSED(waitMode))
|
|||||||
// PthreadStart()
|
// PthreadStart()
|
||||||
m_internal->SignalRun();
|
m_internal->SignalRun();
|
||||||
|
|
||||||
// fall through
|
wxFALLTHROUGH;
|
||||||
|
|
||||||
case STATE_EXITED:
|
case STATE_EXITED:
|
||||||
// nothing to do
|
// nothing to do
|
||||||
@@ -1553,7 +1553,7 @@ wxThreadError wxThread::Delete(ExitCode *rc, wxThreadWait WXUNUSED(waitMode))
|
|||||||
// resume the thread first
|
// resume the thread first
|
||||||
m_internal->Resume();
|
m_internal->Resume();
|
||||||
|
|
||||||
// fall through
|
wxFALLTHROUGH;
|
||||||
|
|
||||||
default:
|
default:
|
||||||
if ( !isDetached )
|
if ( !isDetached )
|
||||||
@@ -1595,7 +1595,7 @@ wxThreadError wxThread::Kill()
|
|||||||
// resume the thread first
|
// resume the thread first
|
||||||
Resume();
|
Resume();
|
||||||
|
|
||||||
// fall through
|
wxFALLTHROUGH;
|
||||||
|
|
||||||
default:
|
default:
|
||||||
#ifdef HAVE_PTHREAD_CANCEL
|
#ifdef HAVE_PTHREAD_CANCEL
|
||||||
|
@@ -305,14 +305,14 @@ bool wxPipeInputStream::CanRead() const
|
|||||||
{
|
{
|
||||||
case -1:
|
case -1:
|
||||||
wxLogSysError(_("Impossible to get child process input"));
|
wxLogSysError(_("Impossible to get child process input"));
|
||||||
// fall through
|
wxFALLTHROUGH;
|
||||||
|
|
||||||
case 0:
|
case 0:
|
||||||
return false;
|
return false;
|
||||||
|
|
||||||
default:
|
default:
|
||||||
wxFAIL_MSG(wxT("unexpected select() return value"));
|
wxFAIL_MSG(wxT("unexpected select() return value"));
|
||||||
// still fall through
|
wxFALLTHROUGH;
|
||||||
|
|
||||||
case 1:
|
case 1:
|
||||||
// input available -- or maybe not, as select() returns 1 when a
|
// input available -- or maybe not, as select() returns 1 when a
|
||||||
@@ -346,7 +346,7 @@ size_t wxPipeOutputStream::OnSysWrite(const void *buffer, size_t size)
|
|||||||
#endif
|
#endif
|
||||||
// do not treat it as an error
|
// do not treat it as an error
|
||||||
m_file->ClearLastError();
|
m_file->ClearLastError();
|
||||||
// fall through
|
wxFALLTHROUGH;
|
||||||
|
|
||||||
// no error
|
// no error
|
||||||
case 0:
|
case 0:
|
||||||
|
@@ -1560,7 +1560,7 @@ wxString wxXmlResourceHandlerImpl::GetText(const wxString& param, bool translate
|
|||||||
str2 << wxT('\\');
|
str2 << wxT('\\');
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
// else fall-through to default: branch below
|
wxFALLTHROUGH;// else fall-through to default: branch below
|
||||||
|
|
||||||
default:
|
default:
|
||||||
str2 << wxT('\\') << *dt;
|
str2 << wxT('\\') << *dt;
|
||||||
|
Reference in New Issue
Block a user