* Fixed wrong resizing mode.
* Fixed center on screen algorithm for multi-screen scenarios. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@17859 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
@@ -134,7 +134,7 @@ SettingsWindow::SettingsWindow()
|
|||||||
BString string = "Physical Memory: ";
|
BString string = "Physical Memory: ";
|
||||||
string << byte_string((off_t)info.max_pages * B_PAGE_SIZE);
|
string << byte_string((off_t)info.max_pages * B_PAGE_SIZE);
|
||||||
BStringView* stringView = new BStringView(rect, "physical memory", string.String(),
|
BStringView* stringView = new BStringView(rect, "physical memory", string.String(),
|
||||||
B_FOLLOW_ALL);
|
B_FOLLOW_NONE);
|
||||||
stringView->ResizeToPreferred();
|
stringView->ResizeToPreferred();
|
||||||
box->AddChild(stringView);
|
box->AddChild(stringView);
|
||||||
|
|
||||||
@@ -142,7 +142,7 @@ SettingsWindow::SettingsWindow()
|
|||||||
string = "Current Swap File Size: ";
|
string = "Current Swap File Size: ";
|
||||||
string << byte_string(fSettings.SwapSize());
|
string << byte_string(fSettings.SwapSize());
|
||||||
stringView = new BStringView(rect, "current swap size", string.String(),
|
stringView = new BStringView(rect, "current swap size", string.String(),
|
||||||
B_FOLLOW_ALL);
|
B_FOLLOW_NONE);
|
||||||
stringView->ResizeToPreferred();
|
stringView->ResizeToPreferred();
|
||||||
box->AddChild(stringView);
|
box->AddChild(stringView);
|
||||||
|
|
||||||
@@ -224,8 +224,8 @@ SettingsWindow::SettingsWindow()
|
|||||||
|
|
||||||
if (!screenFrame.Contains(fSettings.WindowPosition())) {
|
if (!screenFrame.Contains(fSettings.WindowPosition())) {
|
||||||
// move on screen, centered
|
// move on screen, centered
|
||||||
MoveTo((screenFrame.Width() - Bounds().Width()) / 2,
|
MoveTo(screenFrame.left + (screenFrame.Width() - Bounds().Width()) / 2,
|
||||||
(screenFrame.Height() - Bounds().Height()) / 2);
|
screenFrame.top + (screenFrame.Height() - Bounds().Height()) / 2);
|
||||||
} else
|
} else
|
||||||
MoveTo(fSettings.WindowPosition());
|
MoveTo(fSettings.WindowPosition());
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user