diff options
author | Matteo Casalin <matteo.casalin@yahoo.com> | 2017-03-19 17:05:49 +0100 |
---|---|---|
committer | Matteo Casalin <matteo.casalin@yahoo.com> | 2017-03-19 17:12:26 +0100 |
commit | 7a2f07c4bd5d26657593044dd441ba5fd168e5de (patch) | |
tree | 940806dcd4d5d3aadfc1a56f88612321325736da /sfx2 | |
parent | e256519a629e88c624c52916f1c38f774cfd445c (diff) |
Use just geParameter instead of hasParameter + getParameter
getParameter returns and empty string if the key is not found,
so we can just avoid searching twice for the same key.
Change-Id: Ic48debce05fe94d8e087b64bde5a589e54bfb616
Diffstat (limited to 'sfx2')
-rw-r--r-- | sfx2/source/view/viewfrm.cxx | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/sfx2/source/view/viewfrm.cxx b/sfx2/source/view/viewfrm.cxx index bd29aaf003f3..a16fda352944 100644 --- a/sfx2/source/view/viewfrm.cxx +++ b/sfx2/source/view/viewfrm.cxx @@ -2416,9 +2416,7 @@ void SfxViewFrame::AddDispatchMacroToBasic_Impl( const OUString& sMacro ) aMacroName = aName.getToken( 0, cTok, nIndex ); // get location - OUString aLocKey("location"); - if ( xUrl->hasParameter( aLocKey ) ) - aLocation = xUrl->getParameter( aLocKey ); + aLocation = xUrl->getParameter( "location" ); } BasicManager* pBasMgr = nullptr; |