summaryrefslogtreecommitdiffstats
path: root/accessible/ios/Platform.mm
diff options
context:
space:
mode:
authorDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-19 01:14:29 +0000
committerDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-19 01:14:29 +0000
commitfbaf0bb26397aa498eb9156f06d5a6fe34dd7dd8 (patch)
tree4c1ccaf5486d4f2009f9a338a98a83e886e29c97 /accessible/ios/Platform.mm
parentReleasing progress-linux version 124.0.1-1~progress7.99u1. (diff)
downloadfirefox-fbaf0bb26397aa498eb9156f06d5a6fe34dd7dd8.tar.xz
firefox-fbaf0bb26397aa498eb9156f06d5a6fe34dd7dd8.zip
Merging upstream version 125.0.1.
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'accessible/ios/Platform.mm')
-rw-r--r--accessible/ios/Platform.mm57
1 files changed, 57 insertions, 0 deletions
diff --git a/accessible/ios/Platform.mm b/accessible/ios/Platform.mm
new file mode 100644
index 0000000000..b4342ec555
--- /dev/null
+++ b/accessible/ios/Platform.mm
@@ -0,0 +1,57 @@
+/* -*- 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 "Platform.h"
+#include "RemoteAccessible.h"
+#include "DocAccessibleParent.h"
+
+#import "MUIAccessible.h"
+
+namespace mozilla {
+namespace a11y {
+
+bool ShouldA11yBeEnabled() {
+ // XXX: Figure out proper a11y activation strategies in iOS.
+ return true;
+}
+
+void PlatformInit() {}
+
+void PlatformShutdown() {}
+
+void ProxyCreated(RemoteAccessible* aProxy) {
+ MUIAccessible* mozWrapper = [[MUIAccessible alloc] initWithAccessible:aProxy];
+ aProxy->SetWrapper(reinterpret_cast<uintptr_t>(mozWrapper));
+}
+
+void ProxyDestroyed(RemoteAccessible* aProxy) {
+ MUIAccessible* wrapper = GetNativeFromGeckoAccessible(aProxy);
+ [wrapper expire];
+ [wrapper release];
+ aProxy->SetWrapper(0);
+}
+
+void PlatformEvent(Accessible*, uint32_t) {}
+
+void PlatformStateChangeEvent(Accessible*, uint64_t, bool) {}
+
+void PlatformFocusEvent(Accessible* aTarget,
+ const LayoutDeviceIntRect& aCaretRect) {}
+
+void PlatformCaretMoveEvent(Accessible* aTarget, int32_t aOffset,
+ bool aIsSelectionCollapsed, int32_t aGranularity,
+ const LayoutDeviceIntRect& aCaretRect,
+ bool aFromUser) {}
+
+void PlatformTextChangeEvent(Accessible*, const nsAString&, int32_t, uint32_t,
+ bool, bool) {}
+
+void PlatformShowHideEvent(Accessible*, Accessible*, bool, bool) {}
+
+void PlatformSelectionEvent(Accessible*, Accessible*, uint32_t) {}
+
+} // namespace a11y
+} // namespace mozilla