1721f296aSOliver-Rainer Wittmann /**************************************************************
2*fb399032Smseidel *
3721f296aSOliver-Rainer Wittmann * Licensed to the Apache Software Foundation (ASF) under one
4721f296aSOliver-Rainer Wittmann * or more contributor license agreements.  See the NOTICE file
5721f296aSOliver-Rainer Wittmann * distributed with this work for additional information
6721f296aSOliver-Rainer Wittmann * regarding copyright ownership.  The ASF licenses this file
7721f296aSOliver-Rainer Wittmann * to you under the Apache License, Version 2.0 (the
8721f296aSOliver-Rainer Wittmann * "License"); you may not use this file except in compliance
9721f296aSOliver-Rainer Wittmann * with the License.  You may obtain a copy of the License at
10*fb399032Smseidel *
11721f296aSOliver-Rainer Wittmann *   http://www.apache.org/licenses/LICENSE-2.0
12*fb399032Smseidel *
13721f296aSOliver-Rainer Wittmann * Unless required by applicable law or agreed to in writing,
14721f296aSOliver-Rainer Wittmann * software distributed under the License is distributed on an
15721f296aSOliver-Rainer Wittmann * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
16721f296aSOliver-Rainer Wittmann * KIND, either express or implied.  See the License for the
17721f296aSOliver-Rainer Wittmann * specific language governing permissions and limitations
18721f296aSOliver-Rainer Wittmann * under the License.
19*fb399032Smseidel *
20721f296aSOliver-Rainer Wittmann *************************************************************/
21721f296aSOliver-Rainer Wittmann 
22*fb399032Smseidel 
23*fb399032Smseidel 
24721f296aSOliver-Rainer Wittmann #ifndef SW_SIDEBAR_WRAP_PROPERTY_PANEL_HXX
25721f296aSOliver-Rainer Wittmann #define SW_SIDEBAR_WRAP_PROPERTY_PANEL_HXX
26721f296aSOliver-Rainer Wittmann 
27721f296aSOliver-Rainer Wittmann #include <vcl/button.hxx>
28721f296aSOliver-Rainer Wittmann #include <vcl/image.hxx>
29721f296aSOliver-Rainer Wittmann 
30721f296aSOliver-Rainer Wittmann #include <sfx2/sidebar/ControllerItem.hxx>
31721f296aSOliver-Rainer Wittmann #include <com/sun/star/frame/XFrame.hpp>
32721f296aSOliver-Rainer Wittmann 
33721f296aSOliver-Rainer Wittmann #include <boost/scoped_ptr.hpp>
34721f296aSOliver-Rainer Wittmann 
35721f296aSOliver-Rainer Wittmann 
36721f296aSOliver-Rainer Wittmann namespace sw { namespace sidebar {
37721f296aSOliver-Rainer Wittmann 
38*fb399032Smseidel 	class WrapPropertyPanel
39*fb399032Smseidel 		: public Control
40*fb399032Smseidel 		, public ::sfx2::sidebar::ControllerItem::ItemUpdateReceiverInterface
41*fb399032Smseidel 	{
42*fb399032Smseidel 	public:
43*fb399032Smseidel 		static WrapPropertyPanel* Create(
44*fb399032Smseidel 			Window* pParent,
45*fb399032Smseidel 			const ::com::sun::star::uno::Reference< ::com::sun::star::frame::XFrame>& rxFrame,
46*fb399032Smseidel 			SfxBindings* pBindings );
47*fb399032Smseidel 
48*fb399032Smseidel 		// interface of ::sfx2::sidebar::ControllerItem::ItemUpdateReceiverInterface
49*fb399032Smseidel 		virtual void NotifyItemUpdate(
50*fb399032Smseidel 			const sal_uInt16 nSId,
51*fb399032Smseidel 			const SfxItemState eState,
52*fb399032Smseidel 			const SfxPoolItem* pState,
53*fb399032Smseidel 			const bool bIsEnabled);
54*fb399032Smseidel 
55*fb399032Smseidel 	private:
56*fb399032Smseidel 		WrapPropertyPanel(
57*fb399032Smseidel 			Window* pParent,
58*fb399032Smseidel 			const ::com::sun::star::uno::Reference< ::com::sun::star::frame::XFrame >& rxFrame,
59*fb399032Smseidel 			SfxBindings* pBindings );
60*fb399032Smseidel 
61*fb399032Smseidel 		virtual ~WrapPropertyPanel();
62*fb399032Smseidel 
63*fb399032Smseidel 		::com::sun::star::uno::Reference< ::com::sun::star::frame::XFrame > mxFrame;
64*fb399032Smseidel 		SfxBindings* mpBindings;
65*fb399032Smseidel 
66*fb399032Smseidel 		::boost::scoped_ptr<ImageRadioButton> mpRBNoWrap;
67*fb399032Smseidel 		::boost::scoped_ptr<ImageRadioButton> mpRBWrapLeft;
68*fb399032Smseidel 		::boost::scoped_ptr<ImageRadioButton> mpRBWrapRight;
69*fb399032Smseidel 		::boost::scoped_ptr<ImageRadioButton> mpRBWrapParallel;
70*fb399032Smseidel 		::boost::scoped_ptr<ImageRadioButton> mpRBWrapThrough;
71*fb399032Smseidel 		::boost::scoped_ptr<ImageRadioButton> mpRBIdealWrap;
72*fb399032Smseidel 
73*fb399032Smseidel 		// Image resource
74*fb399032Smseidel 		ImageList aWrapIL;
75*fb399032Smseidel 		ImageList aWrapILH;
76*fb399032Smseidel 
77*fb399032Smseidel 		// Controller Items
78*fb399032Smseidel 		::sfx2::sidebar::ControllerItem maSwNoWrapControl;
79*fb399032Smseidel 		::sfx2::sidebar::ControllerItem maSwWrapLeftControl;
80*fb399032Smseidel 		::sfx2::sidebar::ControllerItem maSwWrapRightControl;
81*fb399032Smseidel 		::sfx2::sidebar::ControllerItem maSwWrapParallelControl;
82*fb399032Smseidel 		::sfx2::sidebar::ControllerItem maSwWrapThroughControl;
83*fb399032Smseidel 		::sfx2::sidebar::ControllerItem maSwWrapIdealControl;
84*fb399032Smseidel 
85*fb399032Smseidel 		void Initialize();
86*fb399032Smseidel 
87*fb399032Smseidel 		DECL_LINK(WrapTypeHdl, void*);
88*fb399032Smseidel 	};
89721f296aSOliver-Rainer Wittmann 
90721f296aSOliver-Rainer Wittmann } } // end of namespace ::sw::sidebar
91721f296aSOliver-Rainer Wittmann 
92721f296aSOliver-Rainer Wittmann #endif
93*fb399032Smseidel 
94*fb399032Smseidel /* vim: set noet sw=4 ts=4: */
95