LCOV - code coverage report
Current view: top level - sd/source/ui/slidesorter/controller - SlsProperties.cxx (source / functions) Hit Total Coverage
Test: commit 10e77ab3ff6f4314137acd6e2702a6e5c1ce1fae Lines: 22 50 44.0 %
Date: 2014-11-03 Functions: 8 16 50.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             : 
      20             : #include "controller/SlsProperties.hxx"
      21             : #include <vcl/svapp.hxx>
      22             : #include <vcl/settings.hxx>
      23             : 
      24             : namespace sd { namespace slidesorter { namespace controller {
      25             : 
      26         126 : Properties::Properties (void)
      27             :     : mbIsHighlightCurrentSlide(false),
      28             :       mbIsShowSelection(true),
      29             :       mbIsShowFocus(true),
      30             :       mbIsCenterSelection(false),
      31             :       mbIsSmoothSelectionScrolling(true),
      32             :       mbIsSuspendPreviewUpdatesDuringFullScreenPresentation(true),
      33         126 :       maBackgroundColor(Application::GetSettings().GetStyleSettings().GetWindowColor()),
      34         126 :       maTextColor(Application::GetSettings().GetStyleSettings().GetActiveTextColor()),
      35         126 :       maSelectionColor(Application::GetSettings().GetStyleSettings().GetHighlightColor()),
      36         126 :       maHighlightColor(Application::GetSettings().GetStyleSettings().GetMenuHighlightColor()),
      37             :       mbIsUIReadOnly(false),
      38             :       mbIsOnlyPreviewTriggersMouseOver(true),
      39             :       mbIsHighContrastModeActive(
      40         630 :           Application::GetSettings().GetStyleSettings().GetHighContrastMode())
      41             : {
      42         126 : }
      43             : 
      44         126 : Properties::~Properties (void)
      45             : {
      46         126 : }
      47             : 
      48           0 : void Properties::HandleDataChangeEvent (void)
      49             : {
      50           0 :     maBackgroundColor = Application::GetSettings().GetStyleSettings().GetWindowColor();
      51           0 :     maTextColor = Application::GetSettings().GetStyleSettings().GetActiveTextColor();
      52           0 :     maSelectionColor = Application::GetSettings().GetStyleSettings().GetHighlightColor();
      53           0 :     maHighlightColor = Application::GetSettings().GetStyleSettings().GetMenuHighlightColor();
      54             :     mbIsHighContrastModeActive
      55           0 :         = Application::GetSettings().GetStyleSettings().GetHighContrastMode();
      56           0 : }
      57             : 
      58           0 : void Properties::SetHighlightCurrentSlide (const bool bIsHighlightCurrentSlide)
      59             : {
      60           0 :     mbIsHighlightCurrentSlide = bIsHighlightCurrentSlide;
      61           0 : }
      62             : 
      63           0 : void Properties::SetShowSelection (const bool bIsShowSelection)
      64             : {
      65           0 :     mbIsShowSelection = bIsShowSelection;
      66           0 : }
      67             : 
      68           0 : void Properties::SetShowFocus (const bool bIsShowFocus)
      69             : {
      70           0 :     mbIsShowFocus = bIsShowFocus;
      71           0 : }
      72             : 
      73           0 : void Properties::SetCenterSelection (const bool bIsCenterSelection)
      74             : {
      75           0 :     mbIsCenterSelection = bIsCenterSelection;
      76           0 : }
      77             : 
      78           0 : void Properties::SetSmoothSelectionScrolling (const bool bIsSmoothSelectionScrolling)
      79             : {
      80           0 :     mbIsSmoothSelectionScrolling = bIsSmoothSelectionScrolling;
      81           0 : }
      82             : 
      83           0 : void Properties::SetSuspendPreviewUpdatesDuringFullScreenPresentation (const bool bFlag)
      84             : {
      85           0 :     mbIsSuspendPreviewUpdatesDuringFullScreenPresentation = bFlag;
      86           0 : }
      87             : 
      88         126 : void Properties::SetBackgroundColor (const Color& rColor)
      89             : {
      90         126 :     maBackgroundColor = rColor;
      91         126 : }
      92             : 
      93         126 : void Properties::SetTextColor (const Color& rColor)
      94             : {
      95         126 :     maTextColor = rColor;
      96         126 : }
      97             : 
      98         126 : void Properties::SetSelectionColor (const Color& rColor)
      99             : {
     100         126 :     maSelectionColor = rColor;
     101         126 : }
     102             : 
     103         126 : void Properties::SetHighlightColor (const Color& rColor)
     104             : {
     105         126 :     maHighlightColor = rColor;
     106         126 : }
     107             : 
     108           0 : void Properties::SetUIReadOnly (const bool bIsUIReadOnly)
     109             : {
     110           0 :     mbIsUIReadOnly = bIsUIReadOnly;
     111           0 : }
     112             : 
     113         114 : } } } // end of namespace ::sd::slidesorter::controller
     114             : 
     115             : /* vim:set shiftwidth=4 softtabstop=4 expandtab: */

Generated by: LCOV version 1.10