diff options
author | Mathias Bauer <mba@openoffice.org> | 2010-07-13 14:38:37 +0200 |
---|---|---|
committer | Mathias Bauer <mba@openoffice.org> | 2010-07-13 14:38:37 +0200 |
commit | 0266406fef116fbed7b8e69e309bcda0df4896dd (patch) | |
tree | 7d08d330d7ee76707ab4eb757a60fe2559178957 /sc/source/ui/inc | |
parent | 4a02c63d1431b2e8686a035e119c4a2f5c972592 (diff) | |
parent | 686b7955271806e65222a3a4bfe97365cab33a06 (diff) |
CWS changehid: resync to m84
Diffstat (limited to 'sc/source/ui/inc')
-rw-r--r-- | sc/source/ui/inc/AccessibleContextBase.hxx | 2 | ||||
-rw-r--r-- | sc/source/ui/inc/docfunc.hxx | 4 | ||||
-rwxr-xr-x[-rw-r--r--] | sc/source/ui/inc/docsh.hxx | 14 | ||||
-rw-r--r-- | sc/source/ui/inc/dpcontrol.hxx | 4 | ||||
-rw-r--r-- | sc/source/ui/inc/gridwin.hxx | 20 | ||||
-rw-r--r-- | sc/source/ui/inc/inputhdl.hxx | 4 | ||||
-rw-r--r-- | sc/source/ui/inc/miscdlgs.hrc | 6 | ||||
-rw-r--r-- | sc/source/ui/inc/optdlg.hrc | 1 | ||||
-rw-r--r-- | sc/source/ui/inc/output.hxx | 23 | ||||
-rw-r--r-- | sc/source/ui/inc/spelldialog.hxx | 4 | ||||
-rw-r--r-- | sc/source/ui/inc/tabbgcolordlg.hxx | 80 | ||||
-rw-r--r-- | sc/source/ui/inc/teamdlg.hxx | 53 | ||||
-rw-r--r-- | sc/source/ui/inc/tpcalc.hxx | 1 | ||||
-rw-r--r-- | sc/source/ui/inc/undotab.hxx | 28 | ||||
-rw-r--r-- | sc/source/ui/inc/viewfunc.hxx | 5 | ||||
-rw-r--r-- | sc/source/ui/inc/viewutil.hxx | 4 |
16 files changed, 182 insertions, 71 deletions
diff --git a/sc/source/ui/inc/AccessibleContextBase.hxx b/sc/source/ui/inc/AccessibleContextBase.hxx index 191f56c22d3d..ecfeff96af39 100644 --- a/sc/source/ui/inc/AccessibleContextBase.hxx +++ b/sc/source/ui/inc/AccessibleContextBase.hxx @@ -316,8 +316,6 @@ protected: /// Use this method to set initial Description without notification void SetDescription(const rtl::OUString& rDesc) { msDescription = rDesc; } - void SetRole(sal_Int16 nRole); - /// Reference to the parent object. ::com::sun::star::uno::Reference< ::com::sun::star::accessibility::XAccessible> mxParent; diff --git a/sc/source/ui/inc/docfunc.hxx b/sc/source/ui/inc/docfunc.hxx index df4ff685816f..c92cc082986d 100644 --- a/sc/source/ui/inc/docfunc.hxx +++ b/sc/source/ui/inc/docfunc.hxx @@ -31,6 +31,7 @@ #include <tools/link.hxx> #include "global.hxx" #include "formula/grammar.hxx" +#include "tabbgcolor.hxx" class ScEditEngineDefaulter; class SdrUndoAction; @@ -117,6 +118,9 @@ public: BOOL RenameTable( SCTAB nTab, const String& rName, BOOL bRecord, BOOL bApi ); BOOL DeleteTable( SCTAB nTab, BOOL bRecord, BOOL bApi ); + bool SetTabBgColor( SCTAB nTab, const Color& rColor, bool bRecord, bool bApi ); + bool SetTabBgColor( ScUndoTabColorInfo::List& rUndoTabColorList, bool bRecord, bool bApi ); + BOOL SetTableVisible( SCTAB nTab, BOOL bVisible, BOOL bApi ); BOOL SetLayoutRTL( SCTAB nTab, BOOL bRTL, BOOL bApi ); diff --git a/sc/source/ui/inc/docsh.hxx b/sc/source/ui/inc/docsh.hxx index 09d34c661995..5b4fc6227225 100644..100755 --- a/sc/source/ui/inc/docsh.hxx +++ b/sc/source/ui/inc/docsh.hxx @@ -125,7 +125,7 @@ class SC_DLLPUBLIC ScDocShell: public SfxObjectShell, public SfxListener SC_DLLPRIVATE void InitItems(); SC_DLLPRIVATE void DoEnterHandler(); - SC_DLLPRIVATE void InitOptions(); + SC_DLLPRIVATE void InitOptions(bool bForLoading); SC_DLLPRIVATE void ResetDrawObjectShell(); // SUNWS needs a forward declared friend, otherwise types and members @@ -418,8 +418,20 @@ public: sal_Bool AcceptStateUpdate() const; //-->Added by PengYunQuan for Validity Cell Range Picker ScSheetSaveData* GetSheetSaveData(); + + // passwword protection for Calc (derived from SfxObjectShell) + // see also: FID_CHG_RECORD, SID_CHG_PROTECT + virtual bool IsChangeRecording() const; + virtual bool HasChangeRecordProtection() const; + virtual void SetChangeRecording( bool bActivate ); + virtual bool SetProtectionPassword( const String &rPassword ); + virtual bool GetProtectionHash( /*out*/ ::com::sun::star::uno::Sequence< sal_Int8 > &rPasswordHash ); }; + +void UpdateAcceptChangesDialog(); + + SO2_DECL_REF(ScDocShell) SO2_IMPL_REF(ScDocShell) diff --git a/sc/source/ui/inc/dpcontrol.hxx b/sc/source/ui/inc/dpcontrol.hxx index 40e6167aee48..15f0c9174cc8 100644 --- a/sc/source/ui/inc/dpcontrol.hxx +++ b/sc/source/ui/inc/dpcontrol.hxx @@ -76,7 +76,6 @@ public: void draw(); void getPopupBoundingBox(Point& rPos, Size& rSize) const; - bool isPopupButton() const; private: void drawPopupButton(); @@ -127,9 +126,6 @@ public: void selectMenuItem(size_t nPos, bool bSelected, bool bSubMenuTimer); void clearSelectedMenuItem(); ScMenuFloatingWindow* getSubMenuWindow(size_t nPos) const; - size_t getMenuItemCount() const; - ::rtl::OUString getMenuItemName(size_t nPos) const; - bool isMenuItemEnabled(size_t nPos) const; bool isMenuItemSelected(size_t nPos) const; size_t getSelectedMenuItem() const; diff --git a/sc/source/ui/inc/gridwin.hxx b/sc/source/ui/inc/gridwin.hxx index 4d6ef782aed6..a2283bf2b7de 100644 --- a/sc/source/ui/inc/gridwin.hxx +++ b/sc/source/ui/inc/gridwin.hxx @@ -39,6 +39,7 @@ #include <vector> #include <memory> +#include <boost/shared_ptr.hpp> // --------------------------------------------------------------------------- @@ -112,6 +113,25 @@ private: ::sdr::overlay::OverlayObjectList* mpOOHeader; ::sdr::overlay::OverlayObjectList* mpOOShrink; + ::boost::shared_ptr<Rectangle> mpAutoFillRect; + + /** + * Stores current visible column and row ranges, used to avoid expensive + * operations on objects that are outside visible area. + */ + struct VisibleRange + { + SCCOL mnCol1; + SCCOL mnCol2; + SCROW mnRow1; + SCROW mnRow2; + + VisibleRange(); + + bool isInside(SCCOL nCol, SCROW nRow) const; + }; + VisibleRange maVisibleRange; + private: ScViewData* pViewData; ScSplitPos eWhich; diff --git a/sc/source/ui/inc/inputhdl.hxx b/sc/source/ui/inc/inputhdl.hxx index bcc5ba0dd396..61974cf7464d 100644 --- a/sc/source/ui/inc/inputhdl.hxx +++ b/sc/source/ui/inc/inputhdl.hxx @@ -68,7 +68,9 @@ private: TypedScStrCollection* pColumnData; TypedScStrCollection* pFormulaData; TypedScStrCollection* pFormulaDataPara; + Window* pTipVisibleParent; ULONG nTipVisible; + Window* pTipVisibleSecParent; ULONG nTipVisibleSec; String aManualTip; String aAutoSearch; @@ -149,6 +151,8 @@ private: BOOL CursorAtClosingPar(); void SkipClosingPar(); DECL_LINK( ModifyHdl, void* ); + DECL_LINK( ShowHideTipVisibleParentListener, VclWindowEvent* ); + DECL_LINK( ShowHideTipVisibleSecParentListener, VclWindowEvent* ); #endif public: diff --git a/sc/source/ui/inc/miscdlgs.hrc b/sc/source/ui/inc/miscdlgs.hrc index 908a6bd2221c..becd05165a4e 100644 --- a/sc/source/ui/inc/miscdlgs.hrc +++ b/sc/source/ui/inc/miscdlgs.hrc @@ -181,3 +181,9 @@ #define BTN_GROUP_ROWS 3 #define STR_GROUP 1 #define STR_UNGROUP 2 + +// Tab Bg Color +#define TAB_BG_COLOR_CT_BORDER 1 +#define TAB_BG_COLOR_SET_BGDCOLOR 2 +#define TAB_BG_COLOR_GB_BGDCOLOR 3 + diff --git a/sc/source/ui/inc/optdlg.hrc b/sc/source/ui/inc/optdlg.hrc index 00cfdb2c6d5a..27b8976e3541 100644 --- a/sc/source/ui/inc/optdlg.hrc +++ b/sc/source/ui/inc/optdlg.hrc @@ -70,6 +70,7 @@ #define BTN_MATCH 18 #define BTN_LOOKUP 19 #define BTN_REGEX 20 +#define BTN_GENERAL_PREC 21 // TP_VIEW: #define BTN_VSCROLL 1 diff --git a/sc/source/ui/inc/output.hxx b/sc/source/ui/inc/output.hxx index 8d512898afd3..42844513af92 100644 --- a/sc/source/ui/inc/output.hxx +++ b/sc/source/ui/inc/output.hxx @@ -73,6 +73,15 @@ class ScOutputData { friend class ScDrawStringsVars; private: + struct OutputAreaParam + { + Rectangle maAlignRect; + Rectangle maClipRect; + long mnColWidth; + bool mbLeftClip; + bool mbRightClip; + }; + OutputDevice* pDev; // Device OutputDevice* pRefDevice; // printer if used for preview OutputDevice* pFmtDevice; // reference for text formatting @@ -152,19 +161,19 @@ private: void GetVisibleCell( SCCOL nCol, SCROW nRow, SCTAB nTab, ScBaseCell*& rpCell ); BOOL IsAvailable( SCCOL nX, SCROW nY ); + void GetOutputArea( SCCOL nX, SCSIZE nArrY, long nPosX, long nPosY, - SCCOL nCellX, SCROW nCellY, long nNeeded, - const ScPatternAttr& rPattern, - USHORT nHorJustify, BOOL bCellIsValue, - BOOL bBreak, BOOL bOverwrite, - Rectangle& rAlignRect, Rectangle& rClipRect, - BOOL& rLeftClip, BOOL& rRightClip ); + SCCOL nCellX, SCROW nCellY, long nNeeded, + const ScPatternAttr& rPattern, + USHORT nHorJustify, bool bCellIsValue, + bool bBreak, bool bOverwrite, + OutputAreaParam& rParam ); void ShrinkEditEngine( EditEngine& rEngine, const Rectangle& rAlignRect, long nLeftM, long nTopM, long nRightM, long nBottomM, BOOL bWidth, USHORT nOrient, long nAttrRotate, BOOL bPixelToLogic, long& rEngineWidth, long& rEngineHeight, long& rNeededPixel, - BOOL& rLeftClip, BOOL& rRightClip ); + bool& rLeftClip, bool& rRightClip ); void SetSyntaxColor( Font* pFont, ScBaseCell* pCell ); void SetEditSyntaxColor( EditEngine& rEngine, ScBaseCell* pCell ); diff --git a/sc/source/ui/inc/spelldialog.hxx b/sc/source/ui/inc/spelldialog.hxx index af97519a2b43..eef0d170c2c8 100644 --- a/sc/source/ui/inc/spelldialog.hxx +++ b/sc/source/ui/inc/spelldialog.hxx @@ -65,12 +65,12 @@ protected: next sentence with spelling errors. While doing so the view mode may be changed and text shapes are set into edit mode. */ - virtual ::svx::SpellPortions GetNextWrongSentence(); + virtual ::svx::SpellPortions GetNextWrongSentence( bool bRecheck ); /** This method is responsible for merging corrections made in the spelling dialog back into the document. */ - virtual void ApplyChangedSentence( const ::svx::SpellPortions& rChanged ); + virtual void ApplyChangedSentence( const ::svx::SpellPortions& rChanged, bool bRecheck ); virtual void GetFocus(); virtual void LoseFocus(); diff --git a/sc/source/ui/inc/tabbgcolordlg.hxx b/sc/source/ui/inc/tabbgcolordlg.hxx new file mode 100644 index 000000000000..8f26395937b5 --- /dev/null +++ b/sc/source/ui/inc/tabbgcolordlg.hxx @@ -0,0 +1,80 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2008 by Sun Microsystems, Inc. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * $RCSfile: tabbgcolordlg.hxx,v $ + * $Revision: 1.0 $ + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ + +#ifndef SC_TABBGCOLORDLG_HXX +#define SC_TABBGCOLORDLG_HXX + +#include <vcl/dialog.hxx> +#include <vcl/fixed.hxx> +#include <vcl/imagebtn.hxx> +#include <svtools/valueset.hxx> + +//------------------------------------------------------------------------ + +class ScTabBgColorDlg : public ModalDialog +{ +public: + ScTabBgColorDlg( Window* pParent, + const String& rTitle, + const String& rTabBgColorNoColorText, + const Color& rDefaultColor, + const rtl::OString& nHelpId ); + ~ScTabBgColorDlg(); + + void GetSelectedColor( Color& rColor ) const; + +private: + class ScTabBgColorValueSet : public ValueSet + { + public: + ScTabBgColorValueSet(Control* pParent, const ResId& rResId, ScTabBgColorDlg* pTabBgColorDlg); + + virtual void KeyInput( const KeyEvent& rKEvt ); + private: + ScTabBgColorDlg* aTabBgColorDlg; + }; + + Control aBorderWin; + ScTabBgColorValueSet aTabBgColorSet; + FixedLine aTabBgColorBox; + OKButton aBtnOk; + CancelButton aBtnCancel; + HelpButton aBtnHelp; + Color aTabBgColor; + const String aTabBgColorNoColorText; + rtl::OString msHelpId; + + void FillColorValueSets_Impl(); + + DECL_LINK( TabBgColorDblClickHdl_Impl, ValueSet* ); + DECL_LINK( TabBgColorOKHdl_Impl, OKButton* pBtn ); +}; + +#endif // SC_TABBGCOLORDLG_HXX diff --git a/sc/source/ui/inc/teamdlg.hxx b/sc/source/ui/inc/teamdlg.hxx deleted file mode 100644 index 9f44f06c4b12..000000000000 --- a/sc/source/ui/inc/teamdlg.hxx +++ /dev/null @@ -1,53 +0,0 @@ -/************************************************************************* - * - * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. - * - * Copyright 2000, 2010 Oracle and/or its affiliates. - * - * OpenOffice.org - a multi-platform office productivity suite - * - * This file is part of OpenOffice.org. - * - * OpenOffice.org is free software: you can redistribute it and/or modify - * it under the terms of the GNU Lesser General Public License version 3 - * only, as published by the Free Software Foundation. - * - * OpenOffice.org is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU Lesser General Public License version 3 for more details - * (a copy is included in the LICENSE file that accompanied this code). - * - * You should have received a copy of the GNU Lesser General Public License - * version 3 along with OpenOffice.org. If not, see - * <http://www.openoffice.org/license.html> - * for a copy of the LGPLv3 License. - * - ************************************************************************/ - -#ifndef SC_TEAMDLG_HXX -#define SC_TEAMDLG_HXX - - -#include <vcl/floatwin.hxx> -#include <vcl/fixed.hxx> - - -//======================================================================== - -class ScTeamDlg : public FloatingWindow -{ -public: - ScTeamDlg( Window* pParent ); - ~ScTeamDlg(); - - virtual BOOL Close(); - void Center(); - -private: - FixedBitmap aBmpTeam; -}; - - -#endif - diff --git a/sc/source/ui/inc/tpcalc.hxx b/sc/source/ui/inc/tpcalc.hxx index ea9e53a23ee4..31f2c9458c83 100644 --- a/sc/source/ui/inc/tpcalc.hxx +++ b/sc/source/ui/inc/tpcalc.hxx @@ -76,6 +76,7 @@ private: CheckBox aBtnMatch; CheckBox aBtnRegex; CheckBox aBtnLookUp; + CheckBox aBtnGeneralPrec; FixedText aFtPrec; NumericField aEdPrec; diff --git a/sc/source/ui/inc/undotab.hxx b/sc/source/ui/inc/undotab.hxx index 276ea3d7e204..c8d135070ab1 100644 --- a/sc/source/ui/inc/undotab.hxx +++ b/sc/source/ui/inc/undotab.hxx @@ -32,6 +32,7 @@ #include "markdata.hxx" #include "formula/grammar.hxx" #include <tools/color.hxx> +#include "tabbgcolor.hxx" #ifndef _SVSTDARR_SHORTS @@ -223,6 +224,33 @@ private: void DoChange() const; }; +class ScUndoTabColor: public ScSimpleUndo +{ +public: + TYPEINFO(); + ScUndoTabColor( + ScDocShell* pNewDocShell, + SCTAB nT, + const Color& aOTabBgColor, + const Color& aNTabBgColor); + ScUndoTabColor( + ScDocShell* pNewDocShell, + const ScUndoTabColorInfo::List& rUndoTabColorList); + virtual ~ScUndoTabColor(); + + virtual void Undo(); + virtual void Redo(); + virtual void Repeat(SfxRepeatTarget& rTarget); + virtual BOOL CanRepeat(SfxRepeatTarget& rTarget) const; + +virtual String GetComment() const; + +private: + ScUndoTabColorInfo::List aTabColorList; + bool bIsMultipleUndo; + + void DoChange(bool bUndoType) const; +}; class ScUndoMakeScenario: public ScSimpleUndo { diff --git a/sc/source/ui/inc/viewfunc.hxx b/sc/source/ui/inc/viewfunc.hxx index 21feb272c339..59da2966cc60 100644 --- a/sc/source/ui/inc/viewfunc.hxx +++ b/sc/source/ui/inc/viewfunc.hxx @@ -29,6 +29,8 @@ #include "tabview.hxx" +#include "tabbgcolor.hxx" + #ifndef _SVSTDARR_SHORTS #define _SVSTDARR_SHORTS #include <svl/svstdarr.hxx> @@ -273,6 +275,9 @@ public: SCTAB nCount, const SCTAB* pSrcTabs, BOOL bLink,SCTAB nTab); + bool SetTabBgColor( const Color& rColor, SCTAB nTabNr ); + bool SetTabBgColor( ScUndoTabColorInfo::List& rUndoSetTabBgColorInfoList ); + void InsertTableLink( const String& rFile, const String& rFilter, const String& rOptions, const String& rTabName ); diff --git a/sc/source/ui/inc/viewutil.hxx b/sc/source/ui/inc/viewutil.hxx index 8b103d3761d8..eb1c6df2f902 100644 --- a/sc/source/ui/inc/viewutil.hxx +++ b/sc/source/ui/inc/viewutil.hxx @@ -68,10 +68,10 @@ public: static sal_Int32 GetTransliterationType( USHORT nSlotID ); - static bool HasFiltered( const ScRange& rRange, const ScDocument* pDoc ); + static bool HasFiltered( const ScRange& rRange, ScDocument* pDoc ); /** Fit a range to cover nRows number of unfiltered rows. @return <TRUE/> if the resulting range covers nRows unfiltered rows. */ - static bool FitToUnfilteredRows( ScRange & rRange, const ScDocument * pDoc, size_t nRows ); + static bool FitToUnfilteredRows( ScRange & rRange, ScDocument * pDoc, size_t nRows ); static void UnmarkFiltered( ScMarkData& rMark, ScDocument* pDoc ); static void HideDisabledSlot( SfxItemSet& rSet, SfxBindings& rBindings, USHORT nSlotId ); |