diff options
author | Noel Grandin <noel@peralex.com> | 2014-02-25 15:28:04 +0200 |
---|---|---|
committer | Noel Grandin <noel@peralex.com> | 2014-02-26 08:54:53 +0200 |
commit | d7f3dced121ea29f333594bc7a459e564f67f2fc (patch) | |
tree | cd5a56aa9b0db78921833606b74cd09bc48dd700 /sfx2 | |
parent | WaE: implicit conversion of literal of type 'const char *' to 'bool' (diff) | |
download | core-d7f3dced121ea29f333594bc7a459e564f67f2fc.tar.gz core-d7f3dced121ea29f333594bc7a459e564f67f2fc.zip |
remove unused code in sfx2::sidebar
removes these methods:
sfx2::sidebar::Context::EvaluateMatch(std::vector<sfx2::sidebar::Context>)
sfx2::sidebar::EnumContext::EvaluateMatch(std::vector<sfx2::sidebar::EnumContext>)
Change-Id: I14314d526a5306530d0381ca8bf6ab150d3dd5a0
Diffstat (limited to 'sfx2')
-rw-r--r-- | sfx2/source/sidebar/Context.cxx | 24 | ||||
-rw-r--r-- | sfx2/source/sidebar/Context.hxx | 4 | ||||
-rw-r--r-- | sfx2/source/sidebar/EnumContext.cxx | 28 |
3 files changed, 0 insertions, 56 deletions
diff --git a/sfx2/source/sidebar/Context.cxx b/sfx2/source/sidebar/Context.cxx index c5c9ae3511e1..df0d43c0dfcf 100644 --- a/sfx2/source/sidebar/Context.cxx +++ b/sfx2/source/sidebar/Context.cxx @@ -69,30 +69,6 @@ sal_Int32 Context::EvaluateMatch ( -sal_Int32 Context::EvaluateMatch (const ::std::vector<Context>& rOthers) const -{ - sal_Int32 nBestMatch (NoMatch); - - for (::std::vector<Context>::const_iterator - iContext(rOthers.begin()), - iEnd(rOthers.end()); - iContext!=iEnd; - ++iContext) - { - const sal_Int32 nMatch (EvaluateMatch(*iContext)); - if (nMatch < nBestMatch) - { - if (nMatch == OptimalMatch) - { - // We will find no better match so stop searching. - return OptimalMatch; - } - nBestMatch = nMatch; - } - } - return nBestMatch; -} - diff --git a/sfx2/source/sidebar/Context.hxx b/sfx2/source/sidebar/Context.hxx index f2cabedf2138..12ca19bf0f99 100644 --- a/sfx2/source/sidebar/Context.hxx +++ b/sfx2/source/sidebar/Context.hxx @@ -52,10 +52,6 @@ public: */ sal_Int32 EvaluateMatch (const Context& rOther) const; - /** Return the best match against the given list of contexts. - */ - sal_Int32 EvaluateMatch (const ::std::vector<Context>& rOthers) const; - bool operator== (const Context& rOther) const; bool operator!= (const Context& rOther) const; }; diff --git a/sfx2/source/sidebar/EnumContext.cxx b/sfx2/source/sidebar/EnumContext.cxx index 5d7a3376a737..07ea96c7f8b8 100644 --- a/sfx2/source/sidebar/EnumContext.cxx +++ b/sfx2/source/sidebar/EnumContext.cxx @@ -310,34 +310,6 @@ sal_Int32 EnumContext::EvaluateMatch ( } - - -sal_Int32 EnumContext::EvaluateMatch (const ::std::vector<EnumContext>& rOthers) const -{ - sal_Int32 nBestMatch (NoMatch); - - for (::std::vector<EnumContext>::const_iterator - iContext(rOthers.begin()), - iEnd(rOthers.end()); - iContext!=iEnd; - ++iContext) - { - const sal_Int32 nMatch (EvaluateMatch(*iContext)); - if (nMatch < nBestMatch) - { - if (nMatch == OptimalMatch) - { - // We will find no better match so stop searching. - return OptimalMatch; - } - nBestMatch = nMatch; - } - } - return nBestMatch; -} - - - } } // end of namespace sfx2::sidebar /* vim:set shiftwidth=4 softtabstop=4 expandtab: */ |