summaryrefslogtreecommitdiff
path: root/sd/source/ui/func/fuconstr.cxx
diff options
context:
space:
mode:
authorSarper Akdemir <sarper.akdemir.extern@allotropia.de>2023-07-12 17:15:13 +0300
committerThorsten Behrens <thorsten.behrens@allotropia.de>2023-07-21 14:32:16 +0200
commit83f7c6fe5bb233fa9827ff968710822b95562075 (patch)
tree11da6c859f2a95e4015d23cf710ece36d5f94666 /sd/source/ui/func/fuconstr.cxx
parent3a23c6c7a38317794cc7e8894e6a82f4418c8c6d (diff)
tdf#50725: sd: add new configuration option DragThresholdPixels
Adds new expert configuration option DragThresholdPixels for Impress and Draw under Misc/DragThresholdPixels. Also bumps up the previous hardcoded default value from 2 to 6. Assuming this value was set when 640x480 resolution was the most common resolution, currently scaling the hardcoded default by 3 makes sense. (eg. GTK uses 8 pixels as the default) Change-Id: I35c0eed3ce477685c759f517471ce0bdc8315864 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/154379 Tested-by: Jenkins Reviewed-by: Heiko Tietze <heiko.tietze@documentfoundation.org> Reviewed-by: Thorsten Behrens <thorsten.behrens@allotropia.de>
Diffstat (limited to 'sd/source/ui/func/fuconstr.cxx')
-rw-r--r--sd/source/ui/func/fuconstr.cxx4
1 files changed, 2 insertions, 2 deletions
diff --git a/sd/source/ui/func/fuconstr.cxx b/sd/source/ui/func/fuconstr.cxx
index a3ccf35d4f40..36c1f3428a89 100644
--- a/sd/source/ui/func/fuconstr.cxx
+++ b/sd/source/ui/func/fuconstr.cxx
@@ -87,7 +87,7 @@ bool FuConstruct::MouseButtonDown(const MouseEvent& rMEvt)
if ( pHdl != nullptr || mpView->IsMarkedHit(aMDPos, nHitLog) )
{
- sal_uInt16 nDrgLog = sal_uInt16 ( mpWindow->PixelToLogic(Size(DRGPIX,0)).Width() );
+ sal_uInt16 nDrgLog = sal_uInt16 ( mpWindow->PixelToLogic(Size(mpView->GetDragThresholdPixels(),0)).Width() );
mpView->BegDragObj(aMDPos, nullptr, pHdl, nDrgLog);
bReturn = true;
}
@@ -164,7 +164,7 @@ bool FuConstruct::MouseButtonUp(const MouseEvent& rMEvt)
if ( mpView && !mpView->IsAction() )
{
mpWindow->ReleaseMouse();
- sal_uInt16 nDrgLog = sal_uInt16 ( mpWindow->PixelToLogic(Size(DRGPIX,0)).Width() );
+ sal_uInt16 nDrgLog = sal_uInt16 ( mpWindow->PixelToLogic(Size(mpView->GetDragThresholdPixels(),0)).Width() );
if ( !mpView->AreObjectsMarked() )
{