1/*
2 * Copyright 2006 Haiku, Inc. All Rights Reserved.
3 * Distributed under the terms of the MIT License.
4 *
5 * Authors:
6 *		Stephan A��mus, superstippi@gmx.de
7 */
8#ifndef INPUT_TEXT_VIEW_H
9#define INPUT_TEXT_VIEW_H
10
11
12#include <Invoker.h>
13#include <TextView.h>
14
15
16class InputTextView : public BTextView, public BInvoker {
17 public:
18								InputTextView(BRect frame,
19									const char* name,
20									BRect textRect,
21									uint32 resizingMode,
22									uint32 flags);
23	virtual						~InputTextView();
24
25	// BTextView interface
26	virtual	void				MouseDown(BPoint where);
27	virtual	void				MouseUp(BPoint where);
28
29	virtual	void				KeyDown(const char* bytes, int32 numBytes);
30	virtual	void				MakeFocus(bool focus);
31
32	// BInvoker interface
33	virtual	status_t			Invoke(BMessage* message = NULL);
34
35	// InputTextView
36	virtual	void				RevertChanges() = 0;
37	virtual	void				ApplyChanges() = 0;
38
39 protected:
40			bool				fWasFocus;
41};
42
43#endif // INPUT_TEXT_VIEW_H
44