summaryrefslogtreecommitdiffstats
path: root/widget/nsIDatePicker.idl
diff options
context:
space:
mode:
authorMatt A. Tobin <mattatobin@localhost.localdomain>2018-02-02 04:16:08 -0500
committerMatt A. Tobin <mattatobin@localhost.localdomain>2018-02-02 04:16:08 -0500
commit5f8de423f190bbb79a62f804151bc24824fa32d8 (patch)
tree10027f336435511475e392454359edea8e25895d /widget/nsIDatePicker.idl
parent49ee0794b5d912db1f95dce6eb52d781dc210db5 (diff)
downloadUXP-5f8de423f190bbb79a62f804151bc24824fa32d8.tar
UXP-5f8de423f190bbb79a62f804151bc24824fa32d8.tar.gz
UXP-5f8de423f190bbb79a62f804151bc24824fa32d8.tar.lz
UXP-5f8de423f190bbb79a62f804151bc24824fa32d8.tar.xz
UXP-5f8de423f190bbb79a62f804151bc24824fa32d8.zip
Add m-esr52 at 52.6.0
Diffstat (limited to 'widget/nsIDatePicker.idl')
-rw-r--r--widget/nsIDatePicker.idl50
1 files changed, 50 insertions, 0 deletions
diff --git a/widget/nsIDatePicker.idl b/widget/nsIDatePicker.idl
new file mode 100644
index 000000000..d6be60c95
--- /dev/null
+++ b/widget/nsIDatePicker.idl
@@ -0,0 +1,50 @@
+/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*-
+ *
+ * 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 "nsISupports.idl"
+
+interface mozIDOMWindowProxy;
+
+[scriptable, uuid(13388a28-1b0b-4218-a31b-588f7a4ec26c)]
+interface nsIDatePickerShownCallback : nsISupports
+{
+ /**
+ * Callback called when the user selects cancel in the date picker
+ * This callback can not be called after done() is called.
+ */
+ void cancel();
+
+ /**
+ * Callback called when the user has finished selecting the date
+ *
+ * @param date The new selected date value following the format "YYYY-MM-DD"
+ */
+ void done(in AString date);
+};
+
+[scriptable, uuid(7becfc64-966b-4d53-87d2-9161f36bd3b3)]
+interface nsIDatePicker : nsISupports
+{
+ /**
+ * Initialize the date picker widget. The date picker will not be shown until
+ * open() is called.
+ * If the initialDate parameter does not follow the format "YYYY-MM-DD" then
+ * the behavior will be unspecified.
+ *
+ * @param parent nsIDOMWindow parent. This dialog will be dependent
+ * on this parent. parent may be null.
+ * @param title The title for the date picker widget.
+ * @param initialDate The date to show when the widget is opened. The
+ * parameter has to follow the format "YYYY-MM-DD"
+ */
+ void init(in mozIDOMWindowProxy parent, in AString title, in AString initialDate);
+
+ /**
+ * Opens the date dialog asynchrounously.
+ * The results are provided via the callback object.
+ */
+ void open(in nsIDatePickerShownCallback callback);
+};