Opened 7 years ago

Last modified 4 days ago

#9979 assigned enhancement

[ProcessController] kill dialog is not in the center of a screen

Reported by: diver Owned by: nobody
Priority: normal Milestone: R1.1
Component: Kits/Interface Kit Version: R1/Development
Keywords: Cc:
Blocked By: Blocking:
Platform: All


if i remember correctly it used to be in the center before. Might be related to hrev45681.

Change History (4)

comment:1 by anevilyak, 7 years ago

Type: bugenhancement

The way it's positioned now is normal behavior for BAlert, it tries to position itself slightly offset from the window that spawned it, as best as allowed by proximity to the borders of the desktop. The above referenced commit doesn't change that, though it does change the size of the window slightly. In any case, PC didn't explicitly try to position itself either before or after said revision.

comment:2 by anevilyak, 5 years ago

Owner: changed from anevilyak to nobody
Status: newassigned

comment:3 by pulkomandy, 2 months ago

Component: Applications/ProcessControllerKits/Interface Kit

ProcessController can't really decide where the alert is shown, because its size is computed only in BAlert::Go() which also shows it. So, calling CenterOnScren results in the alert having its top-left corner on the center of the screen.

BAlert::_Prepare detects that the alert has a set position and does not change it. But there is no way to compute the correct position before _Prepare is called.

There is also no way to specify which window is the parent. It just uses the current thread and tests if that's a window (otherwise it does center itself on screen instead).

So, it looks like some API improvement to BAlert could be needed here.

comment:4 by pulkomandy, 4 days ago

Milestone: R1R1.1
Note: See TracTickets for help on using tickets.