LCOV - code coverage report
Current view: top level - sd/source/ui/slidesorter/controller - SlsProperties.cxx (source / functions) Hit Total Coverage
Test: libreoffice_filtered.info Lines: 27 75 36.0 %
Date: 2012-08-25 Functions: 9 27 33.3 %
Legend: Lines: hit not hit | Branches: + taken - not taken # not executed Branches: 0 0 -

           Branch data     Line data    Source code
       1                 :            : /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
       2                 :            : /*************************************************************************
       3                 :            :  *
       4                 :            :  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
       5                 :            :  *
       6                 :            :  * Copyright 2000, 2010 Oracle and/or its affiliates.
       7                 :            :  *
       8                 :            :  * OpenOffice.org - a multi-platform office productivity suite
       9                 :            :  *
      10                 :            :  * This file is part of OpenOffice.org.
      11                 :            :  *
      12                 :            :  * OpenOffice.org is free software: you can redistribute it and/or modify
      13                 :            :  * it under the terms of the GNU Lesser General Public License version 3
      14                 :            :  * only, as published by the Free Software Foundation.
      15                 :            :  *
      16                 :            :  * OpenOffice.org is distributed in the hope that it will be useful,
      17                 :            :  * but WITHOUT ANY WARRANTY; without even the implied warranty of
      18                 :            :  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
      19                 :            :  * GNU Lesser General Public License version 3 for more details
      20                 :            :  * (a copy is included in the LICENSE file that accompanied this code).
      21                 :            :  *
      22                 :            :  * You should have received a copy of the GNU Lesser General Public License
      23                 :            :  * version 3 along with OpenOffice.org.  If not, see
      24                 :            :  * <http://www.openoffice.org/license.html>
      25                 :            :  * for a copy of the LGPLv3 License.
      26                 :            :  *
      27                 :            :  ************************************************************************/
      28                 :            : 
      29                 :            : 
      30                 :            : #include "controller/SlsProperties.hxx"
      31                 :            : #include <vcl/svapp.hxx>
      32                 :            : 
      33                 :            : namespace sd { namespace slidesorter { namespace controller {
      34                 :            : 
      35                 :        130 : Properties::Properties (void)
      36                 :            :     : mbIsHighlightCurrentSlide(false),
      37                 :            :       mbIsShowSelection(true),
      38                 :            :       mbIsShowFocus(true),
      39                 :            :       mbIsCenterSelection(false),
      40                 :            :       mbIsSmoothSelectionScrolling(true),
      41                 :            :       mbIsSuspendPreviewUpdatesDuringFullScreenPresentation(true),
      42                 :        130 :       maBackgroundColor(Application::GetSettings().GetStyleSettings().GetWindowColor()),
      43                 :        130 :       maTextColor(Application::GetSettings().GetStyleSettings().GetActiveTextColor()),
      44                 :        130 :       maSelectionColor(Application::GetSettings().GetStyleSettings().GetHighlightColor()),
      45                 :        130 :       maHighlightColor(Application::GetSettings().GetStyleSettings().GetMenuHighlightColor()),
      46                 :            :       mbIsUIReadOnly(false),
      47                 :            :       mbIsOnlyPreviewTriggersMouseOver(true),
      48                 :            :       mbIsHighContrastModeActive(
      49                 :        130 :           Application::GetSettings().GetStyleSettings().GetHighContrastMode())
      50                 :            : {
      51                 :        130 : }
      52                 :            : 
      53                 :            : 
      54                 :            : 
      55                 :            : 
      56                 :        130 : Properties::~Properties (void)
      57                 :            : {
      58                 :        130 : }
      59                 :            : 
      60                 :            : 
      61                 :            : 
      62                 :            : 
      63                 :          0 : void Properties::HandleDataChangeEvent (void)
      64                 :            : {
      65                 :          0 :     maBackgroundColor = Application::GetSettings().GetStyleSettings().GetWindowColor();
      66                 :          0 :     maTextColor = Application::GetSettings().GetStyleSettings().GetActiveTextColor();
      67                 :          0 :     maSelectionColor = Application::GetSettings().GetStyleSettings().GetHighlightColor();
      68                 :          0 :     maHighlightColor = Application::GetSettings().GetStyleSettings().GetMenuHighlightColor();
      69                 :            :     mbIsHighContrastModeActive
      70                 :          0 :         = Application::GetSettings().GetStyleSettings().GetHighContrastMode();
      71                 :          0 : }
      72                 :            : 
      73                 :            : 
      74                 :            : 
      75                 :            : 
      76                 :          0 : bool Properties::IsHighlightCurrentSlide (void) const
      77                 :            : {
      78                 :          0 :     return mbIsHighlightCurrentSlide;
      79                 :            : }
      80                 :            : 
      81                 :            : 
      82                 :            : 
      83                 :            : 
      84                 :          0 : void Properties::SetHighlightCurrentSlide (const bool bIsHighlightCurrentSlide)
      85                 :            : {
      86                 :          0 :     mbIsHighlightCurrentSlide = bIsHighlightCurrentSlide;
      87                 :          0 : }
      88                 :            : 
      89                 :            : 
      90                 :            : 
      91                 :            : 
      92                 :          0 : bool Properties::IsShowSelection (void) const
      93                 :            : {
      94                 :          0 :     return mbIsShowSelection;
      95                 :            : }
      96                 :            : 
      97                 :            : 
      98                 :            : 
      99                 :            : 
     100                 :          0 : void Properties::SetShowSelection (const bool bIsShowSelection)
     101                 :            : {
     102                 :          0 :     mbIsShowSelection = bIsShowSelection;
     103                 :          0 : }
     104                 :            : 
     105                 :            : 
     106                 :            : 
     107                 :            : 
     108                 :          0 : bool Properties::IsShowFocus (void) const
     109                 :            : {
     110                 :          0 :     return mbIsShowFocus;
     111                 :            : }
     112                 :            : 
     113                 :            : 
     114                 :            : 
     115                 :            : 
     116                 :          0 : void Properties::SetShowFocus (const bool bIsShowFocus)
     117                 :            : {
     118                 :          0 :     mbIsShowFocus = bIsShowFocus;
     119                 :          0 : }
     120                 :            : 
     121                 :            : 
     122                 :            : 
     123                 :            : 
     124                 :          0 : bool Properties::IsCenterSelection (void) const
     125                 :            : {
     126                 :          0 :     return mbIsCenterSelection;
     127                 :            : }
     128                 :            : 
     129                 :            : 
     130                 :            : 
     131                 :            : 
     132                 :          0 : void Properties::SetCenterSelection (const bool bIsCenterSelection)
     133                 :            : {
     134                 :          0 :     mbIsCenterSelection = bIsCenterSelection;
     135                 :          0 : }
     136                 :            : 
     137                 :            : 
     138                 :            : 
     139                 :            : 
     140                 :          0 : bool Properties::IsSmoothSelectionScrolling (void) const
     141                 :            : {
     142                 :          0 :     return mbIsSmoothSelectionScrolling;
     143                 :            : }
     144                 :            : 
     145                 :            : 
     146                 :            : 
     147                 :            : 
     148                 :          0 : void Properties::SetSmoothSelectionScrolling (const bool bIsSmoothSelectionScrolling)
     149                 :            : {
     150                 :          0 :     mbIsSmoothSelectionScrolling = bIsSmoothSelectionScrolling;
     151                 :          0 : }
     152                 :            : 
     153                 :            : 
     154                 :            : 
     155                 :            : 
     156                 :          0 : bool Properties::IsSuspendPreviewUpdatesDuringFullScreenPresentation (void) const
     157                 :            : {
     158                 :          0 :     return mbIsSuspendPreviewUpdatesDuringFullScreenPresentation;
     159                 :            : }
     160                 :            : 
     161                 :            : 
     162                 :            : 
     163                 :            : 
     164                 :          0 : void Properties::SetSuspendPreviewUpdatesDuringFullScreenPresentation (const bool bFlag)
     165                 :            : {
     166                 :          0 :     mbIsSuspendPreviewUpdatesDuringFullScreenPresentation = bFlag;
     167                 :          0 : }
     168                 :            : 
     169                 :            : 
     170                 :            : 
     171                 :            : 
     172                 :        260 : Color Properties::GetBackgroundColor (void) const
     173                 :            : {
     174                 :        260 :     return maBackgroundColor;
     175                 :            : }
     176                 :            : 
     177                 :            : 
     178                 :            : 
     179                 :            : 
     180                 :        130 : void Properties::SetBackgroundColor (const Color& rColor)
     181                 :            : {
     182                 :        130 :     maBackgroundColor = rColor;
     183                 :        130 : }
     184                 :            : 
     185                 :            : 
     186                 :            : 
     187                 :          0 : Color Properties::GetTextColor (void) const
     188                 :            : {
     189                 :          0 :     return maTextColor;
     190                 :            : }
     191                 :            : 
     192                 :            : 
     193                 :            : 
     194                 :            : 
     195                 :        130 : void Properties::SetTextColor (const Color& rColor)
     196                 :            : {
     197                 :        130 :     maTextColor = rColor;
     198                 :        130 : }
     199                 :            : 
     200                 :            : 
     201                 :            : 
     202                 :            : 
     203                 :        130 : Color Properties::GetSelectionColor (void) const
     204                 :            : {
     205                 :        130 :     return maSelectionColor;
     206                 :            : }
     207                 :            : 
     208                 :            : 
     209                 :            : 
     210                 :            : 
     211                 :        130 : void Properties::SetSelectionColor (const Color& rColor)
     212                 :            : {
     213                 :        130 :     maSelectionColor = rColor;
     214                 :        130 : }
     215                 :            : 
     216                 :            : 
     217                 :            : 
     218                 :            : 
     219                 :          0 : Color Properties::GetHighlightColor (void) const
     220                 :            : {
     221                 :          0 :     return maHighlightColor;
     222                 :            : }
     223                 :            : 
     224                 :            : 
     225                 :            : 
     226                 :            : 
     227                 :        130 : void Properties::SetHighlightColor (const Color& rColor)
     228                 :            : {
     229                 :        130 :     maHighlightColor = rColor;
     230                 :        130 : }
     231                 :            : 
     232                 :            : 
     233                 :            : 
     234                 :            : 
     235                 :          0 : bool Properties::IsUIReadOnly (void) const
     236                 :            : {
     237                 :          0 :     return mbIsUIReadOnly;
     238                 :            : }
     239                 :            : 
     240                 :            : 
     241                 :            : 
     242                 :            : 
     243                 :          0 : void Properties::SetUIReadOnly (const bool bIsUIReadOnly)
     244                 :            : {
     245                 :          0 :     mbIsUIReadOnly = bIsUIReadOnly;
     246                 :          0 : }
     247                 :            : 
     248                 :            : 
     249                 :            : 
     250                 :            : 
     251                 :          0 : bool Properties::IsOnlyPreviewTriggersMouseOver (void) const
     252                 :            : {
     253                 :          0 :     return mbIsOnlyPreviewTriggersMouseOver;
     254                 :            : }
     255                 :            : 
     256                 :            : 
     257                 :            : 
     258                 :            : 
     259                 :        130 : bool Properties::IsHighContrastModeActive (void) const
     260                 :            : {
     261                 :        130 :     return mbIsHighContrastModeActive;
     262                 :            : }
     263                 :            : 
     264                 :            : 
     265                 :            : } } } // end of namespace ::sd::slidesorter::controller
     266                 :            : 
     267                 :            : /* vim:set shiftwidth=4 softtabstop=4 expandtab: */

Generated by: LCOV version 1.10