2011-04-27 17:42:18 +04:00
|
|
|
/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
|
2011-05-28 02:37:24 +04:00
|
|
|
/* vim: set ts=2 et sw=2 tw=80: */
|
2012-05-21 15:12:37 +04:00
|
|
|
/* 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/. */
|
2011-04-27 17:42:18 +04:00
|
|
|
|
|
|
|
#ifndef _AtkSocketAccessible_H_
|
|
|
|
#define _AtkSocketAccessible_H_
|
|
|
|
|
2012-05-29 05:18:45 +04:00
|
|
|
#include "AccessibleWrap.h"
|
2011-04-27 17:42:18 +04:00
|
|
|
|
|
|
|
// This file gets included by nsAccessibilityService.cpp, which can't include
|
|
|
|
// atk.h (or glib.h), so we can't rely on it being included.
|
|
|
|
#ifdef __ATK_H__
|
2012-03-20 08:02:50 +04:00
|
|
|
extern "C" typedef void (*AtkSocketEmbedType)(AtkSocket*, gchar*);
|
2011-04-27 17:42:18 +04:00
|
|
|
#else
|
2012-03-20 08:02:50 +04:00
|
|
|
extern "C" typedef void (*AtkSocketEmbedType)(void*, void*);
|
2011-04-27 17:42:18 +04:00
|
|
|
#endif
|
|
|
|
|
2012-11-18 06:01:44 +04:00
|
|
|
namespace mozilla {
|
|
|
|
namespace a11y {
|
|
|
|
|
2011-04-27 17:42:18 +04:00
|
|
|
/**
|
2012-05-29 05:18:45 +04:00
|
|
|
* Provides a AccessibleWrap wrapper around AtkSocket for out-of-process
|
2011-04-27 17:42:18 +04:00
|
|
|
* accessibles.
|
|
|
|
*/
|
2012-05-29 05:18:45 +04:00
|
|
|
class AtkSocketAccessible : public AccessibleWrap {
|
2011-04-27 17:42:18 +04:00
|
|
|
public:
|
|
|
|
// Soft references to AtkSocket
|
|
|
|
static AtkSocketEmbedType g_atk_socket_embed;
|
|
|
|
#ifdef __ATK_H__
|
|
|
|
static GType g_atk_socket_type;
|
|
|
|
#endif
|
|
|
|
static const char* sATKSocketEmbedSymbol;
|
|
|
|
static const char* sATKSocketGetTypeSymbol;
|
|
|
|
|
|
|
|
/*
|
|
|
|
* True if the current Atk version supports AtkSocket and it was correctly
|
|
|
|
* loaded.
|
|
|
|
*/
|
|
|
|
static bool gCanEmbed;
|
|
|
|
|
2012-05-27 13:01:40 +04:00
|
|
|
AtkSocketAccessible(nsIContent* aContent, DocAccessible* aDoc,
|
2011-04-27 17:42:18 +04:00
|
|
|
const nsCString& aPlugId);
|
|
|
|
|
2015-03-21 19:28:04 +03:00
|
|
|
virtual void Shutdown() override;
|
2011-04-27 17:42:18 +04:00
|
|
|
|
2015-03-21 19:28:04 +03:00
|
|
|
virtual void GetNativeInterface(void** aOutAccessible) override;
|
2011-04-27 17:42:18 +04:00
|
|
|
};
|
|
|
|
|
2012-11-18 06:01:44 +04:00
|
|
|
} // namespace a11y
|
|
|
|
} // namespace mozilla
|
|
|
|
|
2011-04-27 17:42:18 +04:00
|
|
|
#endif
|