xref: /haiku/src/apps/networkstatus/WirelessNetworkMenuItem.h (revision 820dca4df6c7bf955c46e8f6521b9408f50b2900)
1 /*
2  * Copyright 2010, Axel Dörfler, axeld@pinc-software.de.
3  * Distributed under the terms of the MIT License.
4  */
5 #ifndef WIRELESS_NETWORK_MENU_ITEM_H
6 #define WIRELESS_NETWORK_MENU_ITEM_H
7 
8 
9 #include <MenuItem.h>
10 
11 
12 class WirelessNetworkMenuItem : public BMenuItem {
13 public:
14 								WirelessNetworkMenuItem(const char* name,
15 									int32 signalQuality, bool encrypted,
16 									BMessage* message);
17 	virtual						~WirelessNetworkMenuItem();
18 
19 			void				SetSignalQuality(int32 quality);
20 			int32				SignalQuality() const
21 									{ return fQuality; }
22 			bool				IsEncrypted() const
23 									{ return fIsEncrypted; }
24 
25 protected:
26 	virtual	void				DrawContent();
27 	virtual	void				Highlight(bool isHighlighted);
28 	virtual	void				GetContentSize(float* width, float* height);
29 			void				DrawRadioIcon();
30 
31 private:
32 			int32				fQuality;
33 			bool				fIsEncrypted;
34 };
35 
36 
37 #endif	// WIRELESS_NETWORK_MENU_ITEM_H
38