diff options
author | Caolán McNamara <caolanm@redhat.com> | 2016-05-25 14:42:05 +0100 |
---|---|---|
committer | Caolán McNamara <caolanm@redhat.com> | 2016-05-25 15:51:31 +0100 |
commit | 86ac0bd31464bd802d4367f2152e7f8e0e9506e9 (patch) | |
tree | a3643b2bd71fdf8daa658e963d7edc92054610a7 /cui | |
parent | 8d1295a104235ce003c9f44fc24072985706290f (diff) |
Window::SetData and Window::GetData are nearly unused now
except for..
a) one use in sw which we can replace with a map
b) one use in svx which didn't do anything
c) one amusing piece of crazy in cui
Change-Id: If66d9f7eab1eaddfb2bdab7815c3a6f22f4d7745
Diffstat (limited to 'cui')
-rw-r--r-- | cui/source/dialogs/about.cxx | 15 |
1 files changed, 2 insertions, 13 deletions
diff --git a/cui/source/dialogs/about.cxx b/cui/source/dialogs/about.cxx index de838b0d2bf5..89e83b5a0dc9 100644 --- a/cui/source/dialogs/about.cxx +++ b/cui/source/dialogs/about.cxx @@ -53,12 +53,6 @@ using namespace ::com::sun::star::uno; using namespace ::com::sun::star::beans; using namespace ::com::sun::star; -enum AboutDialogButton -{ - CREDITS_BUTTON, - WEBSITE_BUTTON -}; - AboutDialog::AboutDialog(vcl::Window* pParent) : SfxModalDialog(pParent, "AboutDialog", "cui/ui/aboutdialog.ui") { @@ -87,10 +81,6 @@ AboutDialog::AboutDialog(vcl::Window* pParent) SetLogo(); - // Allow the button to be identifiable once they are clicked - m_pCreditsButton->SetData( reinterpret_cast<void*>(CREDITS_BUTTON) ); - m_pWebsiteButton->SetData( reinterpret_cast<void*>(WEBSITE_BUTTON) ); - // Connect all handlers m_pCreditsButton->SetClickHdl( LINK( this, AboutDialog, HandleClick ) ); m_pWebsiteButton->SetClickHdl( LINK( this, AboutDialog, HandleClick ) ); @@ -120,10 +110,9 @@ IMPL_LINK_TYPED( AboutDialog, HandleClick, Button*, pButton, void ) OUString sURL = ""; // Find which button was pressed and from this, get the URL to be opened - AboutDialogButton aDialogButton = static_cast<AboutDialogButton>(reinterpret_cast<sal_Int64>(pButton->GetData())); - if ( aDialogButton == CREDITS_BUTTON ) + if (pButton == m_pCreditsButton) sURL = m_aCreditsLinkStr; - else if ( aDialogButton == WEBSITE_BUTTON ) + else if (pButton == m_pWebsiteButton) { sURL = officecfg::Office::Common::Help::StartCenter::InfoURL::get(); localizeWebserviceURI(sURL); |