Kaydet (Commit) 7a25aa28 authored tarafından Cédric Bosdonnat's avatar Cédric Bosdonnat

fdo#61390: Fixed the tabstop in the TemplateView.

Change-Id: I887b11646efb9a839da11cd3e20cdf7e532caf3e
üst a4b4942f
......@@ -54,7 +54,6 @@ private:
Link maOpenHdl;
TemplateAbstractView* mpMasterView;
Control maButtons;
PushButton maAllButton;
FixedText maFTName;
sal_uInt16 mnId;
......
......@@ -115,7 +115,7 @@ bool ViewFilter_Keyword::operator ()(const ThumbnailViewItem *pItem)
TemplateAbstractView::TemplateAbstractView (Window *pParent, WinBits nWinStyle, bool bDisableTransientChildren)
: ThumbnailView(pParent,nWinStyle,bDisableTransientChildren),
mpItemView(new TemplateView(this)),
mpItemView(new TemplateView(pParent)),
mbFilteredResults(false),
meFilterOption(FILTER_APP_WRITER)
{
......@@ -124,7 +124,7 @@ TemplateAbstractView::TemplateAbstractView (Window *pParent, WinBits nWinStyle,
TemplateAbstractView::TemplateAbstractView(Window *pParent, const ResId &rResId, bool bDisableTransientChildren)
: ThumbnailView(pParent,rResId,bDisableTransientChildren),
mpItemView(new TemplateView(this)),
mpItemView(new TemplateView(pParent)),
mbFilteredResults(false),
meFilterOption(FILTER_APP_WRITER)
{
......@@ -186,8 +186,14 @@ void TemplateAbstractView::filterTemplatesByApp (const FILTER_APPLICATION &eApp)
void TemplateAbstractView::showOverlay (bool bVisible)
{
Show(!bVisible);
mpItemView->Show(bVisible);
mpItemView->SetPosSizePixel(GetPosPixel(), GetSizePixel());
mpItemView->SetStyle(GetStyle());
mpItemView->GrabFocus();
// Clear items is the overlay is closed.
if (!bVisible)
{
......
......@@ -34,14 +34,13 @@ using namespace drawinglayer::attribute;
using namespace drawinglayer::primitive2d;
TemplateView::TemplateView (Window *pParent)
: ThumbnailView(pParent,WB_VSCROLL),
: ThumbnailView(pParent,WB_VSCROLL | WB_TABSTOP),
mpMasterView(NULL),
maButtons(this, SfxResId(CONTROL_BUTTONS)),
maAllButton(&maButtons, SfxResId(BTN_ALL_TEMPLATES)),
maFTName(&maButtons, SfxResId(FT_NAME)),
maAllButton(this, SfxResId(BTN_ALL_TEMPLATES)),
maFTName(this, SfxResId(FT_NAME)),
mnId(0)
{
mnHeaderHeight = maButtons.GetSizePixel().getHeight();
mnHeaderHeight = maAllButton.GetSizePixel().getHeight() + maAllButton.GetPosPixel().Y() * 2;
maAllButton.SetStyle(maAllButton.GetStyle() | WB_FLATBUTTON);
}
......@@ -88,13 +87,8 @@ void TemplateView::Resize()
Size aWinSize = GetOutputSize();
// Set the buttons panel and buttons size
Size aPanelSize = maButtons.GetSizePixel();
int nDeltaW = aWinSize.getWidth() - aPanelSize.getWidth();
aPanelSize.setWidth(aWinSize.getWidth());
maButtons.SetSizePixel(aPanelSize);
Size aNameSize = maFTName.GetSizePixel();
aNameSize.setWidth(aNameSize.getWidth() + nDeltaW);
aNameSize.setWidth( aWinSize.getWidth() - maFTName.GetPosPixel().X());
maFTName.SetSizePixel(aNameSize);
ThumbnailView::Resize();
......
......@@ -9,12 +9,6 @@
#include "templateview.hrc"
Control CONTROL_BUTTONS
{
Size = MAP_APPFONT( 290, 17 );
TabStop = False;
};
PushButton BTN_ALL_TEMPLATES
{
Pos = MAP_APPFONT( 1, 1 );
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment