Bug 920377 part.30 Get rid of nsGUIEvent r=roc
This commit is contained in:
@@ -66,9 +66,9 @@ struct ParamTraits<nsEvent>
|
||||
};
|
||||
|
||||
template<>
|
||||
struct ParamTraits<nsGUIEvent>
|
||||
struct ParamTraits<mozilla::WidgetGUIEvent>
|
||||
{
|
||||
typedef nsGUIEvent paramType;
|
||||
typedef mozilla::WidgetGUIEvent paramType;
|
||||
|
||||
static void Write(Message* aMsg, const paramType& aParam)
|
||||
{
|
||||
@@ -88,13 +88,14 @@ struct ParamTraits<mozilla::WidgetInputEvent>
|
||||
|
||||
static void Write(Message* aMsg, const paramType& aParam)
|
||||
{
|
||||
WriteParam(aMsg, static_cast<nsGUIEvent>(aParam));
|
||||
WriteParam(aMsg, static_cast<mozilla::WidgetGUIEvent>(aParam));
|
||||
WriteParam(aMsg, aParam.modifiers);
|
||||
}
|
||||
|
||||
static bool Read(const Message* aMsg, void** aIter, paramType* aResult)
|
||||
{
|
||||
return ReadParam(aMsg, aIter, static_cast<nsGUIEvent*>(aResult)) &&
|
||||
return ReadParam(aMsg, aIter,
|
||||
static_cast<mozilla::WidgetGUIEvent*>(aResult)) &&
|
||||
ReadParam(aMsg, aIter, &aResult->modifiers);
|
||||
}
|
||||
};
|
||||
@@ -348,7 +349,7 @@ struct ParamTraits<mozilla::WidgetTextEvent>
|
||||
|
||||
static void Write(Message* aMsg, const paramType& aParam)
|
||||
{
|
||||
WriteParam(aMsg, static_cast<nsGUIEvent>(aParam));
|
||||
WriteParam(aMsg, static_cast<mozilla::WidgetGUIEvent>(aParam));
|
||||
WriteParam(aMsg, aParam.seqno);
|
||||
WriteParam(aMsg, aParam.theText);
|
||||
WriteParam(aMsg, aParam.isChar);
|
||||
@@ -359,7 +360,8 @@ struct ParamTraits<mozilla::WidgetTextEvent>
|
||||
|
||||
static bool Read(const Message* aMsg, void** aIter, paramType* aResult)
|
||||
{
|
||||
if (!ReadParam(aMsg, aIter, static_cast<nsGUIEvent*>(aResult)) ||
|
||||
if (!ReadParam(aMsg, aIter,
|
||||
static_cast<mozilla::WidgetGUIEvent*>(aResult)) ||
|
||||
!ReadParam(aMsg, aIter, &aResult->seqno) ||
|
||||
!ReadParam(aMsg, aIter, &aResult->theText) ||
|
||||
!ReadParam(aMsg, aIter, &aResult->isChar) ||
|
||||
@@ -397,14 +399,15 @@ struct ParamTraits<mozilla::WidgetCompositionEvent>
|
||||
|
||||
static void Write(Message* aMsg, const paramType& aParam)
|
||||
{
|
||||
WriteParam(aMsg, static_cast<nsGUIEvent>(aParam));
|
||||
WriteParam(aMsg, static_cast<mozilla::WidgetGUIEvent>(aParam));
|
||||
WriteParam(aMsg, aParam.seqno);
|
||||
WriteParam(aMsg, aParam.data);
|
||||
}
|
||||
|
||||
static bool Read(const Message* aMsg, void** aIter, paramType* aResult)
|
||||
{
|
||||
return ReadParam(aMsg, aIter, static_cast<nsGUIEvent*>(aResult)) &&
|
||||
return ReadParam(aMsg, aIter,
|
||||
static_cast<mozilla::WidgetGUIEvent*>(aResult)) &&
|
||||
ReadParam(aMsg, aIter, &aResult->seqno) &&
|
||||
ReadParam(aMsg, aIter, &aResult->data);
|
||||
}
|
||||
@@ -417,7 +420,7 @@ struct ParamTraits<mozilla::WidgetQueryContentEvent>
|
||||
|
||||
static void Write(Message* aMsg, const paramType& aParam)
|
||||
{
|
||||
WriteParam(aMsg, static_cast<nsGUIEvent>(aParam));
|
||||
WriteParam(aMsg, static_cast<mozilla::WidgetGUIEvent>(aParam));
|
||||
WriteParam(aMsg, aParam.mSucceeded);
|
||||
WriteParam(aMsg, aParam.mInput.mOffset);
|
||||
WriteParam(aMsg, aParam.mInput.mLength);
|
||||
@@ -432,7 +435,8 @@ struct ParamTraits<mozilla::WidgetQueryContentEvent>
|
||||
static bool Read(const Message* aMsg, void** aIter, paramType* aResult)
|
||||
{
|
||||
aResult->mWasAsync = true;
|
||||
return ReadParam(aMsg, aIter, static_cast<nsGUIEvent*>(aResult)) &&
|
||||
return ReadParam(aMsg, aIter,
|
||||
static_cast<mozilla::WidgetGUIEvent*>(aResult)) &&
|
||||
ReadParam(aMsg, aIter, &aResult->mSucceeded) &&
|
||||
ReadParam(aMsg, aIter, &aResult->mInput.mOffset) &&
|
||||
ReadParam(aMsg, aIter, &aResult->mInput.mLength) &&
|
||||
@@ -452,7 +456,7 @@ struct ParamTraits<mozilla::WidgetSelectionEvent>
|
||||
|
||||
static void Write(Message* aMsg, const paramType& aParam)
|
||||
{
|
||||
WriteParam(aMsg, static_cast<nsGUIEvent>(aParam));
|
||||
WriteParam(aMsg, static_cast<mozilla::WidgetGUIEvent>(aParam));
|
||||
WriteParam(aMsg, aParam.seqno);
|
||||
WriteParam(aMsg, aParam.mOffset);
|
||||
WriteParam(aMsg, aParam.mLength);
|
||||
@@ -463,7 +467,8 @@ struct ParamTraits<mozilla::WidgetSelectionEvent>
|
||||
|
||||
static bool Read(const Message* aMsg, void** aIter, paramType* aResult)
|
||||
{
|
||||
return ReadParam(aMsg, aIter, static_cast<nsGUIEvent*>(aResult)) &&
|
||||
return ReadParam(aMsg, aIter,
|
||||
static_cast<mozilla::WidgetGUIEvent*>(aResult)) &&
|
||||
ReadParam(aMsg, aIter, &aResult->seqno) &&
|
||||
ReadParam(aMsg, aIter, &aResult->mOffset) &&
|
||||
ReadParam(aMsg, aIter, &aResult->mLength) &&
|
||||
@@ -498,13 +503,14 @@ struct ParamTraits<mozilla::WidgetPluginEvent>
|
||||
|
||||
static void Write(Message* aMsg, const paramType& aParam)
|
||||
{
|
||||
WriteParam(aMsg, static_cast<nsGUIEvent>(aParam));
|
||||
WriteParam(aMsg, static_cast<mozilla::WidgetGUIEvent>(aParam));
|
||||
WriteParam(aMsg, aParam.retargetToFocusedDocument);
|
||||
}
|
||||
|
||||
static bool Read(const Message* aMsg, void** aIter, paramType* aResult)
|
||||
{
|
||||
return ReadParam(aMsg, aIter, static_cast<nsGUIEvent*>(aResult)) &&
|
||||
return ReadParam(aMsg, aIter,
|
||||
static_cast<mozilla::WidgetGUIEvent*>(aResult)) &&
|
||||
ReadParam(aMsg, aIter, &aResult->retargetToFocusedDocument);
|
||||
}
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user