summaryrefslogtreecommitdiff
path: root/sw/source
diff options
context:
space:
mode:
authorCaolán McNamara <caolanm@redhat.com>2018-08-07 13:44:17 +0100
committerMiklos Vajna <vmiklos@collabora.co.uk>2018-08-14 10:52:21 +0200
commit3fc47cda232e396b026f8f26f56f96e0f65dbccc (patch)
tree791d7deb2e359ef5d33a34e6085073fcc459c875 /sw/source
parentbb95d1843e5812c9f2bbecdff80f59b83be013db (diff)
tdf#119130 only have the active postit as a dialog control...
in which pressing ctrl+tab cycles between text and button so we don't waste time searching thousands of SwAnnotationWins Change-Id: Iba34882c6588fc9414004f0ed3b2b779f77b30d1 Reviewed-on: https://gerrit.libreoffice.org/58683 Tested-by: Jenkins Tested-by: Xisco Faulí <xiscofauli@libreoffice.org> Reviewed-by: Miklos Vajna <vmiklos@collabora.co.uk>
Diffstat (limited to 'sw/source')
-rw-r--r--sw/source/core/fields/postithelper.cxx2
-rw-r--r--sw/source/uibase/docvw/AnnotationWin.cxx3
-rw-r--r--sw/source/uibase/docvw/AnnotationWin2.cxx10
3 files changed, 12 insertions, 3 deletions
diff --git a/sw/source/core/fields/postithelper.cxx b/sw/source/core/fields/postithelper.cxx
index 6858e7e7daf0..2705b773c48c 100644
--- a/sw/source/core/fields/postithelper.cxx
+++ b/sw/source/core/fields/postithelper.cxx
@@ -150,7 +150,7 @@ VclPtr<sw::annotation::SwAnnotationWin> SwAnnotationItem::GetSidebarWindow(
SwEditWin& rEditWin,
SwPostItMgr& aMgr)
{
- return VclPtr<sw::annotation::SwAnnotationWin>::Create( rEditWin, WB_DIALOGCONTROL,
+ return VclPtr<sw::annotation::SwAnnotationWin>::Create( rEditWin,
aMgr,
*this,
&mrFormatField );
diff --git a/sw/source/uibase/docvw/AnnotationWin.cxx b/sw/source/uibase/docvw/AnnotationWin.cxx
index 7fef02cdf522..04056aa50cca 100644
--- a/sw/source/uibase/docvw/AnnotationWin.cxx
+++ b/sw/source/uibase/docvw/AnnotationWin.cxx
@@ -62,11 +62,10 @@
namespace sw { namespace annotation {
SwAnnotationWin::SwAnnotationWin( SwEditWin& rEditWin,
- WinBits nBits,
SwPostItMgr& aMgr,
SwSidebarItem& rSidebarItem,
SwFormatField* aField )
- : Window(&rEditWin, nBits)
+ : Window(&rEditWin)
, maBuilder(nullptr, VclBuilderContainer::getUIRootDir(), "modules/swriter/ui/annotationmenu.ui", "")
, mrMgr(aMgr)
, mrView(rEditWin.GetView())
diff --git a/sw/source/uibase/docvw/AnnotationWin2.cxx b/sw/source/uibase/docvw/AnnotationWin2.cxx
index eaf0b9d07356..57a98016a289 100644
--- a/sw/source/uibase/docvw/AnnotationWin2.cxx
+++ b/sw/source/uibase/docvw/AnnotationWin2.cxx
@@ -1111,10 +1111,20 @@ void SwAnnotationWin::ActivatePostIt()
if ( !Application::GetSettings().GetStyleSettings().GetHighContrastMode() )
GetOutlinerView()->SetBackgroundColor(mColorDark);
+
+ //tdf#119130 only have the active postit as a dialog control in which pressing
+ //ctrl+tab cycles between text and button so we don't waste time searching
+ //thousands of SwAnnotationWins
+ SetStyle(GetStyle() | WB_DIALOGCONTROL);
}
void SwAnnotationWin::DeactivatePostIt()
{
+ //tdf#119130 only have the active postit as a dialog control in which pressing
+ //ctrl+tab cycles between text and button so we don't waste time searching
+ //thousands of SwAnnotationWins
+ SetStyle(GetStyle() & ~WB_DIALOGCONTROL);
+
// remove selection, #i87073#
if (GetOutlinerView()->GetEditView().HasSelection())
{