17a32b0c8SAndre Fischer /**************************************************************
27a32b0c8SAndre Fischer  *
37a32b0c8SAndre Fischer  * Licensed to the Apache Software Foundation (ASF) under one
47a32b0c8SAndre Fischer  * or more contributor license agreements.  See the NOTICE file
57a32b0c8SAndre Fischer  * distributed with this work for additional information
67a32b0c8SAndre Fischer  * regarding copyright ownership.  The ASF licenses this file
77a32b0c8SAndre Fischer  * to you under the Apache License, Version 2.0 (the
87a32b0c8SAndre Fischer  * "License"); you may not use this file except in compliance
97a32b0c8SAndre Fischer  * with the License.  You may obtain a copy of the License at
107a32b0c8SAndre Fischer  *
117a32b0c8SAndre Fischer  *   http://www.apache.org/licenses/LICENSE-2.0
127a32b0c8SAndre Fischer  *
137a32b0c8SAndre Fischer  * Unless required by applicable law or agreed to in writing,
147a32b0c8SAndre Fischer  * software distributed under the License is distributed on an
157a32b0c8SAndre Fischer  * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
167a32b0c8SAndre Fischer  * KIND, either express or implied.  See the License for the
177a32b0c8SAndre Fischer  * specific language governing permissions and limitations
187a32b0c8SAndre Fischer  * under the License.
197a32b0c8SAndre Fischer  *
207a32b0c8SAndre Fischer  *************************************************************/
217a32b0c8SAndre Fischer 
227a32b0c8SAndre Fischer #include "precompiled_sd.hxx"
237a32b0c8SAndre Fischer 
247a32b0c8SAndre Fischer #include "CustomAnimationPanel.hxx"
257a32b0c8SAndre Fischer 
267a32b0c8SAndre Fischer #include "ViewShellBase.hxx"
277a32b0c8SAndre Fischer 
287a32b0c8SAndre Fischer 
297a32b0c8SAndre Fischer namespace sd {
307a32b0c8SAndre Fischer     extern ::Window * createCustomAnimationPanel (::Window* pParent, ViewShellBase& rBase);
317a32b0c8SAndre Fischer     extern sal_Int32 getCustomAnimationPanelMinimumHeight (::Window* pParent);
327a32b0c8SAndre Fischer }
337a32b0c8SAndre Fischer 
347a32b0c8SAndre Fischer 
357a32b0c8SAndre Fischer 
367a32b0c8SAndre Fischer 
377a32b0c8SAndre Fischer namespace sd { namespace sidebar {
387a32b0c8SAndre Fischer 
397a32b0c8SAndre Fischer 
CustomAnimationPanel(::Window * pParentWindow,ViewShellBase & rViewShellBase)407a32b0c8SAndre Fischer CustomAnimationPanel::CustomAnimationPanel (
417a32b0c8SAndre Fischer     ::Window* pParentWindow,
427a32b0c8SAndre Fischer     ViewShellBase& rViewShellBase)
437a32b0c8SAndre Fischer     : PanelBase(
447a32b0c8SAndre Fischer         pParentWindow,
457a32b0c8SAndre Fischer         rViewShellBase)
467a32b0c8SAndre Fischer {
477a32b0c8SAndre Fischer #ifdef DEBUG
487a32b0c8SAndre Fischer     SetText(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("sd:CustomAnimationPanel")));
497a32b0c8SAndre Fischer #endif
507a32b0c8SAndre Fischer }
517a32b0c8SAndre Fischer 
527a32b0c8SAndre Fischer 
537a32b0c8SAndre Fischer 
547a32b0c8SAndre Fischer 
~CustomAnimationPanel(void)557a32b0c8SAndre Fischer CustomAnimationPanel::~CustomAnimationPanel (void)
567a32b0c8SAndre Fischer {
577a32b0c8SAndre Fischer }
587a32b0c8SAndre Fischer 
597a32b0c8SAndre Fischer 
607a32b0c8SAndre Fischer 
617a32b0c8SAndre Fischer 
CreateWrappedControl(::Window * pParentWindow,ViewShellBase & rViewShellBase)627a32b0c8SAndre Fischer ::Window* CustomAnimationPanel::CreateWrappedControl (
637a32b0c8SAndre Fischer     ::Window* pParentWindow,
647a32b0c8SAndre Fischer     ViewShellBase& rViewShellBase)
657a32b0c8SAndre Fischer {
667a32b0c8SAndre Fischer     return createCustomAnimationPanel(pParentWindow, rViewShellBase);
677a32b0c8SAndre Fischer }
687a32b0c8SAndre Fischer 
697a32b0c8SAndre Fischer 
707a32b0c8SAndre Fischer 
717a32b0c8SAndre Fischer 
GetHeightForWidth(const sal_Int32 nWidth)727a32b0c8SAndre Fischer css::ui::LayoutSize CustomAnimationPanel::GetHeightForWidth (const sal_Int32 nWidth)
737a32b0c8SAndre Fischer {
747a32b0c8SAndre Fischer     const sal_Int32 nMinimumHeight(getCustomAnimationPanelMinimumHeight(mpWrappedControl.get()));
757a32b0c8SAndre Fischer     return css::ui::LayoutSize(nMinimumHeight,-1, nMinimumHeight);
767a32b0c8SAndre Fischer }
777a32b0c8SAndre Fischer 
787a32b0c8SAndre Fischer 
797a32b0c8SAndre Fischer } } // end of namespace sd::sidebar
80