Commit cc0c047f authored by Oscar Johansson's avatar Oscar Johansson Committed by Commit Bot

Specify class type before calling setCornerFlags (mac)

Specifying what subclass of NSView being called,
in this  case BubbleView.

Bug: 803406
Change-Id: Iabc0a02ab17a881993f34b9c120978ca7f45264c
Reviewed-on: https://chromium-review.googlesource.com/1141879Reviewed-by: default avatarAvi Drissman <avi@chromium.org>
Commit-Queue: Oscar Johansson <oscarj@opera.com>
Cr-Commit-Position: refs/heads/master@{#576137}
parent 47e17816
......@@ -9,6 +9,7 @@
#include "base/bind.h"
#include "base/compiler_specific.h"
#include "base/debug/stack_trace.h"
#include "base/mac/foundation_util.h"
#include "base/mac/scoped_block.h"
#include "base/mac/sdk_forward_declarations.h"
#include "base/strings/string_util.h"
......@@ -393,7 +394,9 @@ void StatusBubbleMac::SetFrameAvoidingMouse(
corner_flags |= OSDependentCornerFlags(window_frame);
[[window_ contentView] setCornerFlags:corner_flags];
BubbleView* contentView =
base::mac::ObjCCast<BubbleView>([window_ contentView]);
[contentView setCornerFlags:corner_flags];
[window_ setFrame:window_frame display:YES];
}
......@@ -713,10 +716,11 @@ void StatusBubbleMac::ExpandBubble() {
// Get the current corner flags and see what needs to change based on the
// expansion.
unsigned long corner_flags = [[window_ contentView] cornerFlags];
BubbleView* contentView =
base::mac::ObjCCast<BubbleView>([window_ contentView]);
unsigned long corner_flags = [contentView cornerFlags];
corner_flags |= OSDependentCornerFlags(actual_window_frame);
[[window_ contentView] setCornerFlags:corner_flags];
[contentView setCornerFlags:corner_flags];
[NSAnimationContext beginGrouping];
[[NSAnimationContext currentContext] setDuration:kExpansionDurationSeconds];
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment