зеркало из https://github.com/mozilla/pjs.git
Bug 569520 part 1. Add a new beforepaint event. r=smaug
This commit is contained in:
Родитель
7d9e21ba8d
Коммит
e333d3cf51
|
@ -665,6 +665,7 @@ nsContentUtils::InitializeEventTable() {
|
|||
{ nsGkAtoms::onvolumechange, NS_VOLUMECHANGE, EventNameType_HTML, NS_EVENT_NULL },
|
||||
#endif // MOZ_MEDIA
|
||||
{ nsGkAtoms::onMozAfterPaint, NS_AFTERPAINT, EventNameType_None, NS_EVENT },
|
||||
{ nsGkAtoms::onMozBeforePaint, NS_BEFOREPAINT, EventNameType_None, NS_EVENT_NULL },
|
||||
|
||||
{ nsGkAtoms::onMozScrolledAreaChanged, NS_SCROLLEDAREACHANGED, EventNameType_None, NS_SCROLLAREA_EVENT },
|
||||
|
||||
|
|
|
@ -669,6 +669,7 @@ GK_ATOM(onmouseover, "onmouseover")
|
|||
GK_ATOM(onMozMouseHittest, "onMozMouseHittest")
|
||||
GK_ATOM(onmouseup, "onmouseup")
|
||||
GK_ATOM(onMozAfterPaint, "onMozAfterPaint")
|
||||
GK_ATOM(onMozBeforePaint, "onMozBeforePaint")
|
||||
GK_ATOM(onMozMousePixelScroll, "onMozMousePixelScroll")
|
||||
GK_ATOM(onMozScrolledAreaChanged, "onMozScrolledAreaChanged")
|
||||
GK_ATOM(ononline, "ononline")
|
||||
|
|
|
@ -91,6 +91,7 @@ static const char* const sEventNames[] = {
|
|||
"durationchange", "volumechange",
|
||||
#endif // MOZ_MEDIA
|
||||
"MozAfterPaint",
|
||||
"MozBeforePaint",
|
||||
"MozSwipeGesture",
|
||||
"MozMagnifyGestureStart",
|
||||
"MozMagnifyGestureUpdate",
|
||||
|
@ -400,7 +401,7 @@ nsDOMEvent::GetCancelable(PRBool* aCancelable)
|
|||
NS_IMETHODIMP
|
||||
nsDOMEvent::GetTimeStamp(PRUint64* aTimeStamp)
|
||||
{
|
||||
LL_UI2L(*aTimeStamp, mEvent->time);
|
||||
*aTimeStamp = mEvent->time;
|
||||
return NS_OK;
|
||||
}
|
||||
|
||||
|
@ -1302,6 +1303,8 @@ const char* nsDOMEvent::GetEventName(PRUint32 aEventType)
|
|||
#endif
|
||||
case NS_AFTERPAINT:
|
||||
return sEventNames[eDOMEvents_afterpaint];
|
||||
case NS_BEFOREPAINT:
|
||||
return sEventNames[eDOMEvents_beforepaint];
|
||||
case NS_SIMPLE_GESTURE_SWIPE:
|
||||
return sEventNames[eDOMEvents_MozSwipeGesture];
|
||||
case NS_SIMPLE_GESTURE_MAGNIFY_START:
|
||||
|
|
|
@ -170,6 +170,7 @@ public:
|
|||
eDOMEvents_volumechange,
|
||||
#endif
|
||||
eDOMEvents_afterpaint,
|
||||
eDOMEvents_beforepaint,
|
||||
eDOMEvents_MozSwipeGesture,
|
||||
eDOMEvents_MozMagnifyGestureStart,
|
||||
eDOMEvents_MozMagnifyGestureUpdate,
|
||||
|
|
|
@ -413,6 +413,7 @@ class nsHashKey;
|
|||
// paint notification events
|
||||
#define NS_NOTIFYPAINT_START 3400
|
||||
#define NS_AFTERPAINT (NS_NOTIFYPAINT_START)
|
||||
#define NS_BEFOREPAINT (NS_NOTIFYPAINT_START+1)
|
||||
|
||||
// Simple gesture events
|
||||
#define NS_SIMPLE_GESTURE_EVENT_START 3500
|
||||
|
@ -534,7 +535,7 @@ public:
|
|||
nsIntPoint refPoint;
|
||||
// Elapsed time, in milliseconds, from a platform-specific zero time
|
||||
// to the time the message was created
|
||||
PRUint32 time;
|
||||
PRUint64 time;
|
||||
// Flags to hold event flow stage and capture/bubble cancellation
|
||||
// status. This is used also to indicate whether the event is trusted.
|
||||
PRUint32 flags;
|
||||
|
|
Загрузка…
Ссылка в новой задаче