Esempio n. 1
0
        void doUgcs(List <XMLement> ugcs)
        {
            AppController.poiHit();


            XMLement raw = XMLement.createFromRawXml("<poi><name>VolksMond</name><description>Door andere gebruikers gemaakte media</description></poi>");
            XMLement mmd = new XMLement("media");

            foreach (XMLement x in ugcs)
            {
                mmd.addChild(x);
            }

            raw.addChild(mmd);

            AppController.sEventLog.WriteLine("hit {0} ugc:", ugcs.Count);
            AppController.sEventLog.WriteLine("\t", raw.toString());

            if (sUgcViewerPage == null)
            {
                sUgcViewerPage = new PoiViewerPage(this);
            }

            if (sUgcViewerPage.setContent(raw))
            {
                mIsActive = false;
                sUgcViewerPage.ShowDialog();
                mBlendTimer.Change(0, 3000);
            }
        }
Esempio n. 2
0
        bool offerPOI(string poiID)
        {
            XMLement x = AppController.sKwxClient.getPOI(poiID);

            if (x != null)
            {
                AppController.sEventLog.WriteLine("\tpoi: {0}", poiID);
                x = x.getChildByName("poi");

                if (x != null)
                {
                    mCurrentPOI = x;
                    XMLement name_xml = x.getChildByName("name");
                    if (name_xml != null)
                    {
                        AppController.sEventLog.WriteLine("\tname: {0}", name_xml.nodeText);
                        title = name_xml.nodeText;
                    }
                    XMLement desc_xml = x.getChildByName("description");
                    if (desc_xml != null)
                    {
                        AppController.sEventLog.WriteLine("\tdesc: {0}", desc_xml.nodeText);
                        mTextBox.Text = desc_xml.nodeText;
                    }
                    mTextBox.Visible = true;
                    mHasContent      = sPoiPage.setContent(x);
                    if (mHasContent)
                    {
                        setMenuText(0, "Toon Media");
                    }
                    else
                    {
                        setMenuText(0, "Geen Media");
                    }
                    return(true);
                }
            }
            return(false);
        }