[haiku-commits] haiku: hrev53564 - src/servers/debug

  • From: Stephan Aßmus <superstippi@xxxxxx>
  • To: haiku-commits@xxxxxxxxxxxxx
  • Date: Fri, 25 Oct 2019 03:26:55 -0400 (EDT)

hrev53564 adds 1 changeset to branch 'master'
old head: caf05af5dd9364af5fc808921f8b0c3a43736aaf
new head: 09250fd50f602a13c2d7b991174f6eafab6ea55f
overview: 
https://git.haiku-os.org/haiku/log/?qt=range&q=09250fd50f60+%5Ecaf05af5dd93

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

09250fd50f60: debug_server: Be a bit more enthusiastic
  
  * Improved the "Oh no!" text of the button.
  
  Change-Id: I9b15f3dccca24a5e394d42890985fd42c49f7587
  Reviewed-on: https://review.haiku-os.org/c/haiku/+/1925
  Reviewed-by: Adrien Destugues <pulkomandy@xxxxxxxxx>
  Reviewed-by: Stephan Aßmus <superstippi@xxxxxx>

                                   [ Axel Dörfler <axeld@xxxxxxxxxxxxxxxx> ]

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

Revision:    hrev53564
Commit:      09250fd50f602a13c2d7b991174f6eafab6ea55f
URL:         https://git.haiku-os.org/haiku/commit/?id=09250fd50f60
Author:      Axel Dörfler <axeld@xxxxxxxxxxxxxxxx>
Date:        Thu Oct 24 21:24:36 2019 UTC
Committer:   Stephan Aßmus <superstippi@xxxxxx>
Commit-Date: Fri Oct 25 07:26:50 2019 UTC

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

2 files changed, 7 insertions(+), 3 deletions(-)
src/servers/debug/DebugWindow.cpp | 7 +++++--
src/servers/debug/DebugWindow.h   | 3 ++-

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

diff --git a/src/servers/debug/DebugWindow.cpp 
b/src/servers/debug/DebugWindow.cpp
index 0dd295f3d6..ed369a04f6 100644
--- a/src/servers/debug/DebugWindow.cpp
+++ b/src/servers/debug/DebugWindow.cpp
@@ -3,6 +3,7 @@
  * Distributed under the terms of the MIT License.
  */
 
+
 #include "DebugWindow.h"
 
 #include <algorithm>
@@ -70,7 +71,7 @@ DebugWindow::DebugWindow(const char* appName)
        BRadioButton *core = new BRadioButton("core",
                B_TRANSLATE("Write core file"), new 
BMessage(kActionWriteCoreFile));
 
-       BButton *close = new BButton("close", B_TRANSLATE("Oh no!"),
+       fOKButton = new BButton("close", B_TRANSLATE("Oh no!"),
                new BMessage(B_QUIT_REQUESTED));
 
        terminate->SetValue(B_CONTROL_ON);
@@ -89,7 +90,7 @@ DebugWindow::DebugWindow(const char* appName)
                                .End()
                                .AddGroup(B_HORIZONTAL)
                                        .AddGlue()
-                                       .Add(close)
+                                       .Add(fOKButton)
                                .End()
                        .End()
                .End();
@@ -118,6 +119,8 @@ DebugWindow::MessageReceived(BMessage* message)
                case kActionWriteCoreFile:
                case kActionSaveReportTeam:
                        fAction = message->what;
+                       fOKButton->SetLabel(fAction == kActionDebugTeam
+                               ? B_TRANSLATE("Oh yeah!") : B_TRANSLATE("Oh 
no!"));
                        return;
        }
 
diff --git a/src/servers/debug/DebugWindow.h b/src/servers/debug/DebugWindow.h
index 9a4fc40b5b..a3418c109d 100644
--- a/src/servers/debug/DebugWindow.h
+++ b/src/servers/debug/DebugWindow.h
@@ -2,7 +2,6 @@
  * Copyright 2019, Adrien Destugues, pulkomandy@xxxxxxxxxxxxx.
  * Distributed under the terms of the MIT License.
  */
-
 #ifndef DEBUGWINDOW_H
 #define DEBUGWINDOW_H
 
@@ -33,11 +32,13 @@ public:
 
        void                    MessageReceived(BMessage* message);
        int32                   Go();
+
 private:
        static  BRect   IconSize();
 
 private:
        BBitmap                 fBitmap;
+       BButton*                fOKButton;
        sem_id                  fSemaphore;
        int32                   fAction;
 };


Other related posts:

  • » [haiku-commits] haiku: hrev53564 - src/servers/debug - Stephan Aßmus