xref: /haiku/headers/private/bluetooth/PincodeWindow.h (revision 97dfeb96704e5dbc5bec32ad7b21379d0125e031)
1 /*
2  * Copyright 2007-2008 Oliver Ruiz Dorantes, oliver.ruiz.dorantes_at_gmail.com
3  * All rights reserved.	Distributed	under the terms	of the MIT License.
4  */
5 #ifndef	_PINCODE_REQUEST_WINDOW_H
6 #define	_PINCODE_REQUEST_WINDOW_H
7 
8 
9 #include <View.h>
10 #include <Window.h>
11 
12 #include <bluetooth/bluetooth.h>
13 #include <bluetooth/HCI/btHCI.h>
14 
15 class BStringView;
16 class BButton;
17 class BTextControl;
18 
19 namespace Bluetooth	{
20 
21 class RemoteDevice;
22 
23 class PincodeWindow : public BWindow
24 {
25 public:
26 							PincodeWindow(bdaddr_t address, hci_id hid);
27 							PincodeWindow(RemoteDevice* rDevice);
28 	virtual void			MessageReceived(BMessage *msg);
29 	virtual bool			QuitRequested();
30 			void			SetBDaddr(BString address);
31 
32 private:
33 			void			InitUI();
34 			bdaddr_t		fBdaddr;
35 			hci_id			fHid;
36 
37 			BStringView*	fMessage;
38 			BStringView*	fRemoteInfo;
39 			BButton*		fAcceptButton;
40 			BButton*		fCancelButton;
41 			BTextControl*	fPincodeText;
42 };
43 
44 }
45 
46 #ifndef	_BT_USE_EXPLICIT_NAMESPACE
47 using Bluetooth::PincodeWindow;
48 #endif
49 
50 #endif
51