~oif-team/ubuntu/natty/qt4-x11/xi2.1

« back to all changes in this revision

Viewing changes to src/3rdparty/webkit/WebCore/rendering/HitTestRequest.h

  • Committer: Bazaar Package Importer
  • Author(s): Alessandro Ghersi
  • Date: 2009-11-02 18:30:08 UTC
  • mfrom: (1.2.2 upstream)
  • mto: (15.2.5 experimental)
  • mto: This revision was merged to the branch mainline in revision 88.
  • Revision ID: james.westby@ubuntu.com-20091102183008-b6a4gcs128mvfb3m
Tags: upstream-4.6.0~beta1
ImportĀ upstreamĀ versionĀ 4.6.0~beta1

Show diffs side-by-side

added added

removed removed

Lines of Context:
2
2
 * This file is part of the HTML rendering engine for KDE.
3
3
 *
4
4
 * Copyright (C) 2006 Apple Computer, Inc.
 
5
 * Copyright (C) 2009 Torch Mobile Inc. http://www.torchmobile.com/
5
6
 *
6
7
 * This library is free software; you can redistribute it and/or
7
8
 * modify it under the terms of the GNU Library General Public
19
20
 * Boston, MA 02110-1301, USA.
20
21
 *
21
22
*/
 
23
 
22
24
#ifndef HitTestRequest_h
23
25
#define HitTestRequest_h
24
26
 
25
27
namespace WebCore {
26
28
 
27
 
struct HitTestRequest {
28
 
    HitTestRequest(bool r, bool a, bool m = false, bool u = false)
29
 
        : readonly(r)
30
 
        , active(a)
31
 
        , mouseMove(m)
32
 
        , mouseUp(u)
33
 
    { 
 
29
class HitTestRequest {
 
30
public:
 
31
    enum RequestType {
 
32
        ReadOnly = 0x1,
 
33
        Active = 0x2,
 
34
        MouseMove = 0x4,
 
35
        MouseUp = 0x8,
 
36
        IgnoreClipping = 0x10
 
37
    };
 
38
 
 
39
    HitTestRequest(int requestType)
 
40
        : m_requestType(requestType)
 
41
    {
34
42
    }
35
43
 
36
 
    bool readonly;
37
 
    bool active;
38
 
    bool mouseMove;
39
 
    bool mouseUp;
 
44
    bool readOnly() const { return m_requestType & ReadOnly; }
 
45
    bool active() const { return m_requestType & Active; }
 
46
    bool mouseMove() const { return m_requestType & MouseMove; }
 
47
    bool mouseUp() const { return m_requestType & MouseUp; }
 
48
    bool ignoreClipping() const { return m_requestType & IgnoreClipping; }
 
49
 
 
50
private:
 
51
    int m_requestType;
40
52
};
41
53
 
42
54
} // namespace WebCore