Beispiel #1
0
        public CampanasPage()
        {
            InitializeComponent();

            _campanaService           = new CampanaService();
            listCampana.ItemSelected += ListView_ItemSelected;
            //listCampana.ItemsSource = GetTest();
        }
Beispiel #2
0
        public ComentarioPage(Campana campana)
        {
            InitializeComponent();

            _camapanaService = new CampanaService();
            this.campana     = campana;


            editorDescription.TextChanged += EditorDescription_TextChanged;

            tapComentar         = new TapGestureRecognizer();
            tapComentar.Tapped += TapComentar_Tapped;

            stkComentar.GestureRecognizers.Add(tapComentar);
            Loading(false);
        }
        public DetalleCampanaPage(Campana campana)
        {
            InitializeComponent();

            this.campana = campana;

            _campanaService = new CampanaService();

            lblLike.Text        = "Likes: " + campana.likes.ToString();
            lblComentario.Text  = "Comentarios: " + campana.cantidad_comentarios.ToString();
            lblDescripcion.Text = campana.descripcion;
            imgPrincipal.Source = campana.foto_url;

            tapLike         = new TapGestureRecognizer();
            tapLike.Tapped += TapLike_Tapped;

            imgLike.GestureRecognizers.Add(tapLike);

            tapPdf         = new TapGestureRecognizer();
            tapPdf.Tapped += async(object sender, EventArgs e) => {
                await Navigation.PushAsync(new PdfViewPage(campana.pdf_url));
            };

            imgPdf.GestureRecognizers.Add(tapPdf);


            if (String.IsNullOrEmpty(GeneralSetting.UserSettings))
            {
                stkComentar.IsVisible = false;
            }
            else
            {
                stkComentar.IsVisible = true;
            }



            tapComentar         = new TapGestureRecognizer();
            tapComentar.Tapped += async(object sender, EventArgs e) => { await Navigation.PushAsync(new ComentarioPage(campana)); };

            stkComentar.GestureRecognizers.Add(tapComentar);

            Loading(false);
        }