From 77fbaff2faf6fc341e30a309f7e68458f2864ad9 Mon Sep 17 00:00:00 2001 From: janekptacijarabaci Date: Fri, 30 Mar 2018 23:25:42 +0200 Subject: Bug 1363672 - Add step support to date picker (follow up) Bug 1374967: https://bugzilla.mozilla.org/show_bug.cgi?id=1374967 (partially - implement getStep/getStepBase) --- dom/html/HTMLInputElement.h | 2 ++ dom/webidl/HTMLInputElement.webidl | 8 ++++++++ 2 files changed, 10 insertions(+) diff --git a/dom/html/HTMLInputElement.h b/dom/html/HTMLInputElement.h index 2321b7338..adab663c3 100644 --- a/dom/html/HTMLInputElement.h +++ b/dom/html/HTMLInputElement.h @@ -800,6 +800,8 @@ public: * The following are called from datetime input box binding to get the * corresponding computed values. */ + double GetStepAsDouble() { return GetStep().toDouble(); } + double GetStepBaseAsDouble() { return GetStepBase().toDouble(); } double GetMinimumAsDouble() { return GetMinimum().toDouble(); } double GetMaximumAsDouble() { return GetMaximum().toDouble(); } diff --git a/dom/webidl/HTMLInputElement.webidl b/dom/webidl/HTMLInputElement.webidl index c551d96ab..cf3e9a4c7 100644 --- a/dom/webidl/HTMLInputElement.webidl +++ b/dom/webidl/HTMLInputElement.webidl @@ -269,4 +269,12 @@ partial interface HTMLInputElement { [Pref="dom.forms.datetime", Func="IsChromeOrXBL"] void closeDateTimePicker(); + + [Pref="dom.forms.datetime", Func="IsChromeOrXBL", + BinaryName="getStepAsDouble"] + double getStep(); + + [Pref="dom.forms.datetime", Func="IsChromeOrXBL", + BinaryName="getStepBaseAsDouble"] + double getStepBase(); }; -- cgit v1.2.3