diff options
Diffstat (limited to 'sw/source/uibase')
-rw-r--r-- | sw/source/uibase/app/docsh.cxx | 4 | ||||
-rw-r--r-- | sw/source/uibase/app/docshini.cxx | 2 | ||||
-rw-r--r-- | sw/source/uibase/app/docst.cxx | 2 | ||||
-rw-r--r-- | sw/source/uibase/app/docstyle.cxx | 4 | ||||
-rw-r--r-- | sw/source/uibase/dbui/dbmgr.cxx | 2 | ||||
-rw-r--r-- | sw/source/uibase/dialog/SwSpellDialogChildWindow.cxx | 2 | ||||
-rw-r--r-- | sw/source/uibase/dochdl/swdtflvr.cxx | 2 | ||||
-rw-r--r-- | sw/source/uibase/docvw/edtwin.cxx | 15 | ||||
-rw-r--r-- | sw/source/uibase/docvw/edtwin2.cxx | 2 | ||||
-rw-r--r-- | sw/source/uibase/fldui/fldmgr.cxx | 2 | ||||
-rw-r--r-- | sw/source/uibase/ribbar/conrect.cxx | 2 | ||||
-rw-r--r-- | sw/source/uibase/shells/basesh.cxx | 6 | ||||
-rw-r--r-- | sw/source/uibase/shells/drawsh.cxx | 2 | ||||
-rw-r--r-- | sw/source/uibase/shells/drwbassh.cxx | 4 | ||||
-rw-r--r-- | sw/source/uibase/shells/tabsh.cxx | 5 | ||||
-rw-r--r-- | sw/source/uibase/shells/textsh1.cxx | 5 | ||||
-rw-r--r-- | sw/source/uibase/uiview/view.cxx | 2 | ||||
-rw-r--r-- | sw/source/uibase/uiview/view2.cxx | 2 | ||||
-rw-r--r-- | sw/source/uibase/uno/unotxvw.cxx | 5 | ||||
-rw-r--r-- | sw/source/uibase/utlui/content.cxx | 4 | ||||
-rw-r--r-- | sw/source/uibase/wrtsh/wrtsh1.cxx | 2 |
21 files changed, 39 insertions, 37 deletions
diff --git a/sw/source/uibase/app/docsh.cxx b/sw/source/uibase/app/docsh.cxx index c8524558f875..40d5233821d1 100644 --- a/sw/source/uibase/app/docsh.cxx +++ b/sw/source/uibase/app/docsh.cxx @@ -330,7 +330,7 @@ bool SwDocShell::Save() case SfxObjectCreateMode::EMBEDDED: // Suppress SfxProgress, if we are Embedded SW_MOD()->SetEmbeddedLoadSave( true ); - // no break; + SAL_FALLTHROUGH; case SfxObjectCreateMode::STANDARD: case SfxObjectCreateMode::PREVIEW: @@ -1007,7 +1007,7 @@ void SwDocShell::GetState(SfxItemSet& rSet) if ( !aMOpt.IsImpress() ) rSet.DisableItem( nWhich ); } - /* no break here */ + SAL_FALLTHROUGH; case FN_ABSTRACT_NEWDOC: case FN_OUTLINE_TO_CLIPBOARD: { diff --git a/sw/source/uibase/app/docshini.cxx b/sw/source/uibase/app/docshini.cxx index 4a7d0049ac5e..92b239467b04 100644 --- a/sw/source/uibase/app/docshini.cxx +++ b/sw/source/uibase/app/docshini.cxx @@ -531,7 +531,7 @@ bool SwDocShell::Load( SfxMedium& rMedium ) } // suppress SfxProgress, when we are Embedded SW_MOD()->SetEmbeddedLoadSave( true ); - // no break; + SAL_FALLTHROUGH; case SfxObjectCreateMode::STANDARD: case SfxObjectCreateMode::PREVIEW: diff --git a/sw/source/uibase/app/docst.cxx b/sw/source/uibase/app/docst.cxx index c9ec1e470ceb..49feaa8da271 100644 --- a/sw/source/uibase/app/docst.cxx +++ b/sw/source/uibase/app/docst.cxx @@ -335,7 +335,7 @@ void SwDocShell::ExecStyleSheet( SfxRequest& rReq ) } } - // intentionally no break + SAL_FALLTHROUGH; case SID_STYLE_EDIT: case SID_STYLE_DELETE: diff --git a/sw/source/uibase/app/docstyle.cxx b/sw/source/uibase/app/docstyle.cxx index b1795c156462..a4a0a557621c 100644 --- a/sw/source/uibase/app/docstyle.cxx +++ b/sw/source/uibase/app/docstyle.cxx @@ -901,7 +901,7 @@ OUString SwDocStyleSheet::GetDescription(SfxMapUnit eUnit) aItemPresentation = SW_RESSTR(STR_WESTERN_FONT) + aItemPresentation; bHasWesternFontPrefix = true; } - // no break; + SAL_FALLTHROUGH; default: bIsDefault = true; } @@ -2701,7 +2701,7 @@ SfxStyleSheetBase* SwStyleSheetIterator::First() case SWSTYLEBIT_HTML | SFXSTYLEBIT_USERDEF: if(IsPoolUserFormat(nId)) break; - // otherwise move on + SAL_FALLTHROUGH; case SWSTYLEBIT_HTML: if( (nId & COLL_GET_RANGE_BITS) != COLL_HTML_BITS) { diff --git a/sw/source/uibase/dbui/dbmgr.cxx b/sw/source/uibase/dbui/dbmgr.cxx index a5a851f37e32..e19412807cba 100644 --- a/sw/source/uibase/dbui/dbmgr.cxx +++ b/sw/source/uibase/dbui/dbmgr.cxx @@ -446,7 +446,7 @@ bool SwDBManager::Merge( const SwMergeDescriptor& rMergeDesc, vcl::Window* pPare WorkingDocType::SOURCE, rMergeDesc.rSh, nullptr, &pWorkDocOrigDBManager, nullptr, &pWorkShell, &pWorkDoc ); } - // fall through + SAL_FALLTHROUGH; } default: diff --git a/sw/source/uibase/dialog/SwSpellDialogChildWindow.cxx b/sw/source/uibase/dialog/SwSpellDialogChildWindow.cxx index 38bfe02560ef..bde5c24684bd 100644 --- a/sw/source/uibase/dialog/SwSpellDialogChildWindow.cxx +++ b/sw/source/uibase/dialog/SwSpellDialogChildWindow.cxx @@ -685,7 +685,7 @@ bool SwSpellDialogChildWindow::MakeTextSelection_Impl(SwWrtShell& rShell, ShellM rView.AttrChangedNotify(&rShell); break; } - // otherwise no break to deselect the object + SAL_FALLTHROUGH; // to deselect the object case SHELL_MODE_GRAPHIC: case SHELL_MODE_OBJECT: { diff --git a/sw/source/uibase/dochdl/swdtflvr.cxx b/sw/source/uibase/dochdl/swdtflvr.cxx index 8242f70d956a..e39c5765c319 100644 --- a/sw/source/uibase/dochdl/swdtflvr.cxx +++ b/sw/source/uibase/dochdl/swdtflvr.cxx @@ -1646,7 +1646,7 @@ bool SwTransferable::PasteFileContent( TransferableDataHelper& rData, break; } } - // no break - because then test if we get a stream + SAL_FALLTHROUGH; // because then test if we get a stream default: if( rData.GetSotStorageStream( nFormat, xStrm ) ) diff --git a/sw/source/uibase/docvw/edtwin.cxx b/sw/source/uibase/docvw/edtwin.cxx index adcb440ff0c5..8f1ac20a5d00 100644 --- a/sw/source/uibase/docvw/edtwin.cxx +++ b/sw/source/uibase/docvw/edtwin.cxx @@ -1093,7 +1093,8 @@ void SwEditWin::ChangeFly( sal_uInt8 nDir, bool bWeb ) case MOVE_RIGHT_SMALL: if( aTmp.Width() < aSnap.Width() + MINFLY ) break; - nRight = aSnap.Width(); // no break + nRight = aSnap.Width(); + SAL_FALLTHROUGH; case MOVE_RIGHT_HUGE: case MOVE_RIGHT_BIG: aTmp.Left( aTmp.Left() + nRight ); break; @@ -1101,7 +1102,8 @@ void SwEditWin::ChangeFly( sal_uInt8 nDir, bool bWeb ) case MOVE_DOWN_SMALL: if( aTmp.Height() < aSnap.Height() + MINFLY ) break; - nDown = aSnap.Height(); // no break + nDown = aSnap.Height(); + SAL_FALLTHROUGH; case MOVE_DOWN_HUGE: case MOVE_DOWN_BIG: aTmp.Top( aTmp.Top() + nDown ); break; @@ -2412,7 +2414,7 @@ KEYINPUT_CHECKTABLE_INSDEL: break; } aCh = '\t'; - // no break! + SAL_FALLTHROUGH; case KS_InsChar: if (rSh.GetChar(false)==CH_TXT_ATR_FORMELEMENT) { @@ -3480,8 +3482,9 @@ void SwEditWin::MouseButtonDown(const MouseEvent& _rMEvt) default: return; } + + SAL_FALLTHROUGH; } - /* no break */ case MOUSE_LEFT + KEY_SHIFT: case MOUSE_LEFT + KEY_SHIFT + KEY_MOD1: { @@ -4214,8 +4217,8 @@ void SwEditWin::MouseMove(const MouseEvent& _rMEvt) } else m_rView.GetPostItMgr()->SetShadowState(nullptr,false); + SAL_FALLTHROUGH; } - // no break; case KEY_SHIFT: case KEY_MOD2: case KEY_MOD1: @@ -4573,7 +4576,7 @@ void SwEditWin::MouseButtonUp(const MouseEvent& rMEvt) break; } bPopMode = true; - // no break + SAL_FALLTHROUGH; case MOUSE_LEFT + KEY_SHIFT: if (rSh.IsSelFrameMode()) { diff --git a/sw/source/uibase/docvw/edtwin2.cxx b/sw/source/uibase/docvw/edtwin2.cxx index 5f97ff06a9f9..a480b73d47d9 100644 --- a/sw/source/uibase/docvw/edtwin2.cxx +++ b/sw/source/uibase/docvw/edtwin2.cxx @@ -306,7 +306,7 @@ void SwEditWin::RequestHelp(const HelpEvent &rEvt) } case RES_INPUTFLD: // BubbleHelp, because the suggestion could be quite long bBalloon = true; - /* no break */ + SAL_FALLTHROUGH; case RES_JUMPEDITFLD: sText = pField->GetPar2(); break; diff --git a/sw/source/uibase/fldui/fldmgr.cxx b/sw/source/uibase/fldui/fldmgr.cxx index 0b5ef6d1cdff..b8c04d8b5a2a 100644 --- a/sw/source/uibase/fldui/fldmgr.cxx +++ b/sw/source/uibase/fldui/fldmgr.cxx @@ -443,7 +443,7 @@ void SwFieldMgr::GetSubTypes(sal_uInt16 nTypeId, std::vector<OUString>& rToFill) case TYP_INPUTFLD: { rToFill.push_back(SW_RES(aSwFields[nPos].nSubTypeStart)); - // move on at generic types + SAL_FALLTHROUGH; // move on at generic types } case TYP_DDEFLD: case TYP_SEQFLD: diff --git a/sw/source/uibase/ribbar/conrect.cxx b/sw/source/uibase/ribbar/conrect.cxx index 0913d101cf68..8394299cf9f6 100644 --- a/sw/source/uibase/ribbar/conrect.cxx +++ b/sw/source/uibase/ribbar/conrect.cxx @@ -171,7 +171,7 @@ void ConstRectangle::Activate(const sal_uInt16 nSlotId) case SID_DRAW_CAPTION_VERTICAL: bCapVertical = true; - // no break + SAL_FALLTHROUGH; case SID_DRAW_CAPTION: m_pWin->SetSdrDrawMode(OBJ_CAPTION); break; diff --git a/sw/source/uibase/shells/basesh.cxx b/sw/source/uibase/shells/basesh.cxx index f4428173b7f9..680da5088447 100644 --- a/sw/source/uibase/shells/basesh.cxx +++ b/sw/source/uibase/shells/basesh.cxx @@ -229,7 +229,7 @@ void SwBaseShell::ExecDelete(SfxRequest &rReq) break; } - // otherwise call DelLeft + SAL_FALLTHROUGH; // otherwise call DelLeft case FN_SHIFT_BACKSPACE: rSh.DelLeft(); break; @@ -1852,7 +1852,7 @@ void SwBaseShell::SetWrapMode( sal_uInt16 nSlot ) case FN_FRAME_WRAPTHRU_TRANSP: if (aWrap.IsContour()) aWrap.SetContour(false); - // No break!!! + SAL_FALLTHROUGH; case FN_FRAME_WRAPTHRU: nSurround = SURROUND_THROUGHT; break; @@ -1971,8 +1971,8 @@ void SwBaseShell::ExecTextCtrl( SfxRequest& rReq ) if(nInputLang != LANGUAGE_DONTKNOW && nInputLang != LANGUAGE_SYSTEM) nScripts = SvtLanguageOptions::GetScriptTypeOfLanguage( nInputLang ); } + SAL_FALLTHROUGH; } - // fall-through case SID_ATTR_CHAR_POSTURE: case SID_ATTR_CHAR_WEIGHT: { diff --git a/sw/source/uibase/shells/drawsh.cxx b/sw/source/uibase/shells/drawsh.cxx index add32b40a001..6c1fc4360ab9 100644 --- a/sw/source/uibase/shells/drawsh.cxx +++ b/sw/source/uibase/shells/drawsh.cxx @@ -273,7 +273,7 @@ void SwDrawShell::Execute(SfxRequest &rReq) case SID_FLIP_VERTICAL: bMirror = false; - /* no break */ + SAL_FALLTHROUGH; case SID_FLIP_HORIZONTAL: rSh.MirrorSelection( bMirror ); break; diff --git a/sw/source/uibase/shells/drwbassh.cxx b/sw/source/uibase/shells/drwbassh.cxx index 6ebd85b4f153..c06382ed289c 100644 --- a/sw/source/uibase/shells/drwbassh.cxx +++ b/sw/source/uibase/shells/drwbassh.cxx @@ -497,14 +497,14 @@ void SwDrawBaseShell::Execute(SfxRequest &rReq) case FN_FRAME_UP: bTopParam = false; - /* no break */ + SAL_FALLTHROUGH; case SID_FRAME_TO_TOP: pSh->SelectionToTop( bTopParam ); break; case FN_FRAME_DOWN: bBottomParam = false; - /* no break */ + SAL_FALLTHROUGH; case SID_FRAME_TO_BOTTOM: pSh->SelectionToBottom( bBottomParam ); break; diff --git a/sw/source/uibase/shells/tabsh.cxx b/sw/source/uibase/shells/tabsh.cxx index 91199fc84878..ef4d98abd9a7 100644 --- a/sw/source/uibase/shells/tabsh.cxx +++ b/sw/source/uibase/shells/tabsh.cxx @@ -744,7 +744,7 @@ void SwTableShell::Execute(SfxRequest &rReq) { case TBLMERGE_OK: bCallDone = true; - //no break; + SAL_FALLTHROUGH; case TBLMERGE_NOSELECTION: break; case TBLMERGE_TOOCOMPLEX: @@ -925,8 +925,9 @@ void SwTableShell::Execute(SfxRequest &rReq) } nSlot = bColumn ? FN_TABLE_INSERT_COL_DLG : FN_TABLE_INSERT_ROW_DLG; + + SAL_FALLTHROUGH; // on Count = 0 appears the dialog } - // No break; on Count = 0 appears the dialog case FN_TABLE_INSERT_COL_DLG: case FN_TABLE_INSERT_ROW_DLG: { diff --git a/sw/source/uibase/shells/textsh1.cxx b/sw/source/uibase/shells/textsh1.cxx index e105efb0d442..c56621e65f8e 100644 --- a/sw/source/uibase/shells/textsh1.cxx +++ b/sw/source/uibase/shells/textsh1.cxx @@ -861,7 +861,7 @@ void SwTextShell::Execute(SfxRequest &rReq) const sal_uInt16 nWhich = GetPool().GetWhich( nSlot ); if ( pArgs && pArgs->GetItemState( nWhich ) == SfxItemState::SET ) bUseDialog = false; - // intentionally no break + SAL_FALLTHROUGH; } case SID_CHAR_DLG: case SID_CHAR_DLG_EFFECT: @@ -894,8 +894,7 @@ void SwTextShell::Execute(SfxRequest &rReq) const sal_uInt16 nWhich = GetPool().GetWhich( nSlot ); if ( pArgs && pArgs->GetItemState( nWhich ) == SfxItemState::SET ) bUseDialog = false; - // intentionally no break - + SAL_FALLTHROUGH; } case SID_PARA_DLG: { diff --git a/sw/source/uibase/uiview/view.cxx b/sw/source/uibase/uiview/view.cxx index f59e70ac8b43..f02a69116b3b 100644 --- a/sw/source/uibase/uiview/view.cxx +++ b/sw/source/uibase/uiview/view.cxx @@ -1576,7 +1576,7 @@ void SwView::Notify( SfxBroadcaster& rBC, const SfxHint& rHint ) m_pVRuler->SetActive( !bModal ); } - /* no break here */ + SAL_FALLTHROUGH; case SFX_HINT_TITLECHANGED: if ( GetDocShell()->IsReadOnly() != GetWrtShell().GetViewOptions()->IsReadonly() ) diff --git a/sw/source/uibase/uiview/view2.cxx b/sw/source/uibase/uiview/view2.cxx index efb3bee30b5f..939d0f17ce0e 100644 --- a/sw/source/uibase/uiview/view2.cxx +++ b/sw/source/uibase/uiview/view2.cxx @@ -1158,8 +1158,8 @@ void SwView::Execute(SfxRequest &rReq) xDictionary->clear(); // put cursor to the start of the document m_pWrtShell->SttDoc(); + SAL_FALLTHROUGH; // call spell/grammar dialog } - // no break; - but call spell/grammar dialog case FN_SPELL_GRAMMAR_DIALOG: { SfxViewFrame* pViewFrame = GetViewFrame(); diff --git a/sw/source/uibase/uno/unotxvw.cxx b/sw/source/uibase/uno/unotxvw.cxx index c3b98384bc73..8a16929974a1 100644 --- a/sw/source/uibase/uno/unotxvw.cxx +++ b/sw/source/uibase/uno/unotxvw.cxx @@ -343,10 +343,9 @@ uno::Any SwXTextView::getSelection() aRef.set(xCursor, uno::UNO_QUERY); break; } - + SAL_FALLTHROUGH; + // without a table selection the text will be delivered } - //Without a table selection the text will be delivered. - //break; case SHELL_MODE_LIST_TEXT : case SHELL_MODE_TABLE_LIST_TEXT: case SHELL_MODE_TEXT : diff --git a/sw/source/uibase/utlui/content.cxx b/sw/source/uibase/utlui/content.cxx index 072d82b3f1c0..b0324efc7d67 100644 --- a/sw/source/uibase/utlui/content.cxx +++ b/sw/source/uibase/utlui/content.cxx @@ -1784,7 +1784,7 @@ bool SwContentTree::FillTransferData( TransferDataContainer& rTransfer, break; case ContentTypeId::URLFIELD: sUrl = static_cast<SwURLFieldContent*>(pCnt)->GetURL(); - // no break; + SAL_FALLTHROUGH; case ContentTypeId::OLE: case ContentTypeId::GRAPHIC: if(GetParentWindow()->GetRegionDropMode() != RegionMode::NONE) @@ -2232,7 +2232,7 @@ void SwContentTree::ExecCommand(sal_uInt16 nCmd, bool bModifier) case FN_ITEM_DOWN: case FN_ITEM_UP: bMove = true; - //fall-through + SAL_FALLTHROUGH; case FN_ITEM_LEFT: case FN_ITEM_RIGHT: if( !GetWrtShell()->GetView().GetDocShell()->IsReadOnly() && diff --git a/sw/source/uibase/wrtsh/wrtsh1.cxx b/sw/source/uibase/wrtsh/wrtsh1.cxx index 79e18c0c72e0..aa61757607e1 100644 --- a/sw/source/uibase/wrtsh/wrtsh1.cxx +++ b/sw/source/uibase/wrtsh/wrtsh1.cxx @@ -366,7 +366,7 @@ void SwWrtShell::InsertObject( const svt::EmbeddedObjectRef& xRef, SvGlobalName { aServerList.FillInsertObjects(); aServerList.Remove( SwDocShell::Factory().GetClassId() ); - // Intentionally no break! + SAL_FALLTHROUGH; } // TODO/LATER: recording! Convert properties to items |