From 9d9ef27273743328dbe140e364cfe1bfd698f981 Mon Sep 17 00:00:00 2001 From: Matthew Wilber Date: Sat, 29 Jan 2005 19:12:01 +0000 Subject: [PATCH] Changed buttons and TextView back to being children of the MasterView so that the Archive() BMessage matches Be's version. Changed when MasterView is added as child of the Alert window to fix the "out-of-alignment" issue. git-svn-id: file:///srv/svn/repos/haiku/trunk/current@11134 a95241bf-73f2-0310-859d-f6bbb57e9c96 --- src/kits/interface/Alert.cpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/kits/interface/Alert.cpp b/src/kits/interface/Alert.cpp index bbd803a785..91ec8293c6 100644 --- a/src/kits/interface/Alert.cpp +++ b/src/kits/interface/Alert.cpp @@ -470,6 +470,7 @@ void BAlert::InitObject(const char* text, const char* button0, // Set up the "_master_" view TAlertView* MasterView = new TAlertView(Bounds()); + AddChild(MasterView); MasterView->SetBitmap(InitIcon()); // Set up the buttons @@ -522,7 +523,7 @@ void BAlert::InitObject(const char* text, const char* button0, // in AttachedToWindow() for (int i = 0; i < buttonCount; ++i) { - AddChild(fButtons[i]); + MasterView->AddChild(fButtons[i]); } for (int i = buttonCount - 1; i >= 0; --i) @@ -617,8 +618,7 @@ void BAlert::InitObject(const char* text, const char* button0, fTextView = new BTextView(TextViewRect, "_tv_", TextViewRect, B_FOLLOW_LEFT | B_FOLLOW_TOP, B_WILL_DRAW); - AddChild(MasterView); - AddChild(fTextView); + MasterView->AddChild(fTextView); fTextView->SetViewColor(ui_color(B_PANEL_BACKGROUND_COLOR)); fTextView->SetText(text, strlen(text));