File indexing completed on 2024-04-28 15:23:31

0001 /*
0002  * This file is part of the DOM implementation for KDE.
0003  *
0004  * Copyright (C) 1999 Lars Knoll (knoll@kde.org)
0005  *           (C) 1999 Antti Koivisto (koivisto@kde.org)
0006  *           (C) 2000 Simon Hausmann <hausmann@kde.org>
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 HTML_INLINEIMPL_H
0025 #define HTML_INLINEIMPL_H
0026 
0027 #include "html_elementimpl.h"
0028 
0029 namespace DOM
0030 {
0031 
0032 class HTMLAnchorElementImpl : public HTMLElementImpl
0033 {
0034 public:
0035     HTMLAnchorElementImpl(DocumentImpl *doc)
0036         : HTMLElementImpl(doc), m_hasTarget(false) {}
0037 
0038     bool isFocusableImpl(FocusType ft) const override;
0039     Id id() const override;
0040     void parseAttribute(AttributeImpl *attr) override;
0041     void defaultEventHandler(EventImpl *evt) override;
0042     void click();
0043 protected:
0044     bool m_hasTarget : 1;
0045 };
0046 
0047 // -------------------------------------------------------------------------
0048 
0049 class HTMLBRElementImpl : public HTMLElementImpl
0050 {
0051 public:
0052     HTMLBRElementImpl(DocumentImpl *doc)
0053         : HTMLElementImpl(doc) {}
0054 
0055     Id id() const override;
0056     void parseAttribute(AttributeImpl *attr) override;
0057     void attach() override;
0058 };
0059 
0060 // -------------------------------------------------------------------------
0061 
0062 class HTMLWBRElementImpl : public HTMLElementImpl
0063 {
0064 public:
0065     HTMLWBRElementImpl(DocumentImpl *doc)
0066         : HTMLElementImpl(doc) {}
0067 
0068     Id id() const override;
0069     void attach() override;
0070 };
0071 
0072 // -------------------------------------------------------------------------
0073 
0074 class HTMLFontElementImpl : public HTMLElementImpl
0075 {
0076 public:
0077     HTMLFontElementImpl(DocumentImpl *doc)
0078         : HTMLElementImpl(doc) {}
0079 
0080     Id id() const override;
0081     void parseAttribute(AttributeImpl *attr) override;
0082 };
0083 
0084 } //namespace
0085 
0086 #endif