xref: /aoo41x/main/sfx2/source/layout/sfxtabpage.cxx (revision d119d52d)
1*d119d52dSAndrew Rist /**************************************************************
2cdf0e10cSrcweir  *
3*d119d52dSAndrew Rist  * Licensed to the Apache Software Foundation (ASF) under one
4*d119d52dSAndrew Rist  * or more contributor license agreements.  See the NOTICE file
5*d119d52dSAndrew Rist  * distributed with this work for additional information
6*d119d52dSAndrew Rist  * regarding copyright ownership.  The ASF licenses this file
7*d119d52dSAndrew Rist  * to you under the Apache License, Version 2.0 (the
8*d119d52dSAndrew Rist  * "License"); you may not use this file except in compliance
9*d119d52dSAndrew Rist  * with the License.  You may obtain a copy of the License at
10*d119d52dSAndrew Rist  *
11*d119d52dSAndrew Rist  *   http://www.apache.org/licenses/LICENSE-2.0
12*d119d52dSAndrew Rist  *
13*d119d52dSAndrew Rist  * Unless required by applicable law or agreed to in writing,
14*d119d52dSAndrew Rist  * software distributed under the License is distributed on an
15*d119d52dSAndrew Rist  * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
16*d119d52dSAndrew Rist  * KIND, either express or implied.  See the License for the
17*d119d52dSAndrew Rist  * specific language governing permissions and limitations
18*d119d52dSAndrew Rist  * under the License.
19*d119d52dSAndrew Rist  *
20*d119d52dSAndrew Rist  *************************************************************/
21*d119d52dSAndrew Rist 
22*d119d52dSAndrew Rist 
23cdf0e10cSrcweir 
24cdf0e10cSrcweir #include <sfx2/layout.hxx>
25cdf0e10cSrcweir 
26cdf0e10cSrcweir #include <com/sun/star/awt/PosSize.hpp>
27cdf0e10cSrcweir #include <toolkit/awt/vclxwindow.hxx>
28cdf0e10cSrcweir 
29cdf0e10cSrcweir namespace layout
30cdf0e10cSrcweir {
31cdf0e10cSrcweir 
32cdf0e10cSrcweir using namespace ::com::sun::star;
33cdf0e10cSrcweir 
34cdf0e10cSrcweir #if 0
35cdf0e10cSrcweir SfxTabDialog::SfxTabDialog (::Window *parent, char const* xml_file, char const* id, ResId const& res_id, SfxItemSet const* set)
36cdf0e10cSrcweir     : ::SfxTabDialog (parent, res_id, set)
37cdf0e10cSrcweir     , InPlug (parent, xml_file, id)
38cdf0e10cSrcweir {
39cdf0e10cSrcweir }
40cdf0e10cSrcweir 
41cdf0e10cSrcweir ::Window* SfxTabDialog::GetParent () const
42cdf0e10cSrcweir {
43cdf0e10cSrcweir     return Window::GetParent ();
44cdf0e10cSrcweir }
45cdf0e10cSrcweir 
46cdf0e10cSrcweir ::Window* SfxTabDialog::GetWindow () const
47cdf0e10cSrcweir {
48cdf0e10cSrcweir     return Window::GetParent ();
49cdf0e10cSrcweir }
50cdf0e10cSrcweir 
51cdf0e10cSrcweir void SfxTabDialog::FreeResource ()
52cdf0e10cSrcweir {
53cdf0e10cSrcweir     //::Window::FreeResource ();
54cdf0e10cSrcweir }
55cdf0e10cSrcweir #endif
56cdf0e10cSrcweir 
SfxTabPage(::Window * parent,char const * xml_file,char const * id,SfxItemSet const * set)57cdf0e10cSrcweir SfxTabPage::SfxTabPage (::Window *parent, char const* xml_file, char const* id, SfxItemSet const* set)
58cdf0e10cSrcweir     : ::SfxTabPage (parent, 0, *set)
59cdf0e10cSrcweir     , InPlug (parent, xml_file, id)
60cdf0e10cSrcweir {
61cdf0e10cSrcweir     dynamic_cast< ::Window* > (this)->SetComponentInterface (GetVCLXWindow ());
62cdf0e10cSrcweir }
63cdf0e10cSrcweir 
GetParent() const64cdf0e10cSrcweir ::Window* SfxTabPage::GetParent () const
65cdf0e10cSrcweir {
66cdf0e10cSrcweir     return Window::GetParent ();
67cdf0e10cSrcweir }
68cdf0e10cSrcweir 
GetWindow() const69cdf0e10cSrcweir ::Window* SfxTabPage::GetWindow () const
70cdf0e10cSrcweir {
71cdf0e10cSrcweir     return ::layout::Window::GetWindow();
72cdf0e10cSrcweir }
73cdf0e10cSrcweir 
FreeResource()74cdf0e10cSrcweir void SfxTabPage::FreeResource ()
75cdf0e10cSrcweir {
76cdf0e10cSrcweir     //::Window::FreeResource ();
77cdf0e10cSrcweir }
78cdf0e10cSrcweir 
GetOptimalSize(WindowSizeType) const79cdf0e10cSrcweir Size SfxTabPage::GetOptimalSize (WindowSizeType) const
80cdf0e10cSrcweir {
81cdf0e10cSrcweir     awt::Size s = GetVCLXWindow()->getMinimumSize ();
82cdf0e10cSrcweir     return Size (s.Width, s.Height);
83cdf0e10cSrcweir }
84cdf0e10cSrcweir 
85cdf0e10cSrcweir } // end namespace layout
86