if ( dx != 0 || dy != 0 )
{
rViewShell.ScrollLines(2*dx, 4*dy);
aScrollTimer.Start();
}
}
// Timer handler for window scrolling
IMPL_LINK_NOARG(FuPoor, ScrollHdl, Timer *, void)
{
Point aPosPixel = pWindow->GetPointerPosPixel();
// use remembered MouseButton state to create correct // MouseEvents for this artificial MouseMove.
MouseMove(MouseEvent(aPosPixel, 1, MouseEventModifiers::NONE, GetMouseButtonCode()));
}
bool FuPoor::MouseButtonUp(const MouseEvent& rMEvt)
{ // remember button state for creation of own MouseEvents
SetMouseButtonCode(rMEvt.GetButtons());
returnfalse;
}
bool FuPoor::MouseButtonDown(const MouseEvent& rMEvt)
{ // remember button state for creation of own MouseEvents
SetMouseButtonCode(rMEvt.GetButtons());
returnfalse;
}
// If we handle a KeyEvent, then the return value is sal_True else FALSE. bool FuPoor::KeyInput(const KeyEvent& /* rKEvt */)
{ returnfalse;
}
sal_uInt8 FuPoor::Command(const CommandEvent& rCEvt)
{ if ( CommandEventId::StartDrag == rCEvt.GetCommand() )
{ // Only if a selection is in Outliner, then Command is allowed // to return sal_True
// Timer-Handler for Drag&Drop
IMPL_LINK_NOARG(FuPoor, DragTimerHdl, Timer *, void)
{ // Calling ExecuteDrag (and that associated reschedule) directly from // the Timer, will confuse the VCL-Timer-Management, if (e.g during Drop) // a new timer is started (e.g ComeBack-Timer of DrawView for // Solid Handles / ModelHasChanged) - the new timer will end with a delay // of the duration of the Drag&Drop. // Therefore Drag&Drop from own event:
// #i33136# fdo#88339 bool FuPoor::doConstructOrthogonal() const
{ // Detect whether we're moving an object or resizing. if (pView->IsDragObj())
{ const SdrHdl* pHdl = pView->GetDragStat().GetHdl(); if (!pHdl || (!pHdl->IsCornerHdl() && !pHdl->IsVertexHdl()))
{ returnfalse;
}
}
// Detect image/media and resize proportionally, but don't constrain movement by default const SdrMarkList& rMarkList = pView->GetMarkedObjectList(); if (rMarkList.GetMarkCount() != 0)
{ if (rMarkList.GetMarkCount() == 1)
{
SdrObjKind aObjIdentifier = rMarkList.GetMark(0)->GetMarkedSdrObj()->GetObjIdentifier(); bool bIsMediaSelected = aObjIdentifier == SdrObjKind::Graphic ||
aObjIdentifier == SdrObjKind::Media ||
aObjIdentifier == SdrObjKind::OLE2;
SdrHdl* pHdl = pView->PickHandle(aMDPos); // Resize proportionally when media is selected and the user drags on a corner if (pHdl) return bIsMediaSelected && pHdl->IsCornerHdl(); return bIsMediaSelected;
}
} elseif (aSfxRequest.GetSlot() == SID_DRAW_XPOLYGON
|| aSfxRequest.GetSlot() == SID_DRAW_XPOLYGON_NOFILL
|| aSfxRequest.GetSlot() == SID_DRAW_XLINE) returntrue;
Die Informationen auf dieser Webseite wurden
nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit,
noch Qualität der bereit gestellten Informationen zugesichert.
Bemerkung:
Die farbliche Syntaxdarstellung und die Messung sind noch experimentell.