diff options
author | Oliver Specht <os@openoffice.org> | 2002-08-09 07:54:15 +0000 |
---|---|---|
committer | Oliver Specht <os@openoffice.org> | 2002-08-09 07:54:15 +0000 |
commit | eebfc1b18cdeea3e476169e00e8178dfccd329fa (patch) | |
tree | 4db7172e7a2140e08afe20878423a69f673fbbc7 | |
parent | 7b903a6a4ee2565e4010c1f2b3d2139254417dbc (diff) |
#100905# chaining of frames in frame dialog enabled
-rw-r--r-- | sw/inc/cmdid.h | 6 | ||||
-rw-r--r-- | sw/inc/fesh.hxx | 14 | ||||
-rw-r--r-- | sw/source/core/frmedt/fefly1.cxx | 91 | ||||
-rw-r--r-- | sw/source/core/frmedt/feshview.cxx | 11 | ||||
-rw-r--r-- | sw/source/ui/chrdlg/break.cxx | 8 | ||||
-rw-r--r-- | sw/source/ui/frmdlg/frmpage.cxx | 164 | ||||
-rw-r--r-- | sw/source/ui/frmdlg/frmpage.hrc | 8 | ||||
-rw-r--r-- | sw/source/ui/inc/frmpage.hxx | 9 | ||||
-rw-r--r-- | sw/source/ui/inc/uitool.hxx | 6 | ||||
-rw-r--r-- | sw/source/ui/utlui/uitool.cxx | 8 |
10 files changed, 273 insertions, 52 deletions
diff --git a/sw/inc/cmdid.h b/sw/inc/cmdid.h index 4d0f3b045f04..c79aa1b3867f 100644 --- a/sw/inc/cmdid.h +++ b/sw/inc/cmdid.h @@ -2,9 +2,9 @@ * * $RCSfile: cmdid.h,v $ * - * $Revision: 1.37 $ + * $Revision: 1.38 $ * - * last change: $Author: os $ $Date: 2002-08-07 09:29:30 $ + * last change: $Author: os $ $Date: 2002-08-09 08:51:29 $ * * The Contents of this file are made available subject to the terms of * either of the following licenses @@ -1150,6 +1150,8 @@ Achtung: Ab sofort sind in diesem File keine C++-Kommentare (//) mehr #define FN_ANCHOR_POSITION (FN_PARAM2+18) /* AnchorPosition property */ #define FN_DROP_TEXT (FN_PARAM2+18) /* text set in drop caps tab page - for recording */ #define FN_DROP_CHAR_STYLE_NAME (FN_PARAM2+19) /* character style of drop caps - for recording */ +#define FN_PARAM_CHAIN_PREVIOUS (FN_PARAM2+20) /* Name of frame to be added as chain successor */ +#define FN_PARAM_CHAIN_NEXT (FN_PARAM2+21) /* Name of frame to be added as chain predecessor */ /*-------------------------------------------------------------------- Bereich: Druckoptionen --------------------------------------------------------------------*/ diff --git a/sw/inc/fesh.hxx b/sw/inc/fesh.hxx index 243ebb22ca76..64fdbad6832a 100644 --- a/sw/inc/fesh.hxx +++ b/sw/inc/fesh.hxx @@ -2,9 +2,9 @@ * * $RCSfile: fesh.hxx,v $ * - * $Revision: 1.15 $ + * $Revision: 1.16 $ * - * last change: $Author: mib $ $Date: 2002-08-09 08:40:25 $ + * last change: $Author: os $ $Date: 2002-08-09 08:52:07 $ * * The Contents of this file are made available subject to the terms of * either of the following licenses @@ -71,6 +71,8 @@ #include <flyenum.hxx> #endif +#include <vector> + class SwFlyFrm; class SvEmbeddedObject; class SwTabCols; @@ -416,6 +418,7 @@ public: //In rRect wird das Rect des Flys geliefert (fuer Highlight desselben) int Chainable( SwRect &rRect, const SwFrmFmt &rSource, const Point &rPt ) const; int Chain( SwFrmFmt &rSource, const Point &rPt ); + int Chain( SwFrmFmt &rSource, const SwFrmFmt &rDest ); void Unchain( SwFrmFmt &rFmt ); void HideChainMarker(); void SetChainMarker(); @@ -666,6 +669,13 @@ public: USHORT GetCurOutColNum( SwGetCurColNumPara* pPara = 0 ) const; // aktuelle aeussere Spalte // Die Breite des aktuellen Bereichs fuer Spaltendialog long GetSectionWidth( SwFmt& rFmt ) const; + + void GetConnectableFrmFmts + (const SwFrmFmt & rFmt, const String & rReference, BOOL bSuccessors, + ::std::vector< String > & aPrevPageVec, + ::std::vector< String > & aThisPageVec, + ::std::vector< String > & aNextPageVec, + ::std::vector< String > & aRestVec); }; #endif diff --git a/sw/source/core/frmedt/fefly1.cxx b/sw/source/core/frmedt/fefly1.cxx index ee4cdf28dc63..be8edeb033c2 100644 --- a/sw/source/core/frmedt/fefly1.cxx +++ b/sw/source/core/frmedt/fefly1.cxx @@ -2,9 +2,9 @@ * * $RCSfile: fefly1.cxx,v $ * - * $Revision: 1.3 $ + * $Revision: 1.4 $ * - * last change: $Author: jp $ $Date: 2001-03-08 21:23:32 $ + * last change: $Author: os $ $Date: 2002-08-09 08:54:15 $ * * The Contents of this file are made available subject to the terms of * either of the following licenses @@ -186,6 +186,9 @@ #ifndef _FLYFRMS_HXX #include <flyfrms.hxx> #endif +#ifndef _FLYPOS_HXX +#include <flypos.hxx> +#endif #ifndef _FLDBAS_HXX #include <fldbas.hxx> #endif @@ -1919,4 +1922,88 @@ sal_Bool SwFEShell::ReplaceSdrObj( const String& rGrfName, const String& rFltNam return bRet; } +static USHORT SwFmtGetPageNum(const SwFlyFrmFmt * pFmt) +{ + ASSERT(pFmt != NULL, "invalid argument"); + + SwFlyFrm * pFrm = pFmt->GetFrm(); + + USHORT aResult; + + if (pFrm != NULL) + aResult = pFrm->GetPhyPageNum(); + else + aResult = pFmt->GetAnchor().GetPageNum(); + + return aResult; +} + +void SwFEShell::GetConnectableFrmFmts +(const SwFrmFmt & rFmt, const String & rReference, BOOL bSuccessors, + ::std::vector< String > & aPrevPageVec, + ::std::vector< String > & aThisPageVec, + ::std::vector< String > & aNextPageVec, + ::std::vector< String > & aRestVec) +{ + ::std::vector< String > aResult; + + SwPosFlyFrms aAllFlys; + pDoc->GetAllFlyFmts(aAllFlys); + sal_uInt16 nCnt = aAllFlys.Count(); + + /* potential successors resp. predecessors */ + ::std::vector< const SwFrmFmt * > aTmpSpzArray; + + for (sal_uInt16 n = 0; n < nCnt; n++) + { + const SwFrmFmt & rFmt1 = aAllFlys[n]->GetFmt(); + + /* + pFmt is a potential successor of rFmt if it is chainable after + rFmt. + + pFmt is a potential predecessor of rFmt if rFmt is chainable + after pFmt. + */ + if ((bSuccessors && pDoc->Chainable(rFmt, rFmt1) == SW_CHAIN_OK) || + (! bSuccessors && pDoc->Chainable(rFmt1, rFmt) == SW_CHAIN_OK)) + aTmpSpzArray.push_back(&rFmt1); + } + + if (aTmpSpzArray.size() > 0) + { + aPrevPageVec.clear(); + aThisPageVec.clear(); + aNextPageVec.clear(); + aRestVec.clear(); + + /* number of page rFmt resides on */ + USHORT nPageNum = SwFmtGetPageNum((SwFlyFrmFmt *) &rFmt); + + ::std::vector< const SwFrmFmt * >::const_iterator aIt; + + for (aIt = aTmpSpzArray.begin(); aIt != aTmpSpzArray.end(); aIt++) + { + String aString = (*aIt)->GetName(); + + /* rFmt is not a vaild successor or predecessor of + itself */ + if (aString != rReference && aString != rFmt.GetName()) + { + USHORT nNum1 = + SwFmtGetPageNum((SwFlyFrmFmt *) *aIt); + + if (nNum1 == nPageNum -1) + aPrevPageVec.push_back(aString); + else if (nNum1 == nPageNum) + aThisPageVec.push_back(aString); + else if (nNum1 == nPageNum + 1) + aNextPageVec.push_back(aString); + else + aRestVec.push_back(aString); + } + } + + } +} diff --git a/sw/source/core/frmedt/feshview.cxx b/sw/source/core/frmedt/feshview.cxx index 0ed404a23e43..e6824d084c14 100644 --- a/sw/source/core/frmedt/feshview.cxx +++ b/sw/source/core/frmedt/feshview.cxx @@ -2,9 +2,9 @@ * * $RCSfile: feshview.cxx,v $ * - * $Revision: 1.11 $ + * $Revision: 1.12 $ * - * last change: $Author: os $ $Date: 2002-06-28 09:06:05 $ + * last change: $Author: os $ $Date: 2002-08-09 08:54:15 $ * * The Contents of this file are made available subject to the terms of * either of the following licenses @@ -2645,6 +2645,13 @@ int SwFEShell::Chainable( SwRect &rRect, const SwFrmFmt &rSource, } return SW_CHAIN_NOT_FOUND; } +/* -----------------------------09.08.2002 07:40------------------------------ + + ---------------------------------------------------------------------------*/ +int SwFEShell::Chain( SwFrmFmt &rSource, const SwFrmFmt &rDest ) +{ + return GetDoc()->Chain(rSource, rDest); +} int SwFEShell::Chain( SwFrmFmt &rSource, const Point &rPt ) { diff --git a/sw/source/ui/chrdlg/break.cxx b/sw/source/ui/chrdlg/break.cxx index b83447107ef3..5227bfe41923 100644 --- a/sw/source/ui/chrdlg/break.cxx +++ b/sw/source/ui/chrdlg/break.cxx @@ -2,9 +2,9 @@ * * $RCSfile: break.cxx,v $ * - * $Revision: 1.6 $ + * $Revision: 1.7 $ * - * last change: $Author: mba $ $Date: 2002-07-01 08:53:44 $ + * last change: $Author: os $ $Date: 2002-08-09 08:53:30 $ * * The Contents of this file are made available subject to the terms of * either of the following licenses @@ -241,14 +241,14 @@ SwBreakDlg::SwBreakDlg( Window *pParent, SwWrtShell &rS ) : for(USHORT i = 0; i < nCount; ++i) { const SwPageDesc &rPageDesc = rSh.GetPageDesc(i); - ::InsertStringSorted(rPageDesc.GetName(), aPageCollBox, TRUE ); + ::InsertStringSorted(rPageDesc.GetName(), aPageCollBox, 1 ); } String aFmtName; for(i = RES_POOLPAGE_BEGIN; i <= RES_POOLPAGE_REGISTER; ++i) if(LISTBOX_ENTRY_NOTFOUND == aPageCollBox.GetEntryPos( aFmtName = SwStyleNameMapper::GetUIName( i, aFmtName ))) - ::InsertStringSorted(aFmtName, aPageCollBox, TRUE ); + ::InsertStringSorted(aFmtName, aPageCollBox, 1 ); CheckEnable(); aPageNumEdit.SetText( aEmptyStr ); diff --git a/sw/source/ui/frmdlg/frmpage.cxx b/sw/source/ui/frmdlg/frmpage.cxx index d017bf41d1e4..da8dfb1ad305 100644 --- a/sw/source/ui/frmdlg/frmpage.cxx +++ b/sw/source/ui/frmdlg/frmpage.cxx @@ -2,9 +2,9 @@ * * $RCSfile: frmpage.cxx,v $ * - * $Revision: 1.20 $ + * $Revision: 1.21 $ * - * last change: $Author: os $ $Date: 2002-06-26 10:31:06 $ + * last change: $Author: os $ $Date: 2002-08-09 08:53:01 $ * * The Contents of this file are made available subject to the terms of * either of the following licenses @@ -533,7 +533,34 @@ USHORT lcl_GetFrmMapCount(FrmMap* pMap) } return 0; } +/* -----------------------------08.08.2002 14:45------------------------------ + ---------------------------------------------------------------------------*/ +void lcl_InsertVectors(ListBox& rBox, + const ::std::vector< String >& rPrev, const ::std::vector< String >& rThis, + const ::std::vector< String >& rNext, const ::std::vector< String >& rRemain) +{ + ::std::vector< const String >::iterator aIt; + for(aIt = rPrev.begin(); aIt != rPrev.end(); aIt++) + rBox.InsertEntry(*aIt); + for(aIt = rThis.begin(); aIt != rThis.end(); aIt++) + rBox.InsertEntry(*aIt); + for(aIt = rNext.begin(); aIt != rNext.end(); aIt++) + rBox.InsertEntry(*aIt); + rBox.SetEntryData( + rBox.InsertEntry(String::CreateFromAscii("-------------")), (void*)(ULONG)1); + //now insert all strings sorted + USHORT nStartPos = rBox.GetEntryCount(); + + for(aIt = rPrev.begin(); aIt != rPrev.end(); aIt++) + ::InsertStringSorted(*aIt, rBox, nStartPos ); + for(aIt = rThis.begin(); aIt != rThis.end(); aIt++) + ::InsertStringSorted(*aIt, rBox, nStartPos ); + for(aIt = rNext.begin(); aIt != rNext.end(); aIt++) + ::InsertStringSorted(*aIt, rBox, nStartPos ); + for(aIt = rRemain.begin(); aIt != rRemain.end(); aIt++) + ::InsertStringSorted(*aIt, rBox, nStartPos ); +} /*-------------------------------------------------------------------- Beschreibung: --------------------------------------------------------------------*/ @@ -2673,9 +2700,9 @@ SwFrmAddPage::SwFrmAddPage(Window *pParent, const SfxItemSet &rSet ) : aAltNameFT (this, SW_RES(FT_ALT_NAME)), aAltNameED (this, SW_RES(ED_ALT_NAME)), aPrevFT (this, SW_RES(FT_PREV)), - aPrevED (this, SW_RES(ED_PREV)), + aPrevLB (this, SW_RES(LB_PREV)), aNextFT (this, SW_RES(FT_NEXT)), - aNextED (this, SW_RES(ED_NEXT)), + aNextLB (this, SW_RES(LB_NEXT)), aNamesFL (this, SW_RES(FL_NAME)), aTextFlowFT (this, SW_RES(FT_TEXTFLOW)), aTextFlowLB (this, SW_RES(LB_TEXTFLOW)), @@ -2790,9 +2817,9 @@ void SwFrmAddPage::Reset(const SfxItemSet &rSet ) Window* aWindows[] = { &aPrevFT, - &aPrevED, + &aPrevLB, &aNextFT, - &aNextED, + &aNextLB, &aNamesFL, &aProtectContentCB, &aProtectFrameCB, @@ -2826,32 +2853,54 @@ void SwFrmAddPage::Reset(const SfxItemSet &rSet ) { const SwFmtChain &rChain = pFmt->GetChain(); const SwFlyFrmFmt* pFlyFmt; - + String sNextChain, sPrevChain; if ((pFlyFmt = rChain.GetPrev()) != 0) { - aPrevED.SetText(pFlyFmt->GetName()); - bNoPrev = FALSE; + sPrevChain = pFlyFmt->GetName(); } if ((pFlyFmt = rChain.GetNext()) != 0) { - aNextED.SetText(pFlyFmt->GetName()); - bNoNext = FALSE; + sNextChain = pFlyFmt->GetName(); } - } - } + //determine chainable frames + ::std::vector< String > aPrevPageFrames; + ::std::vector< String > aThisPageFrames; + ::std::vector< String > aNextPageFrames; + ::std::vector< String > aRemainFrames; + pWrtSh->GetConnectableFrmFmts(*pFmt, sPrevChain, TRUE, + aPrevPageFrames, aThisPageFrames, aNextPageFrames, aRemainFrames ); + lcl_InsertVectors(aPrevLB, aPrevPageFrames, aThisPageFrames, aNextPageFrames, aRemainFrames); + if(sPrevChain.Len()) + { + if(LISTBOX_ENTRY_NOTFOUND == aPrevLB.GetEntryPos(sPrevChain)) + aPrevLB.InsertEntry(sPrevChain, 1); + aPrevLB.SelectEntry(sPrevChain); + } + else + aPrevLB.SelectEntryPos(0); + aPrevPageFrames.erase(aPrevPageFrames.begin(), aPrevPageFrames.end()); + aNextPageFrames.erase(aNextPageFrames.begin(), aNextPageFrames.end()); + aThisPageFrames.erase(aThisPageFrames.begin(), aThisPageFrames.end()); + aRemainFrames.erase(aRemainFrames.begin(), aRemainFrames.end()); - if (bNoPrev) - { - aPrevFT.Disable(); - aPrevED.Disable(); - } - if (bNoNext) - { - aNextFT.Disable(); - aNextED.Disable(); - } + pWrtSh->GetConnectableFrmFmts(*pFmt, sNextChain, FALSE, + aPrevPageFrames, aThisPageFrames, aNextPageFrames, aRemainFrames ); + lcl_InsertVectors(aNextLB, aPrevPageFrames, aThisPageFrames, aNextPageFrames, aRemainFrames); + if(sNextChain.Len()) + { + if(LISTBOX_ENTRY_NOTFOUND == aNextLB.GetEntryPos(sNextChain)) + aNextLB.InsertEntry(sNextChain, 1); + aNextLB.SelectEntry(sNextChain); + } + else + aNextLB.SelectEntryPos(0); + Link aLink(LINK(this, SwFrmAddPage, ChainModifyHdl)); + aPrevLB.SetSelectHdl(aLink); + aNextLB.SetSelectHdl(aLink); + } + } // Pos Protected const SvxProtectItem& rProt = (const SvxProtectItem& )rSet.Get(RES_PROTECT); aProtectFrameCB.Check(rProt.IsPosProtected()); @@ -2929,7 +2978,30 @@ BOOL SwFrmAddPage::FillItemSet(SfxItemSet &rSet) (SvxFrameDirection)nPos, RES_FRAMEDIR )); } } + if(pWrtSh) + { + const SwFrmFmt* pFmt = pWrtSh->GetFlyFrmFmt(); + if (pFmt) + { + String sCurrentPrevChain, sCurrentNextChain; + if(aPrevLB.GetSelectEntryPos()) + sCurrentPrevChain = aPrevLB.GetSelectEntry(); + if(aNextLB.GetSelectEntryPos()) + sCurrentNextChain = aNextLB.GetSelectEntry(); + const SwFmtChain &rChain = pFmt->GetChain(); + const SwFlyFrmFmt* pFlyFmt; + String sNextChain, sPrevChain; + if ((pFlyFmt = rChain.GetPrev()) != 0) + sPrevChain = pFlyFmt->GetName(); + if ((pFlyFmt = rChain.GetNext()) != 0) + sNextChain = pFlyFmt->GetName(); + if(sPrevChain != sCurrentPrevChain) + bRet |= 0 != rSet.Put(SfxStringItem(FN_PARAM_CHAIN_PREVIOUS, sCurrentPrevChain)); + if(sNextChain != sCurrentNextChain) + bRet |= 0 != rSet.Put(SfxStringItem(FN_PARAM_CHAIN_NEXT, sCurrentNextChain)); + } + } return bRet; } @@ -2965,9 +3037,9 @@ void SwFrmAddPage::SetFormatUsed(BOOL bFmt) aAltNameFT.Show(FALSE); aAltNameED.Show(FALSE); aPrevFT.Show(FALSE); - aPrevED.Show(FALSE); + aPrevLB.Show(FALSE); aNextFT.Show(FALSE); - aNextED.Show(FALSE); + aNextLB.Show(FALSE); aNamesFL.Show(FALSE); sal_Int32 nDiff = aExtFL.GetPosPixel().Y() - aNamesFL.GetPosPixel().Y(); @@ -2989,5 +3061,47 @@ void SwFrmAddPage::SetFormatUsed(BOOL bFmt) lcl_Move(*aWindows[nIdx++], nDiff); } } +/* -----------------------------08.08.2002 16:24------------------------------ + + ---------------------------------------------------------------------------*/ +IMPL_LINK(SwFrmAddPage, ChainModifyHdl, ListBox*, pBox) +{ + //prevent the selection of the separator + if(pBox->GetEntryData(pBox->GetSelectEntryPos())) + pBox->SelectEntryPos(0); + else + { + String sCurrentPrevChain, sCurrentNextChain; + if(aPrevLB.GetSelectEntryPos()) + sCurrentPrevChain = aPrevLB.GetSelectEntry(); + if(aNextLB.GetSelectEntryPos()) + sCurrentNextChain = aNextLB.GetSelectEntry(); + const SwFrmFmt* pFmt = pWrtSh->GetFlyFrmFmt(); + if (pFmt) + { + BOOL bNextBox = &aNextLB == pBox; + ListBox& rChangeLB = bNextBox ? aPrevLB : aNextLB; + for(USHORT nEntry = rChangeLB.GetEntryCount(); nEntry > 1; nEntry--) + rChangeLB.RemoveEntry(nEntry - 1); + //determine chainable frames + ::std::vector< String > aPrevPageFrames; + ::std::vector< String > aThisPageFrames; + ::std::vector< String > aNextPageFrames; + ::std::vector< String > aRemainFrames; + pWrtSh->GetConnectableFrmFmts(*pFmt, bNextBox ? sCurrentNextChain : sCurrentPrevChain, !bNextBox, + aPrevPageFrames, aThisPageFrames, aNextPageFrames, aRemainFrames ); + lcl_InsertVectors(rChangeLB, + aPrevPageFrames, aThisPageFrames, aNextPageFrames, aRemainFrames); + String sToSelect = bNextBox ? sCurrentPrevChain : sCurrentNextChain; + if(rChangeLB.GetEntryPos(sToSelect) != LISTBOX_ENTRY_NOTFOUND) + rChangeLB.SelectEntry(sToSelect); + else + rChangeLB.SelectEntryPos(0); + + } + } + + return 0; +} diff --git a/sw/source/ui/frmdlg/frmpage.hrc b/sw/source/ui/frmdlg/frmpage.hrc index 4cd7c3aed806..4f8781430708 100644 --- a/sw/source/ui/frmdlg/frmpage.hrc +++ b/sw/source/ui/frmdlg/frmpage.hrc @@ -2,9 +2,9 @@ * * $RCSfile: frmpage.hrc,v $ * - * $Revision: 1.5 $ + * $Revision: 1.6 $ * - * last change: $Author: jp $ $Date: 2002-01-21 17:52:33 $ + * last change: $Author: os $ $Date: 2002-08-09 08:53:01 $ * * The Contents of this file are made available subject to the terms of * either of the following licenses @@ -129,9 +129,9 @@ #define FT_ALT_NAME 112 #define ED_ALT_NAME 113 #define FT_PREV 114 -#define ED_PREV 115 +#define LB_PREV 115 #define FT_NEXT 116 -#define ED_NEXT 117 +#define LB_NEXT 117 #define FL_NAME 118 #define CB_PROTECT_CONTENT 119 #define CB_PROTECT_FRAME 120 diff --git a/sw/source/ui/inc/frmpage.hxx b/sw/source/ui/inc/frmpage.hxx index dbeab3cdbbd8..e8a34c7523e1 100644 --- a/sw/source/ui/inc/frmpage.hxx +++ b/sw/source/ui/inc/frmpage.hxx @@ -2,9 +2,9 @@ * * $RCSfile: frmpage.hxx,v $ * - * $Revision: 1.8 $ + * $Revision: 1.9 $ * - * last change: $Author: jp $ $Date: 2002-01-21 17:56:02 $ + * last change: $Author: os $ $Date: 2002-08-09 08:52:39 $ * * The Contents of this file are made available subject to the terms of * either of the following licenses @@ -289,9 +289,9 @@ class SwFrmAddPage : public SfxTabPage FixedText aAltNameFT; Edit aAltNameED; FixedText aPrevFT; - Edit aPrevED; + ListBox aPrevLB; FixedText aNextFT; - Edit aNextED; + ListBox aNextLB; FixedLine aNamesFL; CheckBox aProtectContentCB; @@ -314,6 +314,7 @@ class SwFrmAddPage : public SfxTabPage BOOL bNew; DECL_LINK(EditModifyHdl, Edit*); + DECL_LINK(ChainModifyHdl, ListBox*); SwFrmAddPage(Window *pParent, const SfxItemSet &rSet); ~SwFrmAddPage(); diff --git a/sw/source/ui/inc/uitool.hxx b/sw/source/ui/inc/uitool.hxx index 159162ebaf49..6cc43ee8cd42 100644 --- a/sw/source/ui/inc/uitool.hxx +++ b/sw/source/ui/inc/uitool.hxx @@ -2,9 +2,9 @@ * * $RCSfile: uitool.hxx,v $ * - * $Revision: 1.4 $ + * $Revision: 1.5 $ * - * last change: $Author: jp $ $Date: 2001-04-27 17:53:21 $ + * last change: $Author: os $ $Date: 2002-08-09 08:52:40 $ * * The Contents of this file are made available subject to the terms of * either of the following licenses @@ -126,7 +126,7 @@ BOOL GetFileFilterNameDlg( Window& rParent, String& rFileName, // ListBox mit allen Zeichenvorlagen fuellen - ausser Standard! void FillCharStyleListBox(ListBox& rToFill, SwDocShell* pDocSh, BOOL bSorted = FALSE); //inserts a string sorted into a ListBox, -USHORT InsertStringSorted(const String& rEntry, ListBox& rToFill, BOOL bHasOffset); +USHORT InsertStringSorted(const String& rEntry, ListBox& rToFill, USHORT nOffset); // Tabellenbreite und Ausrichtung ermitteln SwTwips GetTableWidth( SwFrmFmt* pFmt, SwTabCols& rCols, USHORT *pPercent, diff --git a/sw/source/ui/utlui/uitool.cxx b/sw/source/ui/utlui/uitool.cxx index 166a39f05907..adccb0408ba5 100644 --- a/sw/source/ui/utlui/uitool.cxx +++ b/sw/source/ui/utlui/uitool.cxx @@ -2,9 +2,9 @@ * * $RCSfile: uitool.cxx,v $ * - * $Revision: 1.8 $ + * $Revision: 1.9 $ * - * last change: $Author: jp $ $Date: 2001-07-31 16:04:06 $ + * last change: $Author: os $ $Date: 2002-08-09 08:53:58 $ * * The Contents of this file are made available subject to the terms of * either of the following licenses @@ -790,9 +790,9 @@ BOOL GetFileFilterNameDlg( Window& rParent, String& rFileName, /*-----------------09.04.98 16:58------------------- --------------------------------------------------*/ -USHORT InsertStringSorted(const String& rEntry, ListBox& rToFill, BOOL bHasOffset ) +USHORT InsertStringSorted(const String& rEntry, ListBox& rToFill, USHORT nOffset ) { - USHORT i = bHasOffset ? 1 : 0; + USHORT i = nOffset; CollatorWrapper& rCaseColl = ::GetAppCaseCollator(); for( ; i < rToFill.GetEntryCount(); i++ ) |