1 /* 2 * Copyright 2008-2009, Oliver Ruiz Dorantes, <oliver.ruiz.dorantes@gmail.com> 3 * Copyright 2012-2013, Tri-Edge AI, <triedgeai@gmail.com> 4 * 5 * All rights reserved. Distributed under the terms of the MIT License. 6 */ 7 8 #ifndef BLUETOOTH_SETTINGS_VIEW_H 9 #define BLUETOOTH_SETTINGS_VIEW_H 10 11 #include "BluetoothSettings.h" 12 13 #include <View.h> 14 15 class BluetoothSettings; 16 class ExtendedLocalDeviceView; 17 class LocalDevice; 18 19 class BBox; 20 class BMenuField; 21 class BPopUpMenu; 22 class BSlider; 23 24 class BluetoothSettingsView : public BView { 25 public: 26 BluetoothSettingsView(const char* name); 27 virtual ~BluetoothSettingsView(); 28 29 virtual void AttachedToWindow(); 30 virtual void MessageReceived(BMessage* message); 31 32 33 private: 34 void _BuildConnectionPolicy(); 35 void _BuildClassMenu(); 36 void _BuildLocalDevicesMenu(); 37 bool _SetDeviceClass(uint8 major, uint8 minor, 38 uint16 service); 39 void _MarkLocalDevice(LocalDevice* lDevice); 40 41 protected: 42 BluetoothSettings fSettings; 43 44 float fDivider; 45 46 BMenuField* fPolicyMenuField; 47 BPopUpMenu* fPolicyMenu; 48 BMenuField* fClassMenuField; 49 BPopUpMenu* fClassMenu; 50 BMenuField* fLocalDevicesMenuField; 51 BPopUpMenu* fLocalDevicesMenu; 52 53 ExtendedLocalDeviceView* fExtDeviceView; 54 55 BSlider* fInquiryTimeControl; 56 57 }; 58 59 #endif // BLUETOOTH_SETTINGS_VIEW_H 60