xref: /aoo42x/main/sfx2/source/layout/sfxtabpage.cxx (revision d119d52d)
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 
24 #include <sfx2/layout.hxx>
25 
26 #include <com/sun/star/awt/PosSize.hpp>
27 #include <toolkit/awt/vclxwindow.hxx>
28 
29 namespace layout
30 {
31 
32 using namespace ::com::sun::star;
33 
34 #if 0
35 SfxTabDialog::SfxTabDialog (::Window *parent, char const* xml_file, char const* id, ResId const& res_id, SfxItemSet const* set)
36     : ::SfxTabDialog (parent, res_id, set)
37     , InPlug (parent, xml_file, id)
38 {
39 }
40 
41 ::Window* SfxTabDialog::GetParent () const
42 {
43     return Window::GetParent ();
44 }
45 
46 ::Window* SfxTabDialog::GetWindow () const
47 {
48     return Window::GetParent ();
49 }
50 
51 void SfxTabDialog::FreeResource ()
52 {
53     //::Window::FreeResource ();
54 }
55 #endif
56 
SfxTabPage(::Window * parent,char const * xml_file,char const * id,SfxItemSet const * set)57 SfxTabPage::SfxTabPage (::Window *parent, char const* xml_file, char const* id, SfxItemSet const* set)
58     : ::SfxTabPage (parent, 0, *set)
59     , InPlug (parent, xml_file, id)
60 {
61     dynamic_cast< ::Window* > (this)->SetComponentInterface (GetVCLXWindow ());
62 }
63 
GetParent() const64 ::Window* SfxTabPage::GetParent () const
65 {
66     return Window::GetParent ();
67 }
68 
GetWindow() const69 ::Window* SfxTabPage::GetWindow () const
70 {
71     return ::layout::Window::GetWindow();
72 }
73 
FreeResource()74 void SfxTabPage::FreeResource ()
75 {
76     //::Window::FreeResource ();
77 }
78 
GetOptimalSize(WindowSizeType) const79 Size SfxTabPage::GetOptimalSize (WindowSizeType) const
80 {
81     awt::Size s = GetVCLXWindow()->getMinimumSize ();
82     return Size (s.Width, s.Height);
83 }
84 
85 } // end namespace layout
86