[prev in list] [next in list] [prev in thread] [next in thread] 

List:       openjdk-openjfx-dev
Subject:    Re: RFR: 8251862: Wrong position of Popup windows at the intersection of 2 screens [v2]
From:       Kevin Rushforth <kcr () openjdk ! org>
Date:       2022-12-23 14:46:25
Message-ID: HCQUYj1RCrVJUM6932iKXmRldCy7LX4fG9bCywibMa8=.cc1e280f-b761-4ef2-bb22-a9177d67d3e4 () github ! com
[Download RAW message or body]

> On Windows platforms with more than one screen, a PopupWindow created for a Stage \
> that straddles two windows will be drawn with an incorrect position and screen \
> scale if the majority of the Stage is on one screen, and the popup is positioned on \
> the other screen. In this case, the Stage is drawn using the screen scale of the \
> screen that most of the window is on, while the popup is drawn using the scale of \
> the screen that it is (typically entirely) on. 
> The most common way this can happen is when you have two screens of a different \
> scale with the secondary screen on the left or above the primary screen. If you \
> position the Stage such that most of it is still on the primary screen (thus the \
> Stage is drawn using the scale of the primary screen), with a menu, a control with \
> a context menu, or a control with a Tooltip now on the secondary screen, the popup \
> window for the menu or Tooltip will be drawn using the screen scale of the \
> secondary window and thus won't be positioned or sized correctly relative to the \
> menu bar, or control in the main window. 
> The fix implemented by this PR is to always use the screen of the owner window, \
> including the screen scales, when rendering a popup window. This matches the \
> behavior of native Windows apps, such as Notepad.

Kevin Rushforth has updated the pull request with a new target base due to a merge or \
a rebase. The incremental webrev excludes the unrelated changes brought in by the \
merge/rebase. The pull request contains two additional commits since the last \
revision:

 - Merge remote-tracking branch 'origin/master' into 8251862-multi-screen-popup
 - 8251862: Wrong position of Popup windows at the intersection of 2 screens

-------------

Changes:
  - all: https://git.openjdk.org/jfx/pull/971/files
  - new: https://git.openjdk.org/jfx/pull/971/files/9000728d..b693b871

Webrevs:
 - full: https://webrevs.openjdk.org/?repo=jfx&pr=971&range=01
 - incr: https://webrevs.openjdk.org/?repo=jfx&pr=971&range=00-01

  Stats: 15298 lines in 1252 files changed: 7602 ins; 1496 del; 6200 mod
  Patch: https://git.openjdk.org/jfx/pull/971.diff
  Fetch: git fetch https://git.openjdk.org/jfx pull/971/head:pull/971

PR: https://git.openjdk.org/jfx/pull/971


[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic