File indexing completed on 2024-04-28 15:24:43
0001 /* 0002 Copyright (C) 2004, 2005 Nikolas Zimmermann <wildfox@kde.org> 0003 Copyright (C) 2004, 2005 Rob Buis <buis@kde.org> 0004 Copyright (C) 2006 Samuel Weinig (sam.weinig@gmail.com) 0005 0006 This file is part of the KDE project 0007 0008 This library is free software; you can redistribute it and/or 0009 modify it under the terms of the GNU Library General Public 0010 License as published by the Free Software Foundation; either 0011 version 2 of the License, or (at your option) any later version. 0012 0013 This library is distributed in the hope that it will be useful, 0014 but WITHOUT ANY WARRANTY; without even the implied warranty of 0015 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 0016 Library General Public License for more details. 0017 0018 You should have received a copy of the GNU Library General Public License 0019 along with this library; see the file COPYING.LIB. If not, write to 0020 the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, 0021 Boston, MA 02110-1301, USA. 0022 */ 0023 0024 #ifndef SVGZoomEvent_h 0025 #define SVGZoomEvent_h 0026 #if ENABLE(SVG) 0027 0028 #include "FloatRect.h" 0029 #include "UIEvent.h" 0030 0031 namespace WebCore 0032 { 0033 0034 class SVGZoomEvent : public UIEvent 0035 { 0036 public: 0037 SVGZoomEvent(); 0038 virtual ~SVGZoomEvent(); 0039 0040 // 'SVGZoomEvent' functions 0041 FloatRect zoomRectScreen() const; 0042 0043 float previousScale() const; 0044 void setPreviousScale(float); 0045 0046 FloatPoint previousTranslate() const; 0047 0048 float newScale() const; 0049 void setNewScale(float); 0050 0051 FloatPoint newTranslate() const; 0052 0053 virtual bool isSVGZoomEvent() const; 0054 0055 private: 0056 float m_newScale; 0057 float m_previousScale; 0058 0059 FloatRect m_zoomRectScreen; 0060 0061 FloatPoint m_newTranslate; 0062 FloatPoint m_previousTranslate; 0063 }; 0064 0065 } // namespace WebCore 0066 0067 #endif // ENABLE(SVG) 0068 #endif // SVGZoomEvent_h 0069