Skip to content

Commit

Permalink
8296654: [macos] Crash when launching JavaFX app with JDK that target…
Browse files Browse the repository at this point in the history
…s SDK 13

Reviewed-by: kcr
Backport-of: 5b96d34
  • Loading branch information
Johan Vos committed Jan 19, 2023
1 parent 06e167a commit 795ed10
Showing 1 changed file with 9 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -263,7 +263,9 @@ - (void)setFrameSize:(NSSize)newSize
(*env)->CallVoidMethod(env, self->jView, jViewNotifyResize, (int)newSize.width, (int)newSize.height);
GLASS_CHECK_EXCEPTION(env);

[self->nsView removeTrackingRect:self->trackingRect];
if (self->trackingRect) {
[self->nsView removeTrackingRect:self->trackingRect];
}
self->trackingRect = [self->nsView addTrackingRect:[self->nsView bounds] owner:self->nsView userData:nil assumeInside:NO];
}

Expand All @@ -277,13 +279,17 @@ - (void)setFrame:(NSRect)frameRect
(*env)->CallVoidMethod(env, self->jView, jViewNotifyResize, (int)frameRect.size.width, (int)frameRect.size.height);
GLASS_CHECK_EXCEPTION(env);

[self->nsView removeTrackingRect:self->trackingRect];
if (self->trackingRect) {
[self->nsView removeTrackingRect:self->trackingRect];
}
self->trackingRect = [self->nsView addTrackingRect:[self->nsView bounds] owner:self->nsView userData:nil assumeInside:NO];
}

- (void)updateTrackingAreas
{
[self->nsView removeTrackingRect:self->trackingRect];
if (self->trackingRect) {
[self->nsView removeTrackingRect:self->trackingRect];
}
self->trackingRect = [self->nsView addTrackingRect:[self->nsView bounds] owner:self->nsView userData:nil assumeInside:NO];
}

Expand Down

1 comment on commit 795ed10

@openjdk-notifier
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please sign in to comment.