gecko/dom/events/FocusEvent.h
Masayuki Nakano b9f308e41e Bug 975688 part.10 Rename nsDOMFocusEvent to mozilla::dom::FocusEvent r=smaug
--HG--
rename : dom/events/nsDOMFocusEvent.cpp => dom/events/FocusEvent.cpp
rename : dom/events/nsDOMFocusEvent.h => dom/events/FocusEvent.h
2014-02-27 19:51:13 +09:00

55 lines
1.7 KiB
C++

/* vim: set shiftwidth=2 tabstop=8 autoindent cindent expandtab: */
/* 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/. */
#ifndef mozilla_dom_FocusEvent_h_
#define mozilla_dom_FocusEvent_h_
#include "nsDOMUIEvent.h"
#include "nsIDOMFocusEvent.h"
#include "mozilla/EventForwards.h"
#include "mozilla/dom/FocusEventBinding.h"
namespace mozilla {
namespace dom {
class FocusEvent : public nsDOMUIEvent,
public nsIDOMFocusEvent
{
public:
NS_DECL_ISUPPORTS
NS_DECL_NSIDOMFOCUSEVENT
// Forward to base class
NS_FORWARD_TO_NSDOMUIEVENT
virtual JSObject* WrapObject(JSContext* aCx,
JS::Handle<JSObject*> aScope) MOZ_OVERRIDE
{
return FocusEventBinding::Wrap(aCx, aScope, this);
}
FocusEvent(EventTarget* aOwner,
nsPresContext* aPresContext,
InternalFocusEvent* aEvent);
EventTarget* GetRelatedTarget();
static already_AddRefed<FocusEvent> Constructor(const GlobalObject& aGlobal,
const nsAString& aType,
const FocusEventInit& aParam,
ErrorResult& aRv);
protected:
nsresult InitFocusEvent(const nsAString& aType,
bool aCanBubble,
bool aCancelable,
nsIDOMWindow* aView,
int32_t aDetail,
EventTarget* aRelatedTarget);
};
} // namespace dom
} // namespace mozilla
#endif // mozilla_dom_FocusEvent_h_