コード例 #1
0
        public override void ViewWillAppear(bool animated)
        {
            this.Divider.Image = UIImage.FromFile ("./Assets/divider.png");
            var button = new UIBarButtonItem ("Back", UIBarButtonItemStyle.Plain, null);
            var custom = new UIButton (new RectangleF (0, 0, 26, 15));
            custom.SetBackgroundImage(UIImage.FromFile("./Assets/back.png"), UIControlState.Normal);
            custom.TouchUpInside += (sender, e) => NavigationController.PopViewControllerAnimated (true);
            button.CustomView = custom;

            var languages = new PreferenceModel[] {
                new PreferenceModel() { Title = "English", HasChild = false, Selected = false },
                new PreferenceModel() { Title = "Български", HasChild = true, Selected = false },
                new PreferenceModel() { Title = "Русский", HasChild = false, Selected = false },
            };
            this.TableView.Source = new ContentLanguageControllerSource (languages);
            this.TableView.BackgroundColor=  UIColor.FromRGB (26, 26, 26);

            this.NavigationItem.LeftBarButtonItem = button;
            this.NavigationController.SetNavigationBarHidden (false, false);
        }
コード例 #2
0
 public ContentLanguageControllerSource(PreferenceModel[] items)
 {
     this.items = items;
 }