From 8323a7cd494b7e0b19df5c0bc822bc1130a9937b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Stephan=20A=C3=9Fmus?= Date: Sun, 3 May 2009 17:53:37 +0000 Subject: [PATCH] Tweak the "install done" message. If Deskbar is running, chances are quitting the Installer won't restart the computer. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@30613 a95241bf-73f2-0310-859d-f6bbb57e9c96 --- src/apps/installer/InstallerWindow.cpp | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) diff --git a/src/apps/installer/InstallerWindow.cpp b/src/apps/installer/InstallerWindow.cpp index ea86b07e20..1f9dd56a05 100644 --- a/src/apps/installer/InstallerWindow.cpp +++ b/src/apps/installer/InstallerWindow.cpp @@ -415,13 +415,6 @@ InstallerWindow::MessageReceived(BMessage *msg) case kInstalling: { _QuitCopyEngine(true); -// if (fWorkerThread->Cancel()) { -// fInstallStatus = kCancelled; -// _SetStatusMessage("Installation cancelled."); -// fProgressLayoutItem->SetVisible(false); -// fPkgSwitchLayoutItem->SetVisible(true); -// _ShowOptionalPackages(); -// } break; } case kFinished: @@ -494,11 +487,18 @@ InstallerWindow::MessageReceived(BMessage *msg) PartitionMenuItem* dstItem = (PartitionMenuItem*)fDestMenu->FindMarked(); + + const char* quitString; + if (be_roster->IsRunning(kDeskbarSignature)) + quitString = "leave the Installer"; + else + quitString = "restart the computer"; + char status[1024]; snprintf(status, sizeof(status), "Installation completed. " - "Boot sector has been written to '%s'. Press Quit to reboot " + "Boot sector has been written to '%s'. Press Quit to %s " "or chose a new target volume to perform another " - "installation.", dstItem ? dstItem->Name() : "???"); + "installation.", dstItem ? dstItem->Name() : "???", quitString); _SetStatusMessage(status); fInstallStatus = kFinished; _DisableInterface(false);