/// <summary> /// Инициализирует новый экземпляр класса с заданным идентификатором /// модели представления и идентификатором пользователя. /// </summary> public ProfileViewModel(string uniqueKey, ulong userID) : base(uniqueKey) { _userID = userID; _wall = new WallCollection((long)userID); NewPost = new RelayCommand(() => NavigationHelper.Navigate(AppViews.NewPostView, _userID)); NewMessage = new RelayCommand(() => NavigationHelper.Navigate(AppViews.ConversationView, (long)_userID)); }
void Start() { instance = this; float tmp=0; for (int i = 0; i <7; i++) { tmp += Random.Range(60, 90); GameObject upperWall = Instantiate(Wall); upperWall.transform.position = new Vector2(i * 55 + tmp, 2); upperWall.transform.localScale = new Vector3(upperWall.transform.localScale.x, Random.Range(minScaleY, maxScaleY)); wallListUpper.Add(upperWall); GameObject lowerWall = Instantiate(Wall); lowerWall.transform.position = new Vector2(i * 55 + tmp, 110); lowerWall.transform.localScale = new Vector3(upperWall.transform.localScale.x, Random.Range(minScaleY, maxScaleY)); wallListLower.Add(lowerWall); } }
/// <summary> /// Инициализирует новый экземпляр класса с заданным идентификатором /// модели представления и идентификатором сообщества. /// </summary> public GroupInfoViewModel(string uniqueKey, ulong groupID) : base(uniqueKey) { _groupID = groupID; _wall = new WallCollection(-(long)groupID); }