Пример #1
0
        void addComments()
        {
            _commentScroll = new CommentsScrollView(new CGRect(0, 346, 320, 167));
            CenterView.Add(_commentScroll);
            var vm = ViewModel as MainViewModel;

            if (vm.PostsList != null)
            {
                _commentScroll.PostsList = vm.PostsList;
            }
            vm.PropertyChanged += (sender, e) => {
                if (e.PropertyName == "PostsList")
                {
                    _commentScroll.PostsList = vm.PostsList;
                }
            };
        }
Пример #2
0
        void addUsersScroll()
        {
            _userscrollview = new UsersScrollView(new CGRect(0, 246, 320, 100));
            CenterView.Add(_userscrollview);

            var vm = ViewModel as MainViewModel;

            if (vm.UsersList != null)
            {
                _userscrollview.UsersList = vm.UsersList;
            }
            vm.PropertyChanged += (sender, e) => {
                if (e.PropertyName == "UsersList")
                {
                    _userscrollview.UsersList = vm.UsersList;
                }
            };
        }
Пример #3
0
        private void initInputComment()
        {
            NewCommentView = new UIView(new CGRect(0, 513, 320, 45));
            CenterView.Add(NewCommentView);

            var img = new UIImageView(new CGRect(20, 12, 22, 22))
            {
                ContentMode = UIViewContentMode.ScaleToFill
            };

            img.Image = UIImage.FromFile("MLResources/IconsMuro/icon_enter.png");
            NewCommentView.Add(img);

            inputComment = new UITextField(new CGRect(50, 14, 250, 18))
            {
                Placeholder = "Comment"
            };
            inputComment.Font      = UIFont.FromName(fontname, 11);
            inputComment.TextColor = UIColor.White;
            NewCommentView.Add(inputComment);
        }
Пример #4
0
        private void initCenter()
        {
            los_scroll           = new LOsScrollView(new CGRect(0, 48, 320, 198));
            los_scroll.DoOpenLO += (sender, lo_index) => {
                var vm1 = ViewModel as MainViewModel;


                vm1.OpenLOCommand.Execute(vm1.LearningOjectsList[0]);
                LoadingView = new LoadingOverlay(new CGRect(0, 0, 320, 568));
                View.Add(LoadingView);
            };
            CenterView.Add(los_scroll);

            var vm = ViewModel as MainViewModel;

            if (vm.LearningOjectsList != null)
            {
                los_scroll.LearningOjectsList = vm.LearningOjectsList;
            }
            vm.PropertyChanged += (sender, e) => {
                los_scroll.LearningOjectsList = vm.LearningOjectsList;
            };
        }