diff options
author | Caolán McNamara <caolanm@redhat.com> | 2016-10-10 15:23:02 +0100 |
---|---|---|
committer | Caolán McNamara <caolanm@redhat.com> | 2016-10-10 15:23:53 +0100 |
commit | e8393d4d91d714b691b101a2062c3e2e7333929b (patch) | |
tree | f6ed6fdccc522da44e1f7f2e99821fa81373d028 /sfx2 | |
parent | 9f7f5b5f911c4e76c88258f6ee3e7d51484f195b (diff) |
de-src standalong PushButton
Change-Id: I6f062e04377fc74ec2fea3ea4390943b715e06d1
Diffstat (limited to 'sfx2')
-rw-r--r-- | sfx2/source/view/view.src | 5 | ||||
-rw-r--r-- | sfx2/source/view/viewfrm.cxx | 8 |
2 files changed, 7 insertions, 6 deletions
diff --git a/sfx2/source/view/view.src b/sfx2/source/view/view.src index 8f0d6c6fdca5..845510a79262 100644 --- a/sfx2/source/view/view.src +++ b/sfx2/source/view/view.src @@ -127,10 +127,9 @@ PushButton BT_CHECKOUT Size = MAP_APPFONT( 30 , 0 ); Text[ en-US ] = "Check Out"; }; -PushButton BT_READONLY_EDIT + +String STR_READONLY_EDIT { - Pos = MAP_APPFONT( 0 , 0 ); - Size = MAP_APPFONT( 70 , 0 ); Text[ en-US ] = "Edit Document"; }; diff --git a/sfx2/source/view/viewfrm.cxx b/sfx2/source/view/viewfrm.cxx index ef4f10d22a82..588a4eb0e8a3 100644 --- a/sfx2/source/view/viewfrm.cxx +++ b/sfx2/source/view/viewfrm.cxx @@ -1224,9 +1224,11 @@ void SfxViewFrame::Notify( SfxBroadcaster& /*rBC*/, const SfxHint& rHint ) SfxInfoBarWindow* pInfoBar = AppendInfoBar("readonly", SfxResId(STR_READONLY_DOCUMENT)); if (pInfoBar) { - VclPtrInstance<PushButton> pBtn( &GetWindow(), SfxResId(BT_READONLY_EDIT)); - pBtn->SetClickHdl(LINK(this, SfxViewFrame, SwitchReadOnlyHandler)); - pInfoBar->addButton(pBtn); + VclPtrInstance<PushButton> xBtn(&GetWindow()); + xBtn->SetText(SfxResId(STR_READONLY_EDIT)); + xBtn->SetSizePixel(xBtn->GetOptimalSize()); + xBtn->SetClickHdl(LINK(this, SfxViewFrame, SwitchReadOnlyHandler)); + pInfoBar->addButton(xBtn); } } |