xref: /haiku/src/apps/terminal/FindWindow.h (revision 16d5c24e533eb14b7b8a99ee9f3ec9ba66335b1e)
1 /*
2  * Copyright 2007, Haiku, Inc.
3  * Copyright 2003-2004 Kian Duffy, myob@users.sourceforge.net
4  * Parts Copyright 1998-1999 Kazuho Okui and Takashi Murai.
5  * All rights reserved. Distributed under the terms of the MIT license.
6  */
7 #ifndef FINDDLG_H_INCLUDED
8 #define FINDDLG_H_INCLUDED
9 
10 
11 #include <Messenger.h>
12 #include <Window.h>
13 
14 
15 const ulong MSG_FIND = 'msgf';
16 const ulong MSG_FIND_START = 'msac';
17 const ulong MSG_FIND_CLOSED = 'mfcl';
18 
19 class BTextControl;
20 class BRadioButton;
21 class BBox;
22 class BCheckBox;
23 
24 class FindWindow : public BWindow {
25 	public:
26 		FindWindow (BRect frame, BMessenger messenger, BString &str,
27 			bool findSelection, bool matchWord, bool matchCase, bool forwardSearch);
28 		virtual ~FindWindow();
29 
30 		virtual void Quit();
31 		virtual void MessageReceived(BMessage *msg);
32 
33 	private:
34 		void _SendFindMessage();
35 
36 	private:
37 		BView 			*fFindView;
38 		BTextControl 	*fFindLabel;
39 		BRadioButton 	*fTextRadio;
40 		BRadioButton 	*fSelectionRadio;
41 		BBox 			*fSeparator;
42 		BCheckBox		*fForwardSearchBox;
43 		BCheckBox		*fMatchCaseBox;
44 		BCheckBox		*fMatchWordBox;
45 		BButton			*fFindButton;
46 
47 		BString	*fFindString;
48 		BMessenger fFindDlgMessenger;
49 };
50 
51 #endif	// FINDDLG_H_INCLUDED
52