Add an information blurb option to PromptWindow.

- PromptWindow now takes a parameter which contains optional
  informational text to display above the text control.

- Adjust callers.
This commit is contained in:
Rene Gollent
2013-04-27 14:04:33 -04:00
parent 31bc74d4bf
commit aa366c07b1
3 changed files with 16 additions and 6 deletions
+6 -3
View File
@@ -1,5 +1,5 @@
/*
* Copyright 2012, Rene Gollent, [email protected].
* Copyright 2012-2013, Rene Gollent, [email protected].
* Distributed under the terms of the MIT License.
*/
#ifndef PROMPT_WINDOW_H_
@@ -10,6 +10,7 @@
#include <Window.h>
class BStringView;
class BTextControl;
@@ -17,8 +18,9 @@ class PromptWindow : public BWindow
{
public:
// PromptWindow takes ownership of message
PromptWindow(const char* title, const char* label, BMessenger target,
BMessage* message = NULL);
PromptWindow(const char* title,
const char* label, const char* info,
BMessenger target, BMessage* message = NULL);
~PromptWindow();
virtual void MessageReceived(BMessage* message);
@@ -27,6 +29,7 @@ public:
status_t SetMessage(BMessage* message);
private:
BTextControl* fTextControl;
BStringView* fInfoView;
BMessenger fTarget;
BMessage* fMessage;
};