using System; using System.Collections.Generic; using System.Text; using Shared; using Shared.Net; using Shared.SimpleControl; using Shared.SimpleControl.Phone.Music; using Shared.SimpleControl.R; namespace SmartHome { public class A31AddListMuisc : FrameLayout { bool isExited; public void Show (string listname, List musicInfoList) { AddChidren (new Button { Height = Application.GetRealHeight (36), BackgroundColor = SkinStyle.Current.MusicTopFrameLayout, }); var topFrameLayout = new FrameLayout { Height = Application.GetRealHeight (100), BackgroundColor = SkinStyle.Current.MusicTopFrameLayout, Y = Application.GetRealHeight (36), }; AddChidren (topFrameLayout); var LocallistName = new Button { Text = listname, TextColor=SkinStyle.Current.MusicTextColor, }; topFrameLayout.AddChidren (LocallistName); var hdl = new Button { Width = Application.GetRealWidth (154), Height = Application.GetRealHeight (90), X = Application.GetRealWidth (486), Gravity = Gravity.CenterVertical, UnSelectedImagePath = MainPage.LogoString, }; topFrameLayout.AddChidren (hdl); var back = new Button { Width = Application.GetRealWidth (82), Height = Application.GetRealHeight (89), X = Application.GetRealWidth (10), Gravity = Gravity.CenterVertical, UnSelectedImagePath = "MusicIcon/HomepageBack.png", }; topFrameLayout.AddChidren (back); back.MouseDownEventHandler += (sender, e) => { RemoveFromParent (); isExited = true; }; var fra = new FrameLayout { Y = topFrameLayout.Bottom, Height = Application.GetRealHeight (Application.DesignHeight - 100 - 36), BackgroundColor = SkinStyle.Current.MusicVerticalScrolViewLayout, }; AddChidren (fra); var middle = new VerticalScrolViewLayout (); fra.AddChidren (middle); if (musicInfoList == null) { return; } List