Bug 844362 - commit backout changes. DONTBUILD CLOSED TREE

This commit is contained in:
Jim Mathies 2013-03-13 09:10:47 -05:00
commit ad193ac20d

View File

@ -284,20 +284,6 @@ MetroInput::MetroInput(MetroWidget* aWidget,
NS_ASSERTION(aWidget, "Attempted to create MetroInput for null widget!");
NS_ASSERTION(aWindow, "Attempted to create MetroInput for null window!");
mTokenPointerPressed.value = 0;
mTokenPointerReleased.value = 0;
mTokenPointerMoved.value = 0;
mTokenPointerEntered.value = 0;
mTokenPointerExited.value = 0;
mTokenPointerWheelChanged.value = 0;
mTokenAcceleratorKeyActivated.value = 0;
mTokenEdgeGesture.value = 0;
mTokenManipulationStarted.value = 0;
mTokenManipulationUpdated.value = 0;
mTokenManipulationCompleted.value = 0;
mTokenTapped.value = 0;
mTokenRightTapped.value = 0;
mTouches.Init();
// Note that this is not thread-safe.
@ -1349,22 +1335,19 @@ void
MetroInput::UnregisterInputEvents() {
// Unregister ourselves for the edge swipe event
WRL::ComPtr<UI::Input::IEdgeGestureStatics> edgeStatics;
if (SUCCEEDED(Foundation::GetActivationFactory(
Foundation::GetActivationFactory(
WRL::Wrappers::HStringReference(
RuntimeClass_Windows_UI_Input_EdgeGesture).Get(),
edgeStatics.GetAddressOf()))) {
WRL::ComPtr<UI::Input::IEdgeGesture> edge;
if (SUCCEEDED(edgeStatics->GetForCurrentView(edge.GetAddressOf()))) {
edge->remove_Completed(mTokenEdgeGesture);
}
}
edgeStatics.GetAddressOf());
WRL::ComPtr<UI::Input::IEdgeGesture> edge;
edgeStatics->GetForCurrentView(edge.GetAddressOf());
edge->remove_Completed(mTokenEdgeGesture);
// Unregister ourselves from the AcceleratorKeyActivated event
WRL::ComPtr<ICoreAcceleratorKeys> coreAcceleratorKeys;
if (SUCCEEDED(mDispatcher.As<ICoreAcceleratorKeys>(&coreAcceleratorKeys))) {
coreAcceleratorKeys->remove_AcceleratorKeyActivated(
mTokenAcceleratorKeyActivated);
}
mDispatcher.As<ICoreAcceleratorKeys>(&coreAcceleratorKeys);
coreAcceleratorKeys->remove_AcceleratorKeyActivated(
mTokenAcceleratorKeyActivated);
// Unregister ourselves from the window events. This is extremely important;
// once this object is destroyed we don't want Windows to try to send events