diff options
author | Jan Holesovsky <kendy@suse.cz> | 2011-03-18 15:40:35 +0100 |
---|---|---|
committer | Jan Holesovsky <kendy@suse.cz> | 2011-03-18 15:40:35 +0100 |
commit | a0c13ffcceea4978bf95b8559bff4a71aa55aa88 (patch) | |
tree | 2adb4d620b027141c5578565d860434657ba0b3c /sd/source/ui/annotations | |
parent | adea34547d7bc43e9795032c7761e293a28c1df7 (diff) | |
parent | 19232495c4985faf1423075bf8814e786da6ddcd (diff) |
Merge remote-tracking branch 'origin/integration/dev300_m101'
Conflicts:
sd/source/ui/func/fuinsfil.cxx
sd/source/ui/func/fuprobjs.cxx
sd/source/ui/slideshow/slideshowimpl.cxx
sd/source/ui/slidesorter/view/SlsPageObjectViewObjectContact.cxx
sd/source/ui/toolpanel/ToolPanelViewShell.cxx
sd/source/ui/view/drawview.cxx
sd/source/ui/view/drtxtob.cxx
sd/source/ui/view/outlnvsh.cxx
sd/source/ui/view/outlview.cxx
Diffstat (limited to 'sd/source/ui/annotations')
-rw-r--r-- | sd/source/ui/annotations/annotationmanager.cxx | 38 | ||||
-rw-r--r-- | sd/source/ui/annotations/annotationmanagerimpl.hxx | 4 | ||||
-rw-r--r-- | sd/source/ui/annotations/annotations.src | 29 | ||||
-rwxr-xr-x[-rw-r--r--] | sd/source/ui/annotations/annotationtag.cxx | 38 | ||||
-rwxr-xr-x[-rw-r--r--] | sd/source/ui/annotations/annotationtag.hxx | 10 | ||||
-rw-r--r-- | sd/source/ui/annotations/annotationwindow.cxx | 24 | ||||
-rw-r--r-- | sd/source/ui/annotations/annotationwindow.hxx | 2 |
7 files changed, 73 insertions, 72 deletions
diff --git a/sd/source/ui/annotations/annotationmanager.cxx b/sd/source/ui/annotations/annotationmanager.cxx index 3aadb8a5ed37..52439cb09282 100644 --- a/sd/source/ui/annotations/annotationmanager.cxx +++ b/sd/source/ui/annotations/annotationmanager.cxx @@ -198,7 +198,7 @@ AnnotationManagerImpl::AnnotationManagerImpl( ViewShellBase& rViewShellBase ) { SdOptions* pOptions = SD_MOD()->GetSdOptions(mpDoc->GetDocumentType()); if( pOptions ) - mbShowAnnotations = pOptions->IsShowComments() == TRUE; + mbShowAnnotations = pOptions->IsShowComments() == sal_True; } // -------------------------------------------------------------------- @@ -340,7 +340,7 @@ void AnnotationManagerImpl::ExecuteDeleteAnnotation(SfxRequest& rReq) if( pArgs ) { const SfxPoolItem* pPoolItem = NULL; - if( SFX_ITEM_SET == pArgs->GetItemState( SID_DELETEALLBYAUTHOR_POSTIT, TRUE, &pPoolItem ) ) + if( SFX_ITEM_SET == pArgs->GetItemState( SID_DELETEALLBYAUTHOR_POSTIT, sal_True, &pPoolItem ) ) { OUString sAuthor( (( const SfxStringItem* ) pPoolItem )->GetValue() ); DeleteAnnotationsByAuthor( sAuthor ); @@ -356,7 +356,7 @@ void AnnotationManagerImpl::ExecuteDeleteAnnotation(SfxRequest& rReq) if( pArgs ) { const SfxPoolItem* pPoolItem = NULL; - if( SFX_ITEM_SET == pArgs->GetItemState( SID_DELETE_POSTIT, TRUE, &pPoolItem ) ) + if( SFX_ITEM_SET == pArgs->GetItemState( SID_DELETE_POSTIT, sal_True, &pPoolItem ) ) ( ( const SfxUnoAnyItem* ) pPoolItem )->GetValue() >>= xAnnotation; } } @@ -460,7 +460,7 @@ void AnnotationManagerImpl::ExecuteReplyToAnnotation( SfxRequest& rReq ) if( pArgs ) { const SfxPoolItem* pPoolItem = NULL; - if( SFX_ITEM_SET == pArgs->GetItemState( rReq.GetSlot(), TRUE, &pPoolItem ) ) + if( SFX_ITEM_SET == pArgs->GetItemState( rReq.GetSlot(), sal_True, &pPoolItem ) ) ( ( const SfxUnoAnyItem* ) pPoolItem )->GetValue() >>= xAnnotation; } @@ -471,7 +471,7 @@ void AnnotationManagerImpl::ExecuteReplyToAnnotation( SfxRequest& rReq ) std::auto_ptr< ::Outliner > pOutliner( new ::Outliner(GetAnnotationPool(),OUTLINERMODE_TEXTOBJECT) ); mpDoc->SetCalcFieldValueHdl( pOutliner.get() ); - pOutliner->SetUpdateMode( TRUE ); + pOutliner->SetUpdateMode( sal_True ); String aStr(SdResId(STR_ANNOTATION_REPLY)); OUString sAuthor( xAnnotation->getAuthor() ); @@ -491,8 +491,8 @@ void AnnotationManagerImpl::ExecuteReplyToAnnotation( SfxRequest& rReq ) aStr.Append( sQuote ); aStr.Append( String(RTL_CONSTASCII_USTRINGPARAM("\"\n") ) ); - USHORT nParaCount = aStr.GetTokenCount( '\n' ); - for( USHORT nPara = 0; nPara < nParaCount; nPara++ ) + sal_uInt16 nParaCount = aStr.GetTokenCount( '\n' ); + for( sal_uInt16 nPara = 0; nPara < nParaCount; nPara++ ) pOutliner->Insert( aStr.GetToken( nPara, '\n' ), LIST_APPEND, -1 ); if( pOutliner->GetParagraphCount() > 1 ) @@ -501,7 +501,7 @@ void AnnotationManagerImpl::ExecuteReplyToAnnotation( SfxRequest& rReq ) aAnswerSet.Put(SvxPostureItem(ITALIC_NORMAL,EE_CHAR_ITALIC)); ESelection aSel; - aSel.nEndPara = (USHORT)pOutliner->GetParagraphCount()-2; + aSel.nEndPara = (sal_uInt16)pOutliner->GetParagraphCount()-2; aSel.nEndPos = pOutliner->GetText( pOutliner->GetParagraph( aSel.nEndPara ) ).Len(); pOutliner->QuickSetAttribs( aAnswerSet, aSel ); @@ -722,7 +722,7 @@ void AnnotationManagerImpl::SelectNextAnnotation(bool bForeward) ::boost::shared_ptr<DrawViewShell> pDrawViewShell(::boost::dynamic_pointer_cast<DrawViewShell>(mrBase.GetMainViewShell())); if (pDrawViewShell.get() != NULL) { - pDrawViewShell->ChangeEditMode(pPage->IsMasterPage() ? EM_MASTERPAGE : EM_PAGE, FALSE); + pDrawViewShell->ChangeEditMode(pPage->IsMasterPage() ? EM_MASTERPAGE : EM_PAGE, sal_False); pDrawViewShell->SwitchPage((pPage->GetPageNum() - 1) >> 1); SfxDispatcher* pDispatcher = getDispatcher( mrBase ); @@ -750,7 +750,7 @@ void AnnotationManagerImpl::SelectNextAnnotation(bool bForeward) WB_YES_NO | WB_DEF_YES, String(SdResId(nStringId))); aQuestionBox.SetImage (QueryBox::GetStandardImage()); - USHORT nBoxResult = aQuestionBox.Execute(); + sal_uInt16 nBoxResult = aQuestionBox.Execute(); if(nBoxResult != BUTTONID_YES) break; } @@ -778,7 +778,7 @@ void AnnotationManagerImpl::onTagDeselected( AnnotationTag& rTag ) // -------------------------------------------------------------------- -void AnnotationManagerImpl::SelectAnnotation( ::com::sun::star::uno::Reference< ::com::sun::star::office::XAnnotation > xAnnotation, bool bEdit /* = FALSE */ ) +void AnnotationManagerImpl::SelectAnnotation( ::com::sun::star::uno::Reference< ::com::sun::star::office::XAnnotation > xAnnotation, bool bEdit /* = sal_False */ ) { mxSelectedAnnotation = xAnnotation; @@ -998,7 +998,7 @@ void AnnotationManagerImpl::ExecuteAnnotationContextMenu( Reference< XAnnotation aStr.SearchAndReplaceAscii("%1", aReplace); pMenu->SetItemText( SID_DELETEALLBYAUTHOR_POSTIT, aStr ); pMenu->EnableItem( SID_REPLYTO_POSTIT, (sAuthor != sCurrentAuthor) && !bReadOnly ); - pMenu->EnableItem( SID_DELETE_POSTIT, (xAnnotation.is() && !bReadOnly) ? TRUE : FALSE ); + pMenu->EnableItem( SID_DELETE_POSTIT, (xAnnotation.is() && !bReadOnly) ? sal_True : sal_False ); pMenu->EnableItem( SID_DELETEALLBYAUTHOR_POSTIT, !bReadOnly ); pMenu->EnableItem( SID_DELETEALL_POSTIT, !bReadOnly ); @@ -1006,11 +1006,11 @@ void AnnotationManagerImpl::ExecuteAnnotationContextMenu( Reference< XAnnotation { if( pAnnotationWindow->IsProtected() || bReadOnly ) { - pMenu->EnableItem( SID_ATTR_CHAR_WEIGHT, FALSE ); - pMenu->EnableItem( SID_ATTR_CHAR_POSTURE, FALSE ); - pMenu->EnableItem( SID_ATTR_CHAR_UNDERLINE, FALSE ); - pMenu->EnableItem( SID_ATTR_CHAR_STRIKEOUT, FALSE ); - pMenu->EnableItem( SID_PASTE, FALSE ); + pMenu->EnableItem( SID_ATTR_CHAR_WEIGHT, sal_False ); + pMenu->EnableItem( SID_ATTR_CHAR_POSTURE, sal_False ); + pMenu->EnableItem( SID_ATTR_CHAR_UNDERLINE, sal_False ); + pMenu->EnableItem( SID_ATTR_CHAR_STRIKEOUT, sal_False ); + pMenu->EnableItem( SID_PASTE, sal_False ); } else { @@ -1046,13 +1046,13 @@ void AnnotationManagerImpl::ExecuteAnnotationContextMenu( Reference< XAnnotation pMenu->EnableItem( SID_COPY, pAnnotationWindow->getView()->HasSelection() ); } - USHORT nId = 0; + sal_uInt16 nId = 0; // set slot images Reference< ::com::sun::star::frame::XFrame > xFrame( mrBase.GetMainViewShell()->GetViewFrame()->GetFrame().GetFrameInterface() ); if( xFrame.is() ) { - for( USHORT nPos = 0; nPos < pMenu->GetItemCount(); nPos++ ) + for( sal_uInt16 nPos = 0; nPos < pMenu->GetItemCount(); nPos++ ) { nId = pMenu->GetItemId( nPos ); if( pMenu->IsItemEnabled( nId ) ) diff --git a/sd/source/ui/annotations/annotationmanagerimpl.hxx b/sd/source/ui/annotations/annotationmanagerimpl.hxx index 0a31dfa0d04e..e9e50e34946e 100644 --- a/sd/source/ui/annotations/annotationmanagerimpl.hxx +++ b/sd/source/ui/annotations/annotationmanagerimpl.hxx @@ -79,7 +79,7 @@ public: void SelectNextAnnotation(bool bForeward); - void SelectAnnotation( ::com::sun::star::uno::Reference< ::com::sun::star::office::XAnnotation > xAnnotation, bool bEdit = FALSE ); + void SelectAnnotation( ::com::sun::star::uno::Reference< ::com::sun::star::office::XAnnotation > xAnnotation, bool bEdit = sal_False ); void GetSelectedAnnotation( ::com::sun::star::uno::Reference< ::com::sun::star::office::XAnnotation >& xAnnotation ); void InsertAnnotation(); @@ -133,7 +133,7 @@ private: ::com::sun::star::uno::Reference< ::com::sun::star::office::XAnnotation > mxSelectedAnnotation; bool mbShowAnnotations; - ULONG mnUpdateTagsEvent; + sal_uLong mnUpdateTagsEvent; Font maFont; }; diff --git a/sd/source/ui/annotations/annotations.src b/sd/source/ui/annotations/annotations.src index 0ca43731d6b0..536d10f9a417 100644 --- a/sd/source/ui/annotations/annotations.src +++ b/sd/source/ui/annotations/annotations.src @@ -28,6 +28,7 @@ #include "annotations.hrc" #include "glob.hrc" #include <svx/svxids.hrc> +#include "helpids.h" Menu RID_ANNOTATION_CONTEXTMENU { @@ -36,7 +37,7 @@ Menu RID_ANNOTATION_CONTEXTMENU MenuItem { Identifier = SID_REPLYTO_POSTIT; - HelpID = SID_REPLYTO_POSTIT ; + HelpId = CMD_SID_REPLYTO_POSTIT ; Text [ en-US ] = "~Reply"; }; MenuItem @@ -46,25 +47,25 @@ Menu RID_ANNOTATION_CONTEXTMENU MenuItem { Identifier = SID_ATTR_CHAR_WEIGHT; - HelpID = SID_ATTR_CHAR_WEIGHT ; + HelpId = CMD_SID_ATTR_CHAR_WEIGHT ; Text [ en-US ] = "~Bold"; }; MenuItem { Identifier = SID_ATTR_CHAR_POSTURE; - HelpID = SID_ATTR_CHAR_POSTURE; + HelpId = CMD_SID_ATTR_CHAR_POSTURE; Text [ en-US ] = "~Italic"; }; MenuItem { Identifier = SID_ATTR_CHAR_UNDERLINE; - HelpID = SID_ATTR_CHAR_UNDERLINE; + HelpId = CMD_SID_ATTR_CHAR_UNDERLINE; Text [ en-US ] = "~Underline"; }; MenuItem { Identifier = SID_ATTR_CHAR_STRIKEOUT; - HelpID = SID_ATTR_CHAR_STRIKEOUT; + HelpId = CMD_SID_ATTR_CHAR_STRIKEOUT; Text [ en-US ] = "~Strikethrough"; }; MenuItem @@ -74,13 +75,13 @@ Menu RID_ANNOTATION_CONTEXTMENU MenuItem { Identifier = SID_COPY ; - HelpID = SID_COPY ; + HelpId = CMD_SID_COPY ; Text [ en-US ] = "~Copy" ; }; MenuItem { Identifier = SID_PASTE ; - HelpID = SID_PASTE ; + HelpId = CMD_SID_PASTE ; Text [ en-US ] = "~Paste" ; }; MenuItem @@ -90,19 +91,19 @@ Menu RID_ANNOTATION_CONTEXTMENU MenuItem { Identifier = SID_DELETE_POSTIT ; - HelpID = SID_DELETE_POSTIT; + HelpId = CMD_SID_DELETE_POSTIT; Text [ en-US ] = "~Delete Comment" ; }; MenuItem { Identifier = SID_DELETEALLBYAUTHOR_POSTIT ; - HelpID = SID_DELETEALLBYAUTHOR_POSTIT; + HelpId = CMD_SID_DELETEALLBYAUTHOR_POSTIT; Text [ en-US ] = "Delete All Comments b~y %1" ; }; MenuItem { Identifier = SID_DELETEALL_POSTIT; - HelpID = SID_DELETEALL_POSTIT; + HelpId = CMD_SID_DELETEALL_POSTIT; Text [ en-US ] = "Delete ~All Comments" ; }; }; @@ -115,7 +116,7 @@ Menu RID_ANNOTATION_TAG_CONTEXTMENU MenuItem { Identifier = SID_REPLYTO_POSTIT; - HelpID = SID_REPLYTO_POSTIT; + HelpId = CMD_SID_REPLYTO_POSTIT; Text [ en-US ] = "~Reply"; }; MenuItem @@ -125,19 +126,19 @@ Menu RID_ANNOTATION_TAG_CONTEXTMENU MenuItem { Identifier = SID_DELETE_POSTIT ; - HelpID = SID_DELETE_POSTIT ; + HelpId = CMD_SID_DELETE_POSTIT ; Text [ en-US ] = "~Delete Comment" ; }; MenuItem { Identifier = SID_DELETEALLBYAUTHOR_POSTIT ; - HelpID = SID_DELETEALLBYAUTHOR_POSTIT ; + HelpId = CMD_SID_DELETEALLBYAUTHOR_POSTIT ; Text [ en-US ] = "Delete All Comments ~by %1" ; }; MenuItem { Identifier = SID_DELETEALL_POSTIT; - HelpID = SID_DELETEALL_POSTIT; + HelpId = CMD_SID_DELETEALL_POSTIT; Text [ en-US ] = "Delete ~All Comments" ; }; }; diff --git a/sd/source/ui/annotations/annotationtag.cxx b/sd/source/ui/annotations/annotationtag.cxx index 4a27c730b0a7..ad03711b5717 100644..100755 --- a/sd/source/ui/annotations/annotationtag.cxx +++ b/sd/source/ui/annotations/annotationtag.cxx @@ -161,7 +161,7 @@ bool AnnotationDragMove::EndSdrDrag(bool /*bCopy*/) Hide(); if( mxTag.is() ) mxTag->Move( DragStat().GetDX(), DragStat().GetDY() ); - return TRUE; + return sal_True; } void AnnotationDragMove::CancelSdrDrag() @@ -177,7 +177,7 @@ public: AnnotationHdl( const SmartTagReference& xTag, const Reference< XAnnotation >& xAnnotation, const Point& rPnt ); virtual ~AnnotationHdl(); virtual void CreateB2dIAObject(); - virtual BOOL IsFocusHdl() const; + virtual sal_Bool IsFocusHdl() const; virtual Pointer GetSdrDragPointer() const; virtual bool isMarkable() const; @@ -250,10 +250,10 @@ void AnnotationHdl::CreateB2dIAObject() pOverlayObject = new ::sdr::overlay::OverlayAnimatedBitmapEx(aPosition, aBitmapEx, aBitmapEx2, nBlinkTime, 0, 0, 0, 0 ); /* - (UINT16)(aBitmapEx.GetSizePixel().Width() - 1) >> 1, - (UINT16)(aBitmapEx.GetSizePixel().Height() - 1) >> 1, - (UINT16)(aBitmapEx2.GetSizePixel().Width() - 1) >> 1, - (UINT16)(aBitmapEx2.GetSizePixel().Height() - 1) >> 1); + (sal_uInt16)(aBitmapEx.GetSizePixel().Width() - 1) >> 1, + (sal_uInt16)(aBitmapEx.GetSizePixel().Height() - 1) >> 1, + (sal_uInt16)(aBitmapEx2.GetSizePixel().Width() - 1) >> 1, + (sal_uInt16)(aBitmapEx2.GetSizePixel().Height() - 1) >> 1); */ } else @@ -273,9 +273,9 @@ void AnnotationHdl::CreateB2dIAObject() // -------------------------------------------------------------------- -BOOL AnnotationHdl::IsFocusHdl() const +sal_Bool AnnotationHdl::IsFocusHdl() const { - return TRUE; + return sal_True; } // -------------------------------------------------------------------- @@ -377,7 +377,7 @@ bool AnnotationTag::KeyInput( const KeyEvent& rKEvt ) if( !mxAnnotation.is() ) return false; - USHORT nCode = rKEvt.GetKeyCode().GetCode(); + sal_uInt16 nCode = rKEvt.GetKeyCode().GetCode(); switch( nCode ) { case KEY_DELETE: @@ -517,31 +517,31 @@ void AnnotationTag::CheckPossibilities() // -------------------------------------------------------------------- -ULONG AnnotationTag::GetMarkablePointCount() const +sal_uLong AnnotationTag::GetMarkablePointCount() const { return 0; } // -------------------------------------------------------------------- -ULONG AnnotationTag::GetMarkedPointCount() const +sal_uLong AnnotationTag::GetMarkedPointCount() const { return 0; } // -------------------------------------------------------------------- -BOOL AnnotationTag::MarkPoint(SdrHdl& /*rHdl*/, BOOL /*bUnmark*/ ) +sal_Bool AnnotationTag::MarkPoint(SdrHdl& /*rHdl*/, sal_Bool /*bUnmark*/ ) { - BOOL bRet=FALSE; + sal_Bool bRet=sal_False; return bRet; } // -------------------------------------------------------------------- -BOOL AnnotationTag::MarkPoints(const Rectangle* /*pRect*/, BOOL /*bUnmark*/ ) +sal_Bool AnnotationTag::MarkPoints(const Rectangle* /*pRect*/, sal_Bool /*bUnmark*/ ) { - BOOL bChgd=FALSE; + sal_Bool bChgd=sal_False; return bChgd; } @@ -638,7 +638,7 @@ BitmapEx AnnotationTag::CreateAnnotationBitmap( bool bSelected ) const int BORDER_Y = 4; // pixels maSize = Size( aVDev.GetTextWidth( sAuthor ) + 2*BORDER_X, aVDev.GetTextHeight() + 2*BORDER_Y ); - aVDev.SetOutputSizePixel( maSize, FALSE ); + aVDev.SetOutputSizePixel( maSize, sal_False ); Color aBorderColor( maColor ); @@ -692,7 +692,7 @@ void AnnotationTag::OpenPopup( bool bEdit ) mpAnnotationWindow->InitControls(); mpAnnotationWindow->setAnnotation(mxAnnotation); - USHORT nArrangeIndex = 0; + sal_uInt16 nArrangeIndex = 0; Point aPopupPos( FloatingWindow::CalcFloatingPosition( mpAnnotationWindow.get(), aRect, FLOATWIN_POPUPMODE_RIGHT, nArrangeIndex ) ); Size aPopupSize( 320, 240 ); @@ -760,7 +760,7 @@ IMPL_LINK(AnnotationTag, WindowEventHandler, VclWindowEvent*, pEvent) if( pHdl ) { mrView.BrkAction(); - const USHORT nDrgLog = (USHORT)pWindow->PixelToLogic(Size(DRGPIX,0)).Width(); + const sal_uInt16 nDrgLog = (sal_uInt16)pWindow->PixelToLogic(Size(DRGPIX,0)).Width(); rtl::Reference< AnnotationTag > xTag( this ); @@ -776,7 +776,7 @@ IMPL_LINK(AnnotationTag, WindowEventHandler, VclWindowEvent*, pEvent) } } } - return TRUE; + return sal_True; } IMPL_LINK( AnnotationTag, ClosePopupHdl, void *, EMPTYARG ) diff --git a/sd/source/ui/annotations/annotationtag.hxx b/sd/source/ui/annotations/annotationtag.hxx index e37ae2057d3f..06875cc26f47 100644..100755 --- a/sd/source/ui/annotations/annotationtag.hxx +++ b/sd/source/ui/annotations/annotationtag.hxx @@ -61,11 +61,11 @@ public: virtual bool Command( const CommandEvent& rCEvt ); // callbacks from sdr view - virtual ULONG GetMarkablePointCount() const; - virtual ULONG GetMarkedPointCount() const; - virtual BOOL MarkPoint(SdrHdl& rHdl, BOOL bUnmark=FALSE); + virtual sal_uLong GetMarkablePointCount() const; + virtual sal_uLong GetMarkedPointCount() const; + virtual sal_Bool MarkPoint(SdrHdl& rHdl, sal_Bool bUnmark=sal_False); virtual void CheckPossibilities(); - virtual BOOL MarkPoints(const Rectangle* pRect, BOOL bUnmark); + virtual sal_Bool MarkPoints(const Rectangle* pRect, sal_Bool bUnmark); void Move( int nDX, int nDY ); bool OnMove( const KeyEvent& rKEvt ); @@ -97,7 +97,7 @@ private: int mnIndex; const Font& mrFont; Size maSize; - ULONG mnClosePopupEvent; + sal_uLong mnClosePopupEvent; ::Window* mpListenWindow; Point maMouseDownPos; }; diff --git a/sd/source/ui/annotations/annotationwindow.cxx b/sd/source/ui/annotations/annotationwindow.cxx index 55a7202b47d1..3feda9f2d4a0 100644 --- a/sd/source/ui/annotations/annotationwindow.cxx +++ b/sd/source/ui/annotations/annotationwindow.cxx @@ -115,11 +115,11 @@ extern OUString getAnnotationDateTimeString( const Reference< XAnnotation >& xAn extern SfxItemPool* GetAnnotationPool(); extern com::sun::star::util::DateTime getCurrentDateTime(); -Color ColorFromAlphaColor(UINT8 aTransparency, Color &aFront, Color &aBack ) +Color ColorFromAlphaColor(sal_uInt8 aTransparency, Color &aFront, Color &aBack ) { - return Color((UINT8)(aFront.GetRed() * aTransparency/(double)255 + aBack.GetRed() * (1-aTransparency/(double)255)), - (UINT8)(aFront.GetGreen() * aTransparency/(double)255 + aBack.GetGreen() * (1-aTransparency/(double)255)), - (UINT8)(aFront.GetBlue() * aTransparency/(double)255 + aBack.GetBlue() * (1-aTransparency/(double)255))); + return Color((sal_uInt8)(aFront.GetRed() * aTransparency/(double)255 + aBack.GetRed() * (1-aTransparency/(double)255)), + (sal_uInt8)(aFront.GetGreen() * aTransparency/(double)255 + aBack.GetGreen() * (1-aTransparency/(double)255)), + (sal_uInt8)(aFront.GetBlue() * aTransparency/(double)255 + aBack.GetBlue() * (1-aTransparency/(double)255))); } /************ AnnotationTextWindow **********************************/ @@ -161,7 +161,7 @@ void AnnotationTextWindow::Paint( const Rectangle& rRect) void AnnotationTextWindow::KeyInput( const KeyEvent& rKeyEvt ) { const KeyCode& rKeyCode = rKeyEvt.GetKeyCode(); - USHORT nKey = rKeyCode.GetCode(); + sal_uInt16 nKey = rKeyCode.GetCode(); if ((rKeyCode.IsMod1() && rKeyCode.IsMod2()) && ((nKey == KEY_PAGEUP) || (nKey == KEY_PAGEDOWN))) { @@ -212,7 +212,7 @@ void AnnotationTextWindow::MouseButtonDown( const MouseEvent& rMEvt ) GrabFocus(); if ( mpOutlinerView ) mpOutlinerView->MouseButtonDown( rMEvt ); - // todo mpOutlinerView->DocView()->GetViewFrame()->GetBindings().InvalidateAll(FALSE); + // todo mpOutlinerView->DocView()->GetViewFrame()->GetBindings().InvalidateAll(sal_False); } void AnnotationTextWindow::MouseButtonUp( const MouseEvent& rMEvt ) @@ -333,7 +333,7 @@ void AnnotationWindow::InitControls() mpOutliner = new ::Outliner(GetAnnotationPool(),OUTLINERMODE_TEXTOBJECT); Doc()->SetCalcFieldValueHdl( mpOutliner ); - mpOutliner->SetUpdateMode( TRUE ); + mpOutliner->SetUpdateMode( sal_True ); Rescale(); OutputDevice* pDev = Doc()->GetRefDevice(); @@ -358,16 +358,16 @@ void AnnotationWindow::InitControls() mpVScrollbar->SetScrollHdl(LINK(this, AnnotationWindow, ScrollHdl)); mpVScrollbar->EnableDrag(); - ULONG nCntrl = mpOutliner->GetControlWord(); + sal_uLong nCntrl = mpOutliner->GetControlWord(); nCntrl |= EE_CNTRL_PASTESPECIAL | EE_CNTRL_AUTOCORRECT | EV_CNTRL_AUTOSCROLL | EE_CNTRL_NOCOLORS; mpOutliner->SetControlWord(nCntrl); Engine()->SetModifyHdl( Link() ); - Engine()->EnableUndo( FALSE ); + Engine()->EnableUndo( sal_False ); Engine()->ClearModifyFlag(); Engine()->GetUndoManager().Clear(); - Engine()->EnableUndo( TRUE ); + Engine()->EnableUndo( sal_True ); Engine()->SetModifyHdl( LINK( this, AnnotationWindow, ModifyHdl ) ); Invalidate(); @@ -486,7 +486,7 @@ void AnnotationWindow::SetLanguage(const SvxLanguageItem aNewItem) Engine()->SetModifyHdl( Link() ); ESelection aOld = getView()->GetSelection(); - ESelection aNewSelection( 0, 0, (USHORT)Engine()->GetParagraphCount()-1, USHRT_MAX ); + ESelection aNewSelection( 0, 0, (sal_uInt16)Engine()->GetParagraphCount()-1, USHRT_MAX ); getView()->SetSelection( aNewSelection ); SfxItemSet aEditAttr(getView()->GetAttribs()); aEditAttr.Put(aNewItem); @@ -774,7 +774,7 @@ void AnnotationWindow::GetFocus() FloatingWindow::GetFocus(); } -void AnnotationWindow::ExecuteSlot( USHORT nSID ) +void AnnotationWindow::ExecuteSlot( sal_uInt16 nSID ) { if( nSID == SID_COPY ) { diff --git a/sd/source/ui/annotations/annotationwindow.hxx b/sd/source/ui/annotations/annotationwindow.hxx index 33efb1e3c2fc..752e5c967e5b 100644 --- a/sd/source/ui/annotations/annotationwindow.hxx +++ b/sd/source/ui/annotations/annotationwindow.hxx @@ -125,7 +125,7 @@ class AnnotationWindow : public FloatingWindow void setAnnotation( const ::com::sun::star::uno::Reference< ::com::sun::star::office::XAnnotation >& xAnnotation, bool bGrabFocus = false ); const ::com::sun::star::uno::Reference< ::com::sun::star::office::XAnnotation >& getAnnotation() const { return mxAnnotation; } - void ExecuteSlot( USHORT nSID ); + void ExecuteSlot( sal_uInt16 nSID ); ScrollBar* Scrollbar() { return mpVScrollbar;} |