diff options
author | Jens-Heiner Rechtien <hr@openoffice.org> | 2009-01-02 15:51:45 +0000 |
---|---|---|
committer | Jens-Heiner Rechtien <hr@openoffice.org> | 2009-01-02 15:51:45 +0000 |
commit | 19f251c29311c23f071cc02fdaa6efd6917922a0 (patch) | |
tree | dcdd660d7eab7c6622efd45ac1baef869fd71c0f /sw/inc/PostItMgr.hxx | |
parent | 16160041500efcc4cc8ad9b77e7c6aa90c0d1acc (diff) |
CWS-TOOLING: integrate CWS notes7
2008-12-29 19:45:08 +0100 mod r265824 : CWS-TOOLING: rebase CWS notes7 to trunk@265758 (milestone: DEV300:m38)
2008-12-16 14:54:42 +0100 mod r265544 : #i97239#
2008-12-16 14:53:18 +0100 mod r265543 : #i97239#
2008-12-16 13:36:43 +0100 mod r265537 : 96602
2008-12-13 13:02:54 +0100 mba r265452 : warning fixed
2008-12-13 08:20:21 +0100 mod r265448 : search inside notes
2008-12-13 00:11:47 +0100 mod r265447 : search inside notes
2008-12-13 00:11:09 +0100 mod r265446 : search inside notes
2008-12-13 00:10:52 +0100 mod r265445 : search inside notes
2008-12-12 19:39:14 +0100 mod r265439 : search inside notes
2008-12-12 19:02:44 +0100 mod r265438 : search inside notes
2008-12-12 16:42:07 +0100 mba r265431 : #i80135#: search in notes
2008-12-12 16:11:54 +0100 mba r265429 : #i80135#: search in notes
2008-12-12 16:11:02 +0100 mba r265428 : #i80135#: search in notes
2008-12-11 20:24:20 +0100 pb r265358 : fix: #i80135# fixes for aNotesBtn
2008-12-11 20:23:19 +0100 pb r265357 : fix: #i80135# fixes for aNotesBtn
2008-12-11 07:42:17 +0100 pb r265241 : fix: #i80135# CB_NOTES added
2008-12-11 07:40:36 +0100 pb r265240 : fix: #i80135# CB_NOTES added
2008-12-11 07:32:03 +0100 pb r265239 : fix: #i80135# CheckBox aNotesBtn added
2008-12-11 07:24:45 +0100 pb r265238 : fix: #i80135# CheckBox aNotesBtn added
2008-12-10 15:41:31 +0100 mod r265198 : crash using replies
2008-12-10 15:21:23 +0100 mod r265195 : crash using replies
2008-12-10 13:45:14 +0100 mba r265181 : warning fixed
2008-12-10 13:26:45 +0100 mba r265178 : warning fixed
2008-12-10 11:48:23 +0100 mba r265162 : fixed compilation error on Linux
2008-12-03 18:39:07 +0100 mod r264806 : we don't get the Ctrl-Alt-N on mac inside a note, let's do the whole reply thing using the shell, cleaner anyway
2008-12-03 17:13:59 +0100 mod r264802 : search dialog can be started and closed when focus is inside a note
2008-12-03 00:07:08 +0100 mod r264733 : search inside notes
2008-12-02 18:06:08 +0100 mod r264729 : WaE
2008-12-02 15:01:26 +0100 mod r264703 : WaE
2008-12-02 00:20:14 +0100 mod r264644 : WaE
2008-12-01 10:06:14 +0100 mod r264587 : WaE
2008-12-01 01:28:34 +0100 mod r264585 : WaE
2008-11-30 22:51:19 +0100 mod r264584 : search inside notes
2008-11-30 17:03:04 +0100 mod r264583 : search inside notes
2008-11-28 16:30:05 +0100 mod r264560 : #i96602#
2008-11-28 16:14:50 +0100 mod r264559 : test
2008-11-28 16:11:37 +0100 mod r264558 : test
2008-11-17 17:46:10 +0100 mod r263735 : WaE
2008-11-17 17:45:56 +0100 mod r263734 : WaE
2008-11-17 17:37:35 +0100 mod r263733 : revert manual fix for icu
2008-11-17 15:03:55 +0100 mod r263726 : manual fix for icu
2008-11-17 11:17:49 +0100 mod r263707 : manual fix for icu
2008-11-14 15:51:19 +0100 mod r263679 : fix
2008-11-14 14:48:02 +0100 mod r263676 : some more cleanup, redline comments not in the margin for 3.1
2008-11-14 08:37:07 +0100 mod r263664 : end of line missing
2008-11-13 18:36:53 +0100 mod r263660 : WaE
2008-11-13 18:20:04 +0100 mod r263659 : #i94374#
2008-11-13 15:51:28 +0100 mod r263648 : CWS-TOOLING: rebase CWS notes7 to trunk@263288 (milestone: DEV300:m35)
2008-11-13 08:33:19 +0100 mod r263622 : typos
2008-11-02 23:18:19 +0100 mod r263278 : changes notes, replies
2008-11-01 11:48:35 +0100 mod r262873 : replies, comments
2008-11-01 11:44:57 +0100 mod r262872 : notes search button
2008-10-10 14:34:34 +0200 mod r262150 : migration from cvs to svn
2008-10-10 14:33:39 +0200 mod r262149 : migration from cvs to svn
Diffstat (limited to 'sw/inc/PostItMgr.hxx')
-rw-r--r-- | sw/inc/PostItMgr.hxx | 76 |
1 files changed, 44 insertions, 32 deletions
diff --git a/sw/inc/PostItMgr.hxx b/sw/inc/PostItMgr.hxx index 731902105434..ce3b1866007d 100644 --- a/sw/inc/PostItMgr.hxx +++ b/sw/inc/PostItMgr.hxx @@ -7,7 +7,7 @@ * OpenOffice.org - a multi-platform office productivity suite * * $RCSfile: PostItMgr.hxx,v $ - * $Revision: 1.8 $ + * $Revision: 1.8.84.5 $ * * This file is part of OpenOffice.org. * @@ -35,10 +35,13 @@ #include <list> #include <vector> - +#include <svx/outlobj.hxx> +#include <tools/string.hxx> #include <tools/link.hxx> #include <swrect.hxx> +#include <com/sun/star/util/SearchOptions.hpp> + class SwWrtShell; class SwDoc; class SwView; @@ -47,11 +50,13 @@ class SwFmtFld; class SwField; class SfxBroadcaster; class SfxHint; -class SwPostIt; class SwEditWin; class Color; class SvxSearchItem; class SvxLanguageItem; +class SwPostIt; +class SwMarginWin; +class SwMarginItem; #define SORT_POS 1 #define SORT_AUTHOR 2 @@ -60,9 +65,7 @@ class SvxLanguageItem; #define COL_NOTES_SIDEPANE_ARROW_ENABLED RGB_COLORDATA(0,0,0) #define COL_NOTES_SIDEPANE_ARROW_DISABLED RGB_COLORDATA(172,168,153) -struct SwPostItItem; - -typedef std::list<SwPostItItem*> SwPostItItem_list; +typedef std::list<SwMarginItem*> SwMarginItem_list; struct SwPostItPageItem { @@ -70,10 +73,10 @@ struct SwPostItPageItem bool bMarginSide; long lOffset; SwRect mPageRect; - SwPostItItem_list* mList; + SwMarginItem_list* mList; SwPostItPageItem(): bScrollbar(false),lOffset(0) { - mList = new SwPostItItem_list; + mList = new SwMarginItem_list; } ~SwPostItPageItem() { @@ -93,44 +96,42 @@ struct FieldShadowState } }; +typedef std::list<SwMarginItem*>::iterator SwMarginItem_iterator; + class SwPostItMgr: public SfxListener { private: SwView* mpView; SwWrtShell* mpWrtShell; SwEditWin* mpEditWin; - std::list< SwPostItItem*> mvPostItFlds; + std::list< SwMarginItem*> mvPostItFlds; std::vector<SwPostItPageItem*> mPages; ULONG mnEventId; bool mbWaitingForCalcRects; - SwPostIt* mpActivePostIt; + SwMarginWin* mpActivePostIt; bool mbLayout; long mbLayoutHeight; long mbLayouting; bool mbReadOnly; bool mbDeleteNote; FieldShadowState mShadowState; + OutlinerParaObject* mpAnswer; - typedef std::list<SwPostItItem*>::iterator SwPostItItem_iterator; - typedef std::list<SwPostIt*>::iterator SwPostIt_iterator; + typedef std::list<SwMarginWin*>::iterator SwMarginWin_iterator; void AddPostIts(bool bCheckExistance = true,bool bFocus = true); - void RemovePostIts(); + //void AddRedlineComments(bool bCheckExistance, bool bFocus); + void RemoveMarginWin(); void PreparePageContainer(); void Scroll(const long lScroll,const unsigned long aPage ); - void AutoScroll(const SwPostIt* pPostIt,const unsigned long aPage ); + void AutoScroll(const SwMarginWin* pPostIt,const unsigned long aPage ); bool ScrollbarHit(const unsigned long aPage,const Point &aPoint); - bool LayoutByPage(std::list<SwPostIt*> &aVisiblePostItList,const Rectangle aBorder,long lNeededHeight); + bool LayoutByPage(std::list<SwMarginWin*> &aVisiblePostItList,const Rectangle aBorder,long lNeededHeight); void CheckForRemovedPostIts(); bool ArrowEnabled(USHORT aDirection,unsigned long aPage) const; bool BorderOverPageBorder(unsigned long aPage) const; bool HasScrollbars() const; - - void SetColors(SwPostIt* pPostIt, SwPostItField* pFld); - - Color GetColorDark(sal_uInt16 aAuthorIndex); - Color GetColorLight(sal_uInt16 aAuthorIndex); - Color GetColorAnkor(sal_uInt16 aAuthorIndex); + void Focus(SfxBroadcaster& rBC); sal_Int32 GetInitialAnchorDistance() const; sal_Int32 GetScrollSize() const; @@ -144,18 +145,18 @@ class SwPostItMgr: public SfxListener SwPostItMgr(SwView* aDoc); ~SwPostItMgr(); - typedef std::list< SwPostItItem* >::const_iterator const_iterator; + typedef std::list< SwMarginItem* >::const_iterator const_iterator; const_iterator begin() const { return mvPostItFlds.begin(); } const_iterator end() const { return mvPostItFlds.end(); } - void InsertFld( SwFmtFld* aField, bool bCheckExistance, bool bFocus); - void RemoveFld( SfxBroadcaster* pFld ); + void InsertItem( SfxBroadcaster* pItem, bool bCheckExistance, bool bFocus); + void RemoveItem( SfxBroadcaster* pBroadcast ); void Notify( SfxBroadcaster& rBC, const SfxHint& rHint ); void LayoutPostIts(); bool CalcRects(); - void MakeVisible(const SwPostIt* pPostIt,long aPage = -1); + void MakeVisible(const SwMarginWin* pPostIt,long aPage = -1); bool ShowScrollbar(const unsigned long aPage) const; bool HasNotes() const ; @@ -187,24 +188,35 @@ class SwPostItMgr: public SfxListener bool IsHit(const Point &aPointPixel); Color GetArrowColor(USHORT aDirection,unsigned long aPage) const; - SwPostIt* GetNextPostIt(USHORT aDirection, SwPostIt* aPostIt); + SwMarginWin* GetNextPostIt(USHORT aDirection, SwMarginWin* aPostIt); long GetNextBorder(); - SwPostIt* GetActivePostIt() { return mpActivePostIt; } - void SetActivePostIt( SwPostIt* p); + SwMarginWin* GetActivePostIt() { return mpActivePostIt; } + void SetActivePostIt( SwMarginWin* p); sal_Int32 GetMinimumSizeWithMeta() const; sal_Int32 GetSidebarScrollerHeight() const; - SwFmtFld* GetFmtFld(SwPostIt* mpPostIt) const; - SwPostIt* GetPostIt(const SwFmtFld* pFld) const; + SwMarginWin* GetPostIt(const SfxBroadcaster* pBroadcaster) const; + SwMarginWin* GetPostIt(SfxBroadcaster* pBroadcaster) const; SwPostIt* GetPostIt(const SwPostItField* pFld) const; - SwPostIt* GetPostIt(SwFmtFld* pFld) const; SwPostIt* GetPostIt(SwPostItField* pFld) const; void SetShadowState(const SwPostItField* pFld,bool bCursor = true); void SetSpellChecking(); - bool ShowPreview(const SwField* pFld,SwFmtFld*& pFmtFld) const; + Color GetColorDark(sal_uInt16 aAuthorIndex); + Color GetColorLight(sal_uInt16 aAuthorIndex); + Color GetColorAnkor(sal_uInt16 aAuthorIndex); + + bool ShowPreview(const SwField* pFld,SwFmtFld*& pFmtFld) const; + + void RegisterAnswer(OutlinerParaObject* pAnswer) { mpAnswer = pAnswer;} + OutlinerParaObject* IsAnswer() {return mpAnswer;} + + sal_uInt16 Replace(SvxSearchItem* pItem); + void StartSearchAndReplace(const SvxSearchItem& rSearchItem); + sal_uInt16 SearchReplace(const SwFmtFld &pFld, const ::com::sun::star::util::SearchOptions& rSearchOptions,bool bSrchForward); + sal_uInt16 FinishSearchReplace(const ::com::sun::star::util::SearchOptions& rSearchOptions,bool bSrchForward); }; #endif |