The specification says nothing about coercing to integer.
MozReview-Commit-ID: Cq5Wbo2vIAD
--HG--
extra : rebase_source : 4b953dfd48bd2227508e725dcc0cc5efc97f0bb9
This patch adds nsISelection::AsSelection() for safer "upcast".
MozReview-Commit-ID: LlxoMaU0oE
--HG--
extra : rebase_source : 8b2fce25888bb256970ea1cb741a9f6fbe6dc542
TextComposition should update its composition start offset after every DOM event dispatch with first clause's selection type if there is composition string.
MozReview-Commit-ID: HFkePci1PhU
--HG--
extra : rebase_source : c7af075115505b52e48d8bbd5f2dd1d9001fe36e
Selection's focus and anchor node and offset are stored only for the last range. However, ContentEventHandler needs its first range. Therefore, ContentEventHandler shouldn't refer them if there are two or more selection ranges.
MozReview-Commit-ID: ACflFE3ZrOM
--HG--
extra : rebase_source : 9a2d1ef0e18a07881f77deff579830a4a0c97fc5
TextComposition needs to query first IME selection. Therefore, we need to add support to query special selection range with eQuerySelectedText.
First, WidgetQueryContentEvent::mInput should have mSelectionType which should be initialized with InitForQuerySelectedText() but unfortunately, there is no method for eQuerySelectedText. Therefore, this patch initializes WidgetQueryContentEvent::mInit::mSelectionType with SelectionType::eNormal in its constructor.
Next, ContentEventHandler needs to support to handle eQuerySelectedText with special selection types. However, we need to create 2 paths in some cases, one is for normal selection and the other is for special selections because there are no selection ranges may be usual case for special selections but not so for normal selection. Therefore, ContentEventHandler::InitCommon() becomes a little bit more complicated. ContentEventHandler::mSelection and ContentEventHandler::mFirstSelectedRange is initialized with the specified selection type but normal selection type is also necessary to compute the selection root since the selection root is computed from the first selected range which may not be anywhere if its selection type is not normal.
Finally, ContentEventHandler::OnQuerySelectedText() returns "there are no selections" as succeeded case in special selection type cases.
MozReview-Commit-ID: 9WzUx8b5piw
--HG--
extra : rebase_source : fb07b40748b594d36315f1fc21c0a02ff9f668bb
ContentEventHandler will need to support query any types of selection. Therefore, it cannot use nsCopySupport::GetSelectionForCopy(). Instead, a part of it should be implemented by nsIPresShell::GetSelectionControllerForFocusedContent() and it should be shared by nsCopySupport::GetSelectionForCopy() and ContentEventHandler.
MozReview-Commit-ID: 1ItkkIUPFMG
--HG--
extra : rebase_source : 3d33a76ebe52bad0ba7fbe332fc06500a2a007d7
TextComposition queries selection start offset a lot of times. Therefore, for reducing the runtime cost, it should use IMEContentObserver if it's available or ContentEventHandler, otherwise.
MozReview-Commit-ID: 61GgQZDX2HP
--HG--
extra : rebase_source : 2080f77fa36e967e070495b11cc7b72e42e63fd1
When composition string hasn't been non-empty, insertion point of the composition string can be changed by a DOM event handler. E.g., compositionstart, first compositionupdate and first text. Therefore, TextComposition should update the composition start offset cache after every event dispatch.
MozReview-Commit-ID: FOPewPTRuCn
--HG--
extra : rebase_source : 95fbba8130a1d21e957cee305b3b2a433bfae56a
Setting MOZ_DEBUG_SYMBOLS as a define was not moved, as this value is not
checked, and exporting MOZ_DEBUG_SYMBOLS was not moved, as this would only
impact nspr, and we're no longer using the nspr build system.
MozReview-Commit-ID: EvBTunhxcsr
It's enough to store target clause offset from start of the composition and better to modify mCompositionStartOffset because when even if mCompositionStartOffset is changed, we don't need to modify the target clause offset.
This patch renames mCompositionTargetOffset to mTargetClauseOffsetInComposition.
MozReview-Commit-ID: 1wt2OTUUjkY
--HG--
extra : rebase_source : 1bb87899c6f2e374252aaa00535915d42c6bb29d
This also fixes the issue of processing the artifacts twice in some
situations (bug 1275673). Note that the artifact download no longer
happens when a specific target is passed to 'mach build'.
MozReview-Commit-ID: Ktys6u3r1kG
Add FennecEmulatorRunner (for convenience), FennecRunner, FennecContext
and EmulatorAVD.
Common behaviour is defined in BaseEmulator and RemoteContext to distinguish
from B2G and Fennec specifics. I've tried to decouple ArchContext from
B2GContext, as well.
The emulator/adb commands in FennecRunner and EmulatorAVD are intended to
match the behaviour seen in current Android automation (e.g. mochitest).
MozReview-Commit-ID: 1tqD0DStdHR
--HG--
extra : rebase_source : 1450f3b03f82a0f9d33e43d19632a06a51ef7253