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 <svx/sdr/contact/viewobjectcontactofopenglobj.hxx>
11 : #include <vcl/outdev.hxx>
12 : #include <vcl/window.hxx>
13 :
14 : using namespace sdr::contact;
15 :
16 :
17 0 : ViewObjectContactOfOpenGLObj::ViewObjectContactOfOpenGLObj(
18 : ObjectContact& rObjectContact, ViewContact& rViewContact )
19 0 : : ViewObjectContactOfSdrObj( rObjectContact, rViewContact )
20 : {
21 0 : }
22 :
23 0 : ViewObjectContactOfOpenGLObj::~ViewObjectContactOfOpenGLObj()
24 : {
25 0 : }
26 :
27 0 : Window* ViewObjectContactOfOpenGLObj::getWindow() const
28 : {
29 0 : Window* pRetval = 0;
30 :
31 0 : boost::optional<const OutputDevice&> oPageOutputDev = getPageViewOutputDevice();
32 0 : if( oPageOutputDev )
33 : {
34 0 : if(OUTDEV_WINDOW == oPageOutputDev->GetOutDevType())
35 : {
36 0 : pRetval = static_cast< Window* >(&const_cast<OutputDevice&>(oPageOutputDev.get()));
37 : }
38 : }
39 :
40 0 : return pRetval;
41 : }
42 :
43 :
44 : /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
|