Copy as Markdown

Other Tools

/*
* DO NOT EDIT. THIS FILE IS GENERATED FROM $SRCDIR/widget/nsITouchBarHelper.idl
*/
#ifndef __gen_nsITouchBarHelper_h__
#define __gen_nsITouchBarHelper_h__
#include "nsIArray.h"
#include "nsISupports.h"
#include "nsITouchBarInput.h"
#include "js/GCAnnotations.h"
/* For IDL files that don't want to include root IDL files. */
#ifndef NS_NO_VTABLE
#define NS_NO_VTABLE
#endif
namespace mozilla {
namespace dom {
class Document; /* webidl Document */
} // namespace dom
} // namespace mozilla
/* starting interface: nsITouchBarHelper */
#define NS_ITOUCHBARHELPER_IID_STR "ea109912-3acc-48de-b679-c23b6a122da5"
#define NS_ITOUCHBARHELPER_IID \
{0xea109912, 0x3acc, 0x48de, \
{ 0xb6, 0x79, 0xc2, 0x3b, 0x6a, 0x12, 0x2d, 0xa5 }}
class NS_NO_VTABLE nsITouchBarHelper : public nsISupports {
public:
NS_DECLARE_STATIC_IID_ACCESSOR(NS_ITOUCHBARHELPER_IID)
/* Used by ToJSValue to check which scriptable interface is implemented. */
using ScriptableInterfaceType = nsITouchBarHelper;
/* readonly attribute AString activeUrl; */
JS_HAZ_CAN_RUN_SCRIPT NS_IMETHOD GetActiveUrl(nsAString& aActiveUrl) = 0;
/* readonly attribute AString activeTitle; */
JS_HAZ_CAN_RUN_SCRIPT NS_IMETHOD GetActiveTitle(nsAString& aActiveTitle) = 0;
/* readonly attribute boolean isUrlbarFocused; */
JS_HAZ_CAN_RUN_SCRIPT NS_IMETHOD GetIsUrlbarFocused(bool *aIsUrlbarFocused) = 0;
/* void toggleFocusUrlbar (); */
JS_HAZ_CAN_RUN_SCRIPT NS_IMETHOD ToggleFocusUrlbar(void) = 0;
/* void unfocusUrlbar (); */
JS_HAZ_CAN_RUN_SCRIPT NS_IMETHOD UnfocusUrlbar(void) = 0;
/* attribute nsIArray allItems; */
JS_HAZ_CAN_RUN_SCRIPT NS_IMETHOD GetAllItems(nsIArray **aAllItems) = 0;
JS_HAZ_CAN_RUN_SCRIPT NS_IMETHOD SetAllItems(nsIArray *aAllItems) = 0;
/* readonly attribute Document document; */
JS_HAZ_CAN_RUN_SCRIPT NS_IMETHOD GetDocument(mozilla::dom::Document **aDocument) = 0;
/* nsITouchBarInput getTouchBarInput (in string aInputName); */
JS_HAZ_CAN_RUN_SCRIPT NS_IMETHOD GetTouchBarInput(const char * aInputName, nsITouchBarInput **_retval) = 0;
/* void insertRestrictionInUrlbar (in string aToken); */
JS_HAZ_CAN_RUN_SCRIPT NS_IMETHOD InsertRestrictionInUrlbar(const char * aToken) = 0;
};
NS_DEFINE_STATIC_IID_ACCESSOR(nsITouchBarHelper, NS_ITOUCHBARHELPER_IID)
/* Use this macro when declaring classes that implement this interface. */
#define NS_DECL_NSITOUCHBARHELPER \
NS_IMETHOD GetActiveUrl(nsAString& aActiveUrl) override; \
NS_IMETHOD GetActiveTitle(nsAString& aActiveTitle) override; \
NS_IMETHOD GetIsUrlbarFocused(bool *aIsUrlbarFocused) override; \
NS_IMETHOD ToggleFocusUrlbar(void) override; \
NS_IMETHOD UnfocusUrlbar(void) override; \
NS_IMETHOD GetAllItems(nsIArray **aAllItems) override; \
NS_IMETHOD SetAllItems(nsIArray *aAllItems) override; \
NS_IMETHOD GetDocument(mozilla::dom::Document **aDocument) override; \
NS_IMETHOD GetTouchBarInput(const char * aInputName, nsITouchBarInput **_retval) override; \
NS_IMETHOD InsertRestrictionInUrlbar(const char * aToken) override;
/* Use this macro when declaring the members of this interface when the
class doesn't implement the interface. This is useful for forwarding. */
#define NS_DECL_NON_VIRTUAL_NSITOUCHBARHELPER \
nsresult GetActiveUrl(nsAString& aActiveUrl); \
nsresult GetActiveTitle(nsAString& aActiveTitle); \
nsresult GetIsUrlbarFocused(bool *aIsUrlbarFocused); \
nsresult ToggleFocusUrlbar(void); \
nsresult UnfocusUrlbar(void); \
nsresult GetAllItems(nsIArray **aAllItems); \
nsresult SetAllItems(nsIArray *aAllItems); \
nsresult GetDocument(mozilla::dom::Document **aDocument); \
nsresult GetTouchBarInput(const char * aInputName, nsITouchBarInput **_retval); \
nsresult InsertRestrictionInUrlbar(const char * aToken);
/* Use this macro to declare functions that forward the behavior of this interface to another object. */
#define NS_FORWARD_NSITOUCHBARHELPER(_to) \
NS_IMETHOD GetActiveUrl(nsAString& aActiveUrl) override { return _to GetActiveUrl(aActiveUrl); } \
NS_IMETHOD GetActiveTitle(nsAString& aActiveTitle) override { return _to GetActiveTitle(aActiveTitle); } \
NS_IMETHOD GetIsUrlbarFocused(bool *aIsUrlbarFocused) override { return _to GetIsUrlbarFocused(aIsUrlbarFocused); } \
NS_IMETHOD ToggleFocusUrlbar(void) override { return _to ToggleFocusUrlbar(); } \
NS_IMETHOD UnfocusUrlbar(void) override { return _to UnfocusUrlbar(); } \
NS_IMETHOD GetAllItems(nsIArray **aAllItems) override { return _to GetAllItems(aAllItems); } \
NS_IMETHOD SetAllItems(nsIArray *aAllItems) override { return _to SetAllItems(aAllItems); } \
NS_IMETHOD GetDocument(mozilla::dom::Document **aDocument) override { return _to GetDocument(aDocument); } \
NS_IMETHOD GetTouchBarInput(const char * aInputName, nsITouchBarInput **_retval) override { return _to GetTouchBarInput(aInputName, _retval); } \
NS_IMETHOD InsertRestrictionInUrlbar(const char * aToken) override { return _to InsertRestrictionInUrlbar(aToken); }
/* Use this macro to declare functions that forward the behavior of this interface to another object in a safe way. */
#define NS_FORWARD_SAFE_NSITOUCHBARHELPER(_to) \
NS_IMETHOD GetActiveUrl(nsAString& aActiveUrl) override { return !_to ? NS_ERROR_NULL_POINTER : _to->GetActiveUrl(aActiveUrl); } \
NS_IMETHOD GetActiveTitle(nsAString& aActiveTitle) override { return !_to ? NS_ERROR_NULL_POINTER : _to->GetActiveTitle(aActiveTitle); } \
NS_IMETHOD GetIsUrlbarFocused(bool *aIsUrlbarFocused) override { return !_to ? NS_ERROR_NULL_POINTER : _to->GetIsUrlbarFocused(aIsUrlbarFocused); } \
NS_IMETHOD ToggleFocusUrlbar(void) override { return !_to ? NS_ERROR_NULL_POINTER : _to->ToggleFocusUrlbar(); } \
NS_IMETHOD UnfocusUrlbar(void) override { return !_to ? NS_ERROR_NULL_POINTER : _to->UnfocusUrlbar(); } \
NS_IMETHOD GetAllItems(nsIArray **aAllItems) override { return !_to ? NS_ERROR_NULL_POINTER : _to->GetAllItems(aAllItems); } \
NS_IMETHOD SetAllItems(nsIArray *aAllItems) override { return !_to ? NS_ERROR_NULL_POINTER : _to->SetAllItems(aAllItems); } \
NS_IMETHOD GetDocument(mozilla::dom::Document **aDocument) override { return !_to ? NS_ERROR_NULL_POINTER : _to->GetDocument(aDocument); } \
NS_IMETHOD GetTouchBarInput(const char * aInputName, nsITouchBarInput **_retval) override { return !_to ? NS_ERROR_NULL_POINTER : _to->GetTouchBarInput(aInputName, _retval); } \
NS_IMETHOD InsertRestrictionInUrlbar(const char * aToken) override { return !_to ? NS_ERROR_NULL_POINTER : _to->InsertRestrictionInUrlbar(aToken); }
#endif /* __gen_nsITouchBarHelper_h__ */