1 | /* |
---|
2 | Tibisay Movil |
---|
3 | |
---|
4 | Copyright (C) 2013 Antonio Araujo (aaraujo@cenditel.gob.ve), Jose Ruiz |
---|
5 | (jruiz@cenditel.gob.ve), Fundacion Centro Nacional de Desarrollo e |
---|
6 | Investigacion en Tecnologias Libres - CENDITEL. |
---|
7 | |
---|
8 | La Fundación CENDITEL concede permiso para usar, copiar, distribuir y/o |
---|
9 | modificar este programa, reconociendo el derecho que la humanidad posee al |
---|
10 | libre acceso al conocimiento, bajo los términos de la licencia de software |
---|
11 | GPL versión 2.0 de la Free Software Foundation. |
---|
12 | |
---|
13 | Este programa se distribuye con la esperanza de que sea util, pero SIN |
---|
14 | NINGUNA GARANTIA; tampoco las implicitas garantias de MERCANTILIDAD o |
---|
15 | ADECUACION A UN PROPOSITO PARTICULAR. |
---|
16 | |
---|
17 | Para mayor información sobre los términos de la licencia ver el archivo |
---|
18 | llamado "gpl-2.0.txt" en ingles. |
---|
19 | */ |
---|
20 | |
---|
21 | package ve.gob.cenditel.tibisaymovil; |
---|
22 | |
---|
23 | import android.os.Bundle; |
---|
24 | import android.app.Activity; |
---|
25 | import android.content.Intent; |
---|
26 | import android.text.method.ScrollingMovementMethod; |
---|
27 | import android.view.Menu; |
---|
28 | import android.view.View; |
---|
29 | import android.view.Window; |
---|
30 | import android.view.View.OnClickListener; |
---|
31 | import android.widget.ImageView; |
---|
32 | import android.widget.LinearLayout; |
---|
33 | import android.widget.TextView; |
---|
34 | |
---|
35 | public class ActivitySignerInfo extends Activity { |
---|
36 | |
---|
37 | @Override |
---|
38 | protected void onCreate(Bundle savedInstanceState) { |
---|
39 | |
---|
40 | //Estilando la barra de titulo |
---|
41 | final boolean customTitleSupported = requestWindowFeature(Window.FEATURE_CUSTOM_TITLE); |
---|
42 | |
---|
43 | super.onCreate(savedInstanceState); |
---|
44 | setContentView(R.layout.activity_signer_info); |
---|
45 | |
---|
46 | //Estilando Barra de titulo |
---|
47 | if(customTitleSupported) |
---|
48 | getWindow().setFeatureInt(Window.FEATURE_CUSTOM_TITLE, R.layout.title_bar); |
---|
49 | |
---|
50 | |
---|
51 | Bundle bundle = getIntent().getExtras(); |
---|
52 | //String name = bundle.getString("name"); |
---|
53 | String cn = bundle.getString("cn"); |
---|
54 | String date = bundle.getString("date"); |
---|
55 | String certificateSerial = bundle.getString("certificateSerial"); |
---|
56 | String validFrom = bundle.getString("validFrom"); |
---|
57 | String validUntil = bundle.getString("validUntil"); |
---|
58 | String certificateIssuer = bundle.getString("certificateIssuer"); |
---|
59 | |
---|
60 | |
---|
61 | TextView signerCN = (TextView) this.findViewById(R.id.signature_errors_text); |
---|
62 | signerCN.setText(cn); |
---|
63 | signerCN.setMovementMethod(ScrollingMovementMethod.getInstance()); |
---|
64 | |
---|
65 | TextView signatureDate = (TextView) this.findViewById(R.id.signature_date); |
---|
66 | signatureDate.setText(date); |
---|
67 | |
---|
68 | TextView certSerial = (TextView) this.findViewById(R.id.certificate_serial); |
---|
69 | certSerial.setText(certificateSerial); |
---|
70 | |
---|
71 | TextView certValidFrom = (TextView) this.findViewById(R.id.certificate_valid_from); |
---|
72 | certValidFrom.setText(validFrom); |
---|
73 | |
---|
74 | TextView certValidUntil = (TextView) this.findViewById(R.id.certificate_valid_until); |
---|
75 | certValidUntil.setText(validUntil); |
---|
76 | |
---|
77 | TextView certCertificateIssuer = (TextView) this.findViewById(R.id.certificate_issuer); |
---|
78 | certCertificateIssuer.setText(certificateIssuer); |
---|
79 | |
---|
80 | |
---|
81 | LinearLayout shareButton = (LinearLayout) this.findViewById(R.id.button_remove_certificate_zone); |
---|
82 | shareButton.setVisibility(LinearLayout.GONE); |
---|
83 | |
---|
84 | |
---|
85 | ImageView backImage = (ImageView) this.findViewById(R.id.button_add_certificate); |
---|
86 | backImage.setVisibility(ImageView.GONE); |
---|
87 | |
---|
88 | TextView buttonFinishText = (TextView) this.findViewById(R.id.button_add_certificate_text); |
---|
89 | buttonFinishText.setVisibility(TextView.GONE); |
---|
90 | |
---|
91 | } |
---|
92 | |
---|
93 | @Override |
---|
94 | public boolean onCreateOptionsMenu(Menu menu) { |
---|
95 | // Inflate the menu; this adds items to the action bar if it is present. |
---|
96 | getMenuInflater().inflate(R.menu.activity_signer_info, menu); |
---|
97 | return true; |
---|
98 | } |
---|
99 | |
---|
100 | } |
---|