| | |
| | | topFrameLayout.BackgroundColor = ZigbeeColor.Current.GXCGrayBackgroundColor;
|
| | | this.AddChidren(topFrameLayout);
|
| | | //标题分类
|
| | | var btnTitle = new NormalViewControl(300, 95, true);
|
| | | var btnTitle = new NormalViewControl(400, 95, true);
|
| | | btnTitle.X = ControlCommonResourse.XXLeft;
|
| | | btnTitle.Gravity = Gravity.CenterVertical;
|
| | | btnTitle.TextID = R.MyInternationalizationString.Category;
|
| | |
| | | frameDeviceBack.AddChidren(listDeviceView);
|
| | |
|
| | | //上一次选择的菜单
|
| | | MainPage.Controls.DeviceFunctionUnallocatedControl oldSelectContr = null;
|
| | | MainPage.Controls.DeviceFunctionMenuControl oldSelectContr = null;
|
| | | DeviceRowInfo nowSelectDeviceInfo = null;
|
| | | foreach (string strText in dicGroupDevice.Keys)
|
| | | {
|
| | |
| | | HorizontalView.AddChidren(devieFrame);
|
| | |
|
| | | //菜单图片控件
|
| | | var deviceObjContr = new MainPage.Controls.DeviceFunctionUnallocatedControl();
|
| | | var deviceObjContr = new MainPage.Controls.DeviceFunctionMenuControl();
|
| | | devieFrame.AddChidren(deviceObjContr);
|
| | | deviceObjContr.InitControl(strText, rowInfo.IconPath, rowInfo.IconPathSelected, rowInfo.listDeviceKeys);
|
| | | deviceObjContr.InitControl(strText, rowInfo.IconPath, rowInfo.IconPathSelected);
|
| | | deviceObjContr.ButtonClickEvent += (sender, e) =>
|
| | | {
|
| | | //选择的是同一个东西的话,不处理
|
| | |
| | | string path1 = string.Empty;
|
| | | string path2 = string.Empty;
|
| | | //获取图片
|
| | | LocalDevice.Current.GetDeviceFunctionTypeMenuIcon(typeInfo.ConcreteType, ref path1, ref path2);
|
| | | LocalDevice.Current.GetDeviceFunctionTypeMenuIcon(typeInfo, ref path1, ref path2);
|
| | | dic[typeInfo.BeloneText].IconPath = path1;
|
| | | dic[typeInfo.BeloneText].IconPathSelected = path2;
|
| | | dic[typeInfo.BeloneText].Text = typeInfo.BeloneText;
|