Line data Source code
1 : /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
2 : /*
3 : * This file is part of the LibreOffice project.
4 : *
5 : * This Source Code Form is subject to the terms of the Mozilla Public
6 : * License, v. 2.0. If a copy of the MPL was not distributed with this
7 : * file, You can obtain one at http://mozilla.org/MPL/2.0/.
8 : */
9 :
10 : #include "oglwindow.hxx"
11 : #include <cppuhelper/supportsservice.hxx>
12 :
13 : using namespace com::sun::star;
14 :
15 : namespace avmedia { namespace ogl {
16 :
17 0 : OGLWindow::OGLWindow( OGLPlayer& rPlayer )
18 : : m_rPlayer( rPlayer )
19 0 : , meZoomLevel( media::ZoomLevel_ORIGINAL )
20 : {
21 : (void) m_rPlayer;
22 0 : }
23 :
24 0 : OGLWindow::~OGLWindow()
25 : {
26 0 : }
27 :
28 0 : void SAL_CALL OGLWindow::update() throw (css::uno::RuntimeException, std::exception)
29 : {
30 0 : }
31 :
32 0 : sal_Bool SAL_CALL OGLWindow::setZoomLevel( css::media::ZoomLevel eZoomLevel ) throw (css::uno::RuntimeException, std::exception)
33 : {
34 0 : sal_Bool bRet = false;
35 :
36 0 : if( media::ZoomLevel_NOT_AVAILABLE != meZoomLevel &&
37 : media::ZoomLevel_NOT_AVAILABLE != eZoomLevel )
38 : {
39 0 : if( eZoomLevel != meZoomLevel )
40 : {
41 0 : meZoomLevel = eZoomLevel;
42 : }
43 0 : bRet = true;
44 : }
45 : // TODO: set zoom level, not just store this value
46 0 : return bRet;
47 : }
48 :
49 0 : css::media::ZoomLevel SAL_CALL OGLWindow::getZoomLevel() throw (css::uno::RuntimeException, std::exception)
50 : {
51 0 : return meZoomLevel;
52 : }
53 :
54 0 : void SAL_CALL OGLWindow::setPointerType( sal_Int32 ) throw (css::uno::RuntimeException, std::exception)
55 : {
56 0 : }
57 :
58 0 : OUString SAL_CALL OGLWindow::getImplementationName() throw (css::uno::RuntimeException, std::exception)
59 : {
60 0 : return OUString("com.sun.star.comp.avmedia.Window_OpenGL");
61 : }
62 :
63 0 : sal_Bool SAL_CALL OGLWindow::supportsService( const OUString& rServiceName ) throw (css::uno::RuntimeException, std::exception)
64 : {
65 0 : return cppu::supportsService(this, rServiceName);
66 : }
67 :
68 0 : uno::Sequence< OUString > SAL_CALL OGLWindow::getSupportedServiceNames() throw (css::uno::RuntimeException, std::exception)
69 : {
70 0 : uno::Sequence< OUString > aRet(1);
71 0 : aRet[0] = OUString("com.sun.star.media.Window_OpenGL");
72 0 : return aRet;
73 : }
74 :
75 0 : void SAL_CALL OGLWindow::dispose() throw (uno::RuntimeException, std::exception)
76 : {
77 0 : }
78 :
79 0 : void SAL_CALL OGLWindow::addEventListener( const uno::Reference< lang::XEventListener >& )
80 : throw (uno::RuntimeException, std::exception)
81 : {
82 0 : }
83 :
84 0 : void SAL_CALL OGLWindow::removeEventListener( const uno::Reference< lang::XEventListener >& )
85 : throw (uno::RuntimeException, std::exception)
86 : {
87 0 : }
88 :
89 0 : void SAL_CALL OGLWindow::setPosSize( sal_Int32 /*X*/, sal_Int32 /*Y*/, sal_Int32 /*Width*/, sal_Int32 /*Height*/, sal_Int16 /* Flags */ )
90 : throw (uno::RuntimeException, std::exception)
91 : {
92 : // TODO: store size
93 0 : }
94 :
95 0 : awt::Rectangle SAL_CALL OGLWindow::getPosSize()
96 : throw (uno::RuntimeException, std::exception)
97 : {
98 : // TODO: get size
99 0 : return awt::Rectangle();
100 : }
101 :
102 0 : void SAL_CALL OGLWindow::setVisible( sal_Bool )
103 : throw (uno::RuntimeException, std::exception)
104 : {
105 0 : }
106 :
107 0 : void SAL_CALL OGLWindow::setEnable( sal_Bool )
108 : throw (uno::RuntimeException, std::exception)
109 : {
110 0 : }
111 :
112 0 : void SAL_CALL OGLWindow::setFocus()
113 : throw (uno::RuntimeException, std::exception)
114 : {
115 0 : }
116 :
117 0 : void SAL_CALL OGLWindow::addWindowListener( const uno::Reference< awt::XWindowListener >& )
118 : throw (uno::RuntimeException, std::exception)
119 : {
120 0 : }
121 :
122 0 : void SAL_CALL OGLWindow::removeWindowListener( const uno::Reference< awt::XWindowListener >& )
123 : throw (uno::RuntimeException, std::exception)
124 : {
125 0 : }
126 :
127 0 : void SAL_CALL OGLWindow::addFocusListener( const uno::Reference< awt::XFocusListener >& )
128 : throw (uno::RuntimeException, std::exception)
129 : {
130 0 : }
131 :
132 0 : void SAL_CALL OGLWindow::removeFocusListener( const uno::Reference< awt::XFocusListener >& )
133 : throw (uno::RuntimeException, std::exception)
134 : {
135 0 : }
136 :
137 0 : void SAL_CALL OGLWindow::addKeyListener( const uno::Reference< awt::XKeyListener >& )
138 : throw (uno::RuntimeException, std::exception)
139 : {
140 0 : }
141 :
142 0 : void SAL_CALL OGLWindow::removeKeyListener( const uno::Reference< awt::XKeyListener >& )
143 : throw (uno::RuntimeException, std::exception)
144 : {
145 0 : }
146 :
147 0 : void SAL_CALL OGLWindow::addMouseListener( const uno::Reference< awt::XMouseListener >& )
148 : throw (uno::RuntimeException, std::exception)
149 : {
150 0 : }
151 :
152 0 : void SAL_CALL OGLWindow::removeMouseListener( const uno::Reference< awt::XMouseListener >& )
153 : throw (uno::RuntimeException, std::exception)
154 : {
155 0 : }
156 :
157 0 : void SAL_CALL OGLWindow::addMouseMotionListener( const uno::Reference< awt::XMouseMotionListener >& )
158 : throw (uno::RuntimeException, std::exception)
159 : {
160 0 : }
161 :
162 0 : void SAL_CALL OGLWindow::removeMouseMotionListener( const uno::Reference< awt::XMouseMotionListener >& )
163 : throw (uno::RuntimeException, std::exception)
164 : {
165 0 : }
166 :
167 0 : void SAL_CALL OGLWindow::addPaintListener( const uno::Reference< awt::XPaintListener >& )
168 : throw (uno::RuntimeException, std::exception)
169 : {
170 0 : }
171 :
172 0 : void SAL_CALL OGLWindow::removePaintListener( const uno::Reference< awt::XPaintListener >& )
173 : throw (uno::RuntimeException, std::exception)
174 : {
175 0 : }
176 :
177 : } // namespace ogl
178 : } // namespace avmedia
179 :
180 : /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
|