summaryrefslogtreecommitdiffstats
path: root/testing/web-platform/tests/resources/webidl2/test/syntax/idl/typedef.widl
blob: b4c17d8d36a89fb50ec3bb6232a1237fe86dfb0e (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
// Extracted from http://dev.w3.org/2006/webapi/WebIDL/ on 2011-05-06
      interface Point {
        attribute float x;
        attribute float y;
      };

      typedef sequence<Point> PointSequence;

      interface Rect {
        attribute Point topleft;
        attribute Point bottomright;
      };

  interface Widget {

    readonly attribute Rect bounds;

    boolean pointWithinBounds(Point p);
    boolean allPointsWithinBounds(PointSequence ps);
  };

  typedef [Clamp] octet value;