Esempio n. 1
0
        public void RenderRssStream(Stream stream)
        {
            var doc   = XDocument.Load(new XmlTextReader(stream));
            var items = doc.XPathSelectElements("./rss/channel/item/title");

            //
            // Since this is invoked on a separated thread, make sure that
            // we call UIKit only from the main thread.
            //
            InvokeOnMainThread(delegate {
                var table = new UITableViewController();
                navigationController.PushViewController(table, true);

                // Put the data on a string [] so we can use our existing
                // UITableView renderer for strings.
                string [] entries = new string [items.Count()];
                int i             = 0;
                foreach (var e in items)
                {
                    entries [i++] = e.Value;
                }

                TableViewSelector.Configure(table.View as UITableView, entries);
            });
        }
Esempio n. 2
0
        // This method is invoked when the application has loaded its UI and its ready to run
        public override bool FinishedLaunching(UIApplication app, NSDictionary options)
        {
            window.AddSubview(navigationController.View);

            button1.TouchDown += Button1TouchDown;
            TableViewSelector.Configure(this.stack, new string [] {
                "WebRequest",
                "HttpClient/CFNetwork",
                "HttpClient/AFNetworking"
            });

            window.MakeKeyAndVisible();

            return(true);
        }
Esempio n. 3
0
        // This method is invoked when the application has loaded its UI and its ready to run
        public override bool FinishedLaunching(UIApplication application, NSDictionary launchOptions)
        {
            window.RootViewController = navigationController;

            button1.TouchDown += Button1TouchDown;
            TableViewSelector.Configure(stack, new [] {
                "http  - WebRequest",
                "https - WebRequest",
                "http  - NSUrlConnection",
                "http  - HttpClient/CFNetwork"
            });

            window.MakeKeyAndVisible();

            return(true);
        }
Esempio n. 4
0
        // This method is invoked when the application has loaded its UI and its ready to run
        public override bool FinishedLaunching(UIApplication app, NSDictionary options)
        {
            // window.AddSubview (navigationController.View);

            button1.TouchDown += Button1TouchDown;
            TableViewSelector.Configure(this.stack, new string [] {
                "WebRequest",
                "HttpClient/CFNetwork",
                "HttpClient/NSURLSession"
            });

            // window = new UIWindow (UIScreen.MainScreen.Bounds);
            window.RootViewController = navigationController;

            window.MakeKeyAndVisible();

            return(true);
        }
Esempio n. 5
0
        // This method is invoked when the application has loaded its UI and its ready to run
        public override bool FinishedLaunching(UIApplication app, NSDictionary options)
        {
            //window.AddSubview (navigationController.View);

            button1.TouchDown += Button1TouchDown;
            TableViewSelector.Configure(this.stack, new string [] {
                "http  - WebRequest",
                "https - WebRequest",
                "http  - HttpClient",
                "https  - HttpClient"

                //"http  - NSUrlConnection",
            });

            window.RootViewController = navigationController;

            window.MakeKeyAndVisible();

            return(true);
        }