LCOV - code coverage report
Current view: top level - sfx2/source/sidebar - ContextList.hxx (source / functions) Hit Total Coverage
Test: commit e02a6cb2c3e2b23b203b422e4e0680877f232636 Lines: 0 2 0.0 %
Date: 2014-04-14 Functions: 0 5 0.0 %
Legend: Lines: hit not hit

          Line data    Source code
       1             : /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
       2             : /*
       3             :  * This file is part of the LibreOffice project.
       4             :  *
       5             :  * This Source Code Form is subject to the terms of the Mozilla Public
       6             :  * License, v. 2.0. If a copy of the MPL was not distributed with this
       7             :  * file, You can obtain one at http://mozilla.org/MPL/2.0/.
       8             :  *
       9             :  * This file incorporates work covered by the following license notice:
      10             :  *
      11             :  *   Licensed to the Apache Software Foundation (ASF) under one or more
      12             :  *   contributor license agreements. See the NOTICE file distributed
      13             :  *   with this work for additional information regarding copyright
      14             :  *   ownership. The ASF licenses this file to you under the Apache
      15             :  *   License, Version 2.0 (the "License"); you may not use this file
      16             :  *   except in compliance with the License. You may obtain a copy of
      17             :  *   the License at http://www.apache.org/licenses/LICENSE-2.0 .
      18             :  */
      19             : #ifndef INCLUDED_SFX2_SOURCE_SIDEBAR_CONTEXTLIST_HXX
      20             : #define INCLUDED_SFX2_SOURCE_SIDEBAR_CONTEXTLIST_HXX
      21             : 
      22             : #include "Context.hxx"
      23             : #include <sal/types.h>
      24             : #include <rtl/ustring.hxx>
      25             : 
      26             : #include <vector>
      27             : 
      28             : 
      29             : namespace sfx2 { namespace sidebar {
      30             : 
      31             : /** Per context data for deck and panel descriptors.
      32             : */
      33           0 : class ContextList
      34             : {
      35             : public:
      36             :     ContextList (void);
      37             :     ~ContextList (void);
      38             : 
      39           0 :     class Entry
      40             :     {
      41             :     public:
      42             :         Context maContext;
      43             :         bool mbIsInitiallyVisible;
      44             :         ::rtl::OUString msMenuCommand;
      45             :     };
      46             : 
      47             :     /** Return <TRUE/> when the given context matches any of the stored contexts.
      48             :     */
      49             :     const Entry* GetMatch (
      50             :         const Context& rContext) const;
      51             :     Entry* GetMatch (
      52             :         const Context& rContext);
      53             : 
      54             :     void AddContextDescription (
      55             :         const Context& rContext,
      56             :         const bool bIsInitiallyVisible,
      57             :         const ::rtl::OUString& rsMenuCommand);
      58             : 
      59             : private:
      60             :     ::std::vector<Entry> maEntries;
      61             : 
      62             :     ::std::vector<Entry>::const_iterator FindBestMatch (const Context& rContext) const;
      63             : };
      64             : 
      65             : 
      66             : } } // end of namespace sfx2::sidebar
      67             : 
      68             : #endif
      69             : 
      70             : /* vim:set shiftwidth=4 softtabstop=4 expandtab: */

Generated by: LCOV version 1.10