2014-03-08 01:35:19 +04:00
|
|
|
/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
|
|
|
|
/* vim: set ts=2 et sw=2 tw=80: */
|
|
|
|
/* This Source Code Form is subject to the terms of the Mozilla Public
|
|
|
|
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
|
|
|
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
|
|
|
|
|
|
|
|
include protocol PContent;
|
|
|
|
|
2015-03-09 23:42:55 +03:00
|
|
|
include "mozilla/GfxMessageUtils.h";
|
|
|
|
|
2015-03-23 00:44:12 +03:00
|
|
|
using struct nsIntPoint from "nsRect.h";
|
|
|
|
using struct nsIntSize from "nsRect.h";
|
2015-03-08 05:33:57 +03:00
|
|
|
using struct nsIntRect from "nsRect.h";
|
|
|
|
|
2014-03-08 01:35:19 +04:00
|
|
|
namespace mozilla {
|
|
|
|
namespace a11y {
|
|
|
|
|
|
|
|
struct AccessibleData
|
|
|
|
{
|
|
|
|
uint64_t ID;
|
|
|
|
uint32_t Role;
|
|
|
|
uint32_t ChildrenCount;
|
2015-01-09 23:01:39 +03:00
|
|
|
uint32_t Interfaces;
|
2014-03-08 01:35:19 +04:00
|
|
|
};
|
|
|
|
|
|
|
|
struct ShowEventData
|
|
|
|
{
|
|
|
|
uint64_t ID;
|
|
|
|
uint32_t Idx;
|
|
|
|
AccessibleData[] NewTree;
|
|
|
|
};
|
|
|
|
|
2014-10-24 13:29:48 +04:00
|
|
|
struct Attribute
|
|
|
|
{
|
|
|
|
nsCString Name;
|
|
|
|
nsString Value;
|
|
|
|
};
|
|
|
|
|
2015-01-29 19:58:34 +03:00
|
|
|
struct RelationTargets
|
|
|
|
{
|
|
|
|
uint32_t Type;
|
|
|
|
uint64_t[] Targets;
|
|
|
|
};
|
|
|
|
|
2014-09-23 12:35:33 +04:00
|
|
|
prio(normal upto high) sync protocol PDocAccessible
|
2014-03-08 01:35:19 +04:00
|
|
|
{
|
|
|
|
manager PContent;
|
|
|
|
|
|
|
|
parent:
|
|
|
|
__delete__();
|
|
|
|
|
|
|
|
/*
|
|
|
|
* Notify the parent process the document in the child process is firing an
|
|
|
|
* event.
|
|
|
|
*/
|
2014-09-30 18:00:26 +04:00
|
|
|
Event(uint64_t aID, uint32_t type);
|
2014-03-08 01:35:19 +04:00
|
|
|
ShowEvent(ShowEventData data);
|
|
|
|
HideEvent(uint64_t aRootID);
|
2014-09-23 12:35:33 +04:00
|
|
|
|
2015-03-24 20:52:59 +03:00
|
|
|
/*
|
|
|
|
* Tell the parent document to bind the existing document as a new child
|
|
|
|
* document.
|
|
|
|
*/
|
|
|
|
BindChildDoc(PDocAccessible aChildDoc, uint64_t aID);
|
|
|
|
|
2014-09-23 12:35:33 +04:00
|
|
|
child:
|
2015-02-12 23:56:13 +03:00
|
|
|
// Accessible
|
2014-09-23 12:35:33 +04:00
|
|
|
prio(high) sync State(uint64_t aID) returns(uint64_t states);
|
2014-09-23 13:53:03 +04:00
|
|
|
prio(high) sync Name(uint64_t aID) returns(nsString name);
|
2015-02-11 23:00:11 +03:00
|
|
|
prio(high) sync Value(uint64_t aID) returns(nsString value);
|
2014-10-24 07:21:44 +04:00
|
|
|
prio(high) sync Description(uint64_t aID) returns(nsString desc);
|
2014-10-24 13:29:48 +04:00
|
|
|
prio(high) sync Attributes(uint64_t aID) returns(Attribute[] attributes);
|
2015-01-29 19:58:34 +03:00
|
|
|
prio(high) sync RelationByType(uint64_t aID, uint32_t aRelationType)
|
|
|
|
returns(uint64_t[] targets);
|
|
|
|
prio(high) sync Relations(uint64_t aID) returns(RelationTargets[] relations);
|
2015-02-12 23:56:13 +03:00
|
|
|
|
|
|
|
// AccessibleText
|
|
|
|
|
|
|
|
// TextSubstring is getText in IDL.
|
2015-03-06 23:43:25 +03:00
|
|
|
prio(high) sync CaretOffset(uint64_t aID) returns(int32_t aOffset);
|
|
|
|
prio(high) sync SetCaretOffset(uint64_t aID, int32_t aOffset) returns (bool aValid);
|
2015-02-25 15:18:17 +03:00
|
|
|
prio(high) sync CharacterCount(uint64_t aID) returns(int32_t aCount);
|
|
|
|
prio(high) sync SelectionCount(uint64_t aID) returns(int32_t aCount);
|
2015-02-11 23:00:11 +03:00
|
|
|
prio(high) sync TextSubstring(uint64_t aID, int32_t aStartOffset, int32_t
|
|
|
|
aEndOffset) returns(nsString aText);
|
2015-02-17 22:35:40 +03:00
|
|
|
prio(high) sync GetTextAfterOffset(uint64_t aID, int32_t aOffset, int32_t aBoundaryType)
|
2015-02-12 23:56:13 +03:00
|
|
|
returns(nsString aText, int32_t aStartOffset, int32_t aEndOffset);
|
2015-02-17 22:35:40 +03:00
|
|
|
prio(high) sync GetTextAtOffset(uint64_t aID, int32_t aOffset, int32_t aBoundaryType)
|
2015-02-12 23:56:13 +03:00
|
|
|
returns(nsString aText, int32_t aStartOffset, int32_t aEndOffset);
|
2015-03-06 23:44:02 +03:00
|
|
|
|
2015-02-17 22:35:40 +03:00
|
|
|
prio(high) sync GetTextBeforeOffset(uint64_t aID, int32_t aOffset, int32_t aBoundaryType)
|
2015-02-12 23:56:13 +03:00
|
|
|
returns(nsString aText, int32_t aStartOffset, int32_t aEndOffset);
|
2015-03-06 20:37:37 +03:00
|
|
|
prio(high) sync CharAt(uint64_t aID, int32_t aOffset) returns(uint16_t aChar);
|
2015-03-06 23:44:02 +03:00
|
|
|
|
|
|
|
prio(high) sync TextAttributes(uint64_t aID, bool aIncludeDefAttrs, int32_t aOffset)
|
|
|
|
returns(Attribute[] aAttributes, int32_t aStartOffset, int32_t aEndOffset);
|
|
|
|
prio(high) sync DefaultTextAttributes(uint64_t aID) returns(Attribute[] aAttributes);
|
2015-03-08 05:33:57 +03:00
|
|
|
|
|
|
|
prio(high) sync TextBounds(uint64_t aID, int32_t aStartOffset, int32_t aEndOffset,
|
|
|
|
uint32_t aCoordType)
|
|
|
|
returns(nsIntRect aRetVal);
|
|
|
|
prio(high) sync CharBounds(uint64_t aID, int32_t aOffset, uint32_t aCoordType)
|
|
|
|
returns(nsIntRect aRetVal);
|
2015-03-08 15:05:55 +03:00
|
|
|
|
|
|
|
prio(high) sync OffsetAtPoint(uint64_t aID, int32_t aX, int32_t aY, uint32_t aCoordType)
|
|
|
|
returns(int32_t aRetVal);
|
2015-03-09 23:50:16 +03:00
|
|
|
|
|
|
|
prio(high) sync SelectionBoundsAt(uint64_t aID, int32_t aSelectionNum)
|
|
|
|
returns(bool aSucceeded, nsString aData, int32_t aStartOffset, int32_t aEndOffset);
|
|
|
|
prio(high) sync SetSelectionBoundsAt(uint64_t aID, int32_t aSelectionNum,
|
|
|
|
int32_t aStartOffset, int32_t aEndOffset)
|
|
|
|
returns(bool aSucceeded);
|
|
|
|
prio(high) sync AddToSelection(uint64_t aID, int32_t aStartOffset, int32_t aEndOffset)
|
|
|
|
returns(bool aSucceeded);
|
|
|
|
prio(high) sync RemoveFromSelection(uint64_t aID, int32_t aSelectionNum)
|
|
|
|
returns(bool aSucceeded);
|
2015-03-09 23:51:02 +03:00
|
|
|
|
|
|
|
ScrollSubstringTo(uint64_t aID, int32_t aStartOffset, int32_t aEndOffset,
|
|
|
|
uint32_t aScrollType);
|
|
|
|
ScrollSubstringToPoint(uint64_t aID,
|
|
|
|
int32_t aStartOffset,
|
|
|
|
int32_t aEndOffset,
|
|
|
|
uint32_t aCoordinateType,
|
|
|
|
int32_t aX, int32_t aY);
|
2015-03-10 00:04:02 +03:00
|
|
|
|
|
|
|
prio(high) sync ReplaceText(uint64_t aID, nsString aText);
|
|
|
|
prio(high) sync InsertText(uint64_t aID, nsString aText, int32_t aPosition);
|
|
|
|
prio(high) sync CopyText(uint64_t aID, int32_t aStartPos, int32_t aEndPos);
|
|
|
|
prio(high) sync CutText(uint64_t aID, int32_t aStartPos, int32_t aEndPos);
|
|
|
|
prio(high) sync DeleteText(uint64_t aID, int32_t aStartPos, int32_t aEndPos);
|
|
|
|
prio(high) sync PasteText(uint64_t aID, int32_t aPosition);
|
2015-03-23 00:44:12 +03:00
|
|
|
|
|
|
|
prio(high) sync ImagePosition(uint64_t aID, uint32_t aCoordType) returns(nsIntPoint aRetVal);
|
|
|
|
prio(high) sync ImageSize(uint64_t aID) returns(nsIntSize aRetVal);
|
2015-03-25 17:03:13 +03:00
|
|
|
|
|
|
|
prio(high) sync StartOffset(uint64_t aID) returns(uint32_t aRetVal, bool aOk);
|
|
|
|
prio(high) sync EndOffset(uint64_t aID) returns(uint32_t aRetVal, bool aOk);
|
|
|
|
prio(high) sync IsLinkValid(uint64_t aID) returns(bool aRetVal);
|
|
|
|
prio(high) sync AnchorCount(uint64_t aID) returns(uint32_t aRetVal, bool aOk);
|
|
|
|
prio(high) sync AnchorURIAt(uint64_t aID, uint32_t aIndex) returns(nsCString aURI, bool aOk);
|
|
|
|
prio(high) sync AnchorAt(uint64_t aID, uint32_t aIndex) returns(uint64_t aIDOfAnchor, bool aOk);
|
2015-03-25 17:05:18 +03:00
|
|
|
|
|
|
|
prio(high) sync LinkCount(uint64_t aID) returns(uint32_t aCount);
|
|
|
|
prio(high) sync LinkAt(uint64_t aID, uint32_t aIndex) returns(uint64_t aIDOfLink, bool aOk);
|
|
|
|
prio(high) sync LinkIndexOf(uint64_t aID, uint64_t aLinkID) returns(int32_t aIndex);
|
|
|
|
prio(high) sync LinkIndexAtOffset(uint64_t aID, uint32_t aOffset) returns(int32_t aIndex);
|
|
|
|
|
2014-03-08 01:35:19 +04:00
|
|
|
};
|
|
|
|
|
|
|
|
}
|
|
|
|
}
|