private void RefrescarVista() { if ( this.InvokeRequired ) { SinParametrosCallback callback = new SinParametrosCallback( this.RefrescarVista ); this.Invoke( callback ); } else { if ( this.controller.JuegoSeleccionado == null ) this.BlanquearTitulos(); else { this.lblTituloCentral.Text = this.controller.JuegoSeleccionado.Nombre; int indiceMenor = this.controller.IndiceJuegoSeleccionado - 1; for ( int i = this.titulosJuegosInferior.Count - 1; i >= 0; i-- ) { if ( indiceMenor < 0 ) this.titulosJuegosInferior[ i ].Text = string.Empty; else this.titulosJuegosInferior[ i ].Text = this.controller.Juegos[ indiceMenor ].Nombre; this.Refresh(); indiceMenor--; } int indiceMayor = this.controller.IndiceJuegoSeleccionado + 1; for ( int i = 0; i < this.titulosJuegosSuperior.Count; i++ ) { if ( indiceMayor > this.controller.Juegos.Count - 1 ) this.titulosJuegosSuperior[ i ].Text = string.Empty; else this.titulosJuegosSuperior[ i ].Text = this.controller.Juegos[ indiceMayor ].Nombre; this.Refresh(); indiceMayor++; } } } }
private void SwitchActivarBusqueda() { if ( this.InvokeRequired ) { SinParametrosCallback callback = new SinParametrosCallback( this.SwitchActivarBusqueda ); this.Invoke( callback ); } else { this.txtBusqueda.Visible = !this.txtBusqueda.Visible; if ( this.txtBusqueda.Visible ) { this.txtBusqueda.Focus(); this.txtBusqueda.Text = string.Empty; this.indiceLetraActual = 0; this.txtBusqueda.Text = this.caracteres[ this.indiceLetraActual ].ToString(); } else { this.controller.Filtro = string.Empty; this.RefrescarVista(); this.lblResultadoBusqueda.Visible = false; } } }
private void controller_Escape( object sender, EventArgs e ) { if ( this.InvokeRequired ) { SinParametrosCallback callback = new SinParametrosCallback( this.Cerrar ); this.Invoke( callback ); } else this.Cerrar(); }
private void controller_BuscarYAvanzar( object sender, EventArgs e ) { if ( this.InvokeRequired ) { SinParametrosCallback callback = new SinParametrosCallback( this.BuscadorBuscarYAvanzar ); this.Invoke( callback ); } else this.BuscadorBuscarYAvanzar(); }
private void controller_BuscadorSiguiente( object sender, EventArgs e ) { if ( this.InvokeRequired ) { SinParametrosCallback callback = new SinParametrosCallback( this.BuscadorSiguienteLetra ); this.Invoke( callback ); } else this.BuscadorSiguienteLetra(); }
private void SeleccionarPlataforma() { if ( this.InvokeRequired ) { SinParametrosCallback callback = new SinParametrosCallback( this.SeleccionarPlataforma ); this.Invoke( callback ); } else this.controller.SeleccionarPlataforma( this.controller.PlataformaSeleccionada ); }
private void RefrescarVista() { if ( this.InvokeRequired ) { SinParametrosCallback callback = new SinParametrosCallback( this.RefrescarVista ); this.Invoke( callback ); } else { this.ImagenCentral.ImageLocation = this.controller.PlataformaSeleccionada.RutaImagen; int indiceMenor = this.controller.IndicePlataformaSeleccionada - 1; for ( int i = this.titulosPlataformasInferior.Count - 1; i >= 0; i-- ) { if ( indiceMenor < 0 ) { this.titulosPlataformasInferior[ i ].Visible = false; this.titulosPlataformasInferior[ i ].ImageLocation = string.Empty; } else { this.titulosPlataformasInferior[ i ].ImageLocation = this.controller.ListaDePlataformas[ indiceMenor ].RutaImagen; this.titulosPlataformasInferior[ i ].Visible = true; } this.Refresh(); indiceMenor--; } int indiceMayor = this.controller.IndicePlataformaSeleccionada + 1; for ( int i = 0; i < this.titulosPlataformasSuperior.Count; i++ ) { if ( indiceMayor > this.controller.ListaDePlataformas.Count - 1 ) { this.titulosPlataformasSuperior[ i ].Visible = false; this.titulosPlataformasSuperior[ i ].ImageLocation = string.Empty; } else { this.titulosPlataformasSuperior[ i ].ImageLocation = this.controller.ListaDePlataformas[ indiceMayor ].RutaImagen; this.titulosPlataformasSuperior[ i ].Visible = true; } this.Refresh(); indiceMayor++; } } }