vfs: check userland buffers before reading them.
[haiku.git] / src / apps / debugger / user_interface / gui / value / TableCellTextControlEditor.h
blob9db2a6b580ab2e91b8bdeb66a7d7d7eacd8e6cd9
1 /*
2 * Copyright 2015, Rene Gollent, rene@gollent.com.
3 * Distributed under the terms of the MIT License.
4 */
5 #ifndef TABLE_CELL_TEXT_CONTROL_EDITOR_H
6 #define TABLE_CELL_TEXT_CONTROL_EDITOR_H
8 #include <TextControl.h>
10 #include "TableCellFormattedValueEditor.h"
13 // common base class for editors that input a value via a text field
14 class TableCellTextControlEditor : public TableCellFormattedValueEditor,
15 public BTextControl {
16 public:
17 TableCellTextControlEditor(
18 ::Value* initialValue,
19 ValueFormatter* formatter);
20 virtual ~TableCellTextControlEditor();
22 status_t Init();
24 virtual BView* GetView();
26 virtual bool ValidateInput() const = 0;
28 virtual status_t GetValueForInput(::Value*& _output) const = 0;
29 // returns reference
31 virtual void AttachedToWindow();
32 virtual void MessageReceived(BMessage* message);
35 #endif // TABLE_CELL_TEXT_CONTROL_EDITOR_H