sfx2/source/control/templateabstractview.cxx | 7 ++----- sfx2/source/doc/templatedlg.cxx | 2 ++ 2 files changed, 4 insertions(+), 5 deletions(-)
New commits: commit 1ce372eec4dd0e4e807baa7bbf568245b955f99f Author: Cédric Bosdonnat <cedric.bosdon...@free.fr> Date: Wed Jan 9 15:18:17 2013 +0100 Template Manager: filter the results when opening the dialog Change-Id: If6cc5f6d5e502c1fc5da210179263be63fc8c8a6 diff --git a/sfx2/source/control/templateabstractview.cxx b/sfx2/source/control/templateabstractview.cxx index c9ea989..27d37a8 100644 --- a/sfx2/source/control/templateabstractview.cxx +++ b/sfx2/source/control/templateabstractview.cxx @@ -103,7 +103,7 @@ TemplateAbstractView::TemplateAbstractView (Window *pParent, WinBits nWinStyle, : ThumbnailView(pParent,nWinStyle,bDisableTransientChildren), mpItemView(new TemplateView(this)), mbFilteredResults(false), - meFilterOption(FILTER_APP_NONE) + meFilterOption(FILTER_APP_WRITER) { mpItemView->setItemStateHdl(LINK(this,TemplateAbstractView,OverlayItemStateHdl)); } @@ -112,7 +112,7 @@ TemplateAbstractView::TemplateAbstractView(Window *pParent, const ResId &rResId, : ThumbnailView(pParent,rResId,bDisableTransientChildren), mpItemView(new TemplateView(this)), mbFilteredResults(false), - meFilterOption(FILTER_APP_NONE) + meFilterOption(FILTER_APP_WRITER) { mpItemView->setItemStateHdl(LINK(this,TemplateAbstractView,OverlayItemStateHdl)); } @@ -186,9 +186,6 @@ void TemplateAbstractView::showOverlay (bool bVisible) if (mbFilteredResults) { filterItems(ViewFilter_Application(meFilterOption)); - - mbFilteredResults = false; - meFilterOption = FILTER_APP_NONE; } mpItemView->Clear(); diff --git a/sfx2/source/doc/templatedlg.cxx b/sfx2/source/doc/templatedlg.cxx index 4c12338..9a50ba9 100644 --- a/sfx2/source/doc/templatedlg.cxx +++ b/sfx2/source/doc/templatedlg.cxx @@ -191,6 +191,8 @@ SfxTemplateManagerDlg::SfxTemplateManagerDlg (Window *parent) maView->Populate(); maView->Show(); + mpCurView->filterTemplatesByApp(FILTER_APP_WRITER); + FreeResource(); }
_______________________________________________ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits