summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--ui/message_center/cocoa/popup_collection_unittest.mm46
-rw-r--r--ui/message_center/cocoa/popup_controller.mm8
2 files changed, 0 insertions, 54 deletions
diff --git a/ui/message_center/cocoa/popup_collection_unittest.mm b/ui/message_center/cocoa/popup_collection_unittest.mm
index ca4cb8f..80c3874 100644
--- a/ui/message_center/cocoa/popup_collection_unittest.mm
+++ b/ui/message_center/cocoa/popup_collection_unittest.mm
@@ -402,50 +402,4 @@ TEST_F(PopupCollectionTest, CloseCollectionBeforeUpdatePopupAnimationEnds) {
collection_.reset();
}
-// This test reproduces bug.
-// https://code.google.com/p/chromium/issues/detail?id=418053
-// It will timeout if problem exists.
-TEST_F(PopupCollectionTest, AnimationDidEndOutOfOrder) {
- // Set animation duration to 100 ms.
- [collection_ setAnimationDuration:0.1];
-
- // Add three notifications.
- AddThreeNotifications();
-
- // Wait for animation end.
- WaitForAnimationEnded();
-
- // Add fourth notification.
- scoped_ptr<message_center::Notification> notification;
- notification.reset(new message_center::Notification(
- message_center::NOTIFICATION_TYPE_SIMPLE,
- "4",
- ASCIIToUTF16("Fourth"),
- ASCIIToUTF16("This is the Fourth notification to be displayed"),
- gfx::Image(),
- base::string16(),
- DummyNotifierId(),
- message_center::RichNotificationData(),
- NULL));
- center_->AddNotification(notification.Pass());
-
- // Mark first notifications as shown,
- // just as from TimerFinished callback.
- // Mark it while fourth animation is in progress so old notification
- // will be marked as pending updates.
- center_->MarkSinglePopupAsShown("1", false);
- center_->MarkSinglePopupAsShown("2", false);
- center_->MarkSinglePopupAsShown("3", false);
-
- WaitForAnimationEnded();
- // Assert that isAnimating flag is false ater animation ends.
- // If it will be true after all animaions ends,
- // no new notification can be added and collection will be blocked.
- EXPECT_FALSE([collection_ isAnimating]);
-
- // Release the popup collection before the animation ends. No crash should
- // be expected.
- collection_.reset();
-}
-
} // namespace message_center
diff --git a/ui/message_center/cocoa/popup_controller.mm b/ui/message_center/cocoa/popup_controller.mm
index 889d8de..da3bb38 100644
--- a/ui/message_center/cocoa/popup_controller.mm
+++ b/ui/message_center/cocoa/popup_controller.mm
@@ -206,14 +206,6 @@
[self close];
}
-- (void)animationDidStop:(NSAnimation*)animation {
- // We can arrive here if animation was stopped in [self close] call.
- DCHECK_EQ(animation, boundsAnimation_.get());
- [self setBoundsAnimation:nil];
-
- [popupCollection_ onPopupAnimationEnded:[self notificationID]];
-}
-
- (void)showWithAnimation:(NSRect)newBounds {
bounds_ = newBounds;
NSRect startBounds = newBounds;