1 /**************************************************************
2  *
3  * Licensed to the Apache Software Foundation (ASF) under one
4  * or more contributor license agreements.  See the NOTICE file
5  * distributed with this work for additional information
6  * regarding copyright ownership.  The ASF licenses this file
7  * to you under the Apache License, Version 2.0 (the
8  * "License"); you may not use this file except in compliance
9  * with the License.  You may obtain a copy of the License at
10  *
11  *   http://www.apache.org/licenses/LICENSE-2.0
12  *
13  * Unless required by applicable law or agreed to in writing,
14  * software distributed under the License is distributed on an
15  * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
16  * KIND, either express or implied.  See the License for the
17  * specific language governing permissions and limitations
18  * under the License.
19  *
20  *************************************************************/
21 
22 
23 #ifndef _CHART2_TP_3D_SCENE_APPEARANCE_HXX
24 #define _CHART2_TP_3D_SCENE_APPEARANCE_HXX
25 
26 // header for class TabPage
27 #include <vcl/tabpage.hxx>
28 // header for class FixedLine
29 #include <vcl/fixed.hxx>
30 // header for class MetricField
31 #include <vcl/field.hxx>
32 // header for class CheckBox
33 #ifndef _SV_BUTTON_HXX
34 #include <vcl/button.hxx>
35 #endif
36 // header for class ListBox
37 #include <vcl/lstbox.hxx>
38 #include <com/sun/star/drawing/ShadeMode.hpp>
39 #include <com/sun/star/frame/XModel.hpp>
40 
41 #include "ControllerLockGuard.hxx"
42 
43 //.............................................................................
44 namespace chart
45 {
46 //.............................................................................
47 
48 class ThreeD_SceneAppearance_TabPage : public TabPage
49 {
50 public:
51     ThreeD_SceneAppearance_TabPage(
52         Window* pWindow,
53         const ::com::sun::star::uno::Reference< ::com::sun::star::frame::XModel > & xChartModel,
54         ControllerLockHelper & rControllerLockHelper );
55 	virtual ~ThreeD_SceneAppearance_TabPage();
56 
57     // has to be called in case the dialog was closed with OK
58     void commitPendingChanges();
59 
60     virtual void ActivatePage();
61 
62 private:
63     DECL_LINK( SelectSchemeHdl, void* );
64     DECL_LINK( SelectShading, void* );
65     DECL_LINK( SelectRoundedEdgeOrObjectLines, CheckBox* );
66 
67     void initControlsFromModel();
68     void applyShadeModeToModel();
69     void applyRoundedEdgeAndObjectLinesToModel();
70     void updateScheme();
71 
72 private:
73     ::com::sun::star::uno::Reference< ::com::sun::star::frame::XModel >
74         m_xChartModel;
75 
76     FixedText		m_aFT_Scheme;
77     ListBox		    m_aLB_Scheme;
78 
79     FixedLine		m_aFL_Seperator;
80 
81 	CheckBox		m_aCB_Shading;
82 	CheckBox		m_aCB_ObjectLines;
83     CheckBox		m_aCB_RoundedEdge;
84 
85     bool            m_bUpdateOtherControls;
86     bool            m_bCommitToModel;
87 
88     ControllerLockHelper & m_rControllerLockHelper;
89 };
90 
91 //.............................................................................
92 } //namespace chart
93 //.............................................................................
94 
95 #endif
96