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_GEOMETRY_HXX 24 #define _CHART2_TP_3D_SCENE_GEOMETRY_HXX 25 26 #include <com/sun/star/beans/XPropertySet.hpp> 27 #include <basegfx/matrix/b3dhommatrix.hxx> 28 29 // header for class TabPage 30 #include <vcl/tabpage.hxx> 31 // header for class FixedLine 32 #include <vcl/fixed.hxx> 33 // header for class MetricField 34 #include <vcl/field.hxx> 35 // header for class OKButton 36 #ifndef _SV_BUTTON_HXX 37 #include <vcl/button.hxx> 38 #endif 39 40 #include "ControllerLockGuard.hxx" 41 42 //............................................................................. 43 namespace chart 44 { 45 //............................................................................. 46 47 class ThreeD_SceneGeometry_TabPage : public TabPage 48 { 49 public: 50 ThreeD_SceneGeometry_TabPage( Window* pWindow, 51 const ::com::sun::star::uno::Reference< 52 ::com::sun::star::beans::XPropertySet > & xSceneProperties, 53 ControllerLockHelper & rControllerLockHelper ); 54 virtual ~ThreeD_SceneGeometry_TabPage(); 55 56 // has to be called in case the dialog was closed with OK 57 void commitPendingChanges(); 58 59 // is called by timer to apply changes to model 60 DECL_LINK( AngleChanged, void* ); 61 // is called immediately when a field changes 62 DECL_LINK( AngleEdited, void* ); 63 64 // is called by timer to apply changes to model 65 DECL_LINK( PerspectiveChanged, void* ); 66 // is called immediately when a field changes 67 DECL_LINK( PerspectiveEdited, void* ); 68 DECL_LINK( PerspectiveToggled, void* ); 69 DECL_LINK( RightAngledAxesToggled, void* ); 70 71 private: 72 void fillDialogAnglesFromModel() const; 73 void applyAnglesToModel(); 74 void applyPerspectiveToModel(); 75 76 ::com::sun::star::uno::Reference< 77 ::com::sun::star::beans::XPropertySet > m_xSceneProperties; 78 79 CheckBox m_aCbxRightAngledAxes; 80 81 FixedText m_aFtXRotation; 82 MetricField m_aMFXRotation; 83 84 FixedText m_aFtYRotation; 85 MetricField m_aMFYRotation; 86 87 FixedText m_aFtZRotation; 88 MetricField m_aMFZRotation; 89 90 CheckBox m_aCbxPerspective; 91 MetricField m_aMFPerspective; 92 93 //to keep old values when switching to right angled axes 94 sal_Int64 m_nXRotation; 95 sal_Int64 m_nYRotation; 96 sal_Int64 m_nZRotation; 97 98 bool m_bAngleChangePending; 99 bool m_bPerspectiveChangePending; 100 101 ControllerLockHelper & m_rControllerLockHelper; 102 }; 103 104 //............................................................................. 105 } //namespace chart 106 //............................................................................. 107 108 #endif 109