Skip to content

Commit

Permalink
1.Extend URI parameters supported by RemoteCanvasActivity(Support
Browse files Browse the repository at this point in the history
TlsPort, CaCertPath and CertSubject) .
2.Changed support for spice scheme in AndroidManifest.xml
3.Changed the IntroTextDialog's title and text.
  • Loading branch information
yixin committed Jun 16, 2015
1 parent d4a2e1f commit 5233d9b
Show file tree
Hide file tree
Showing 4 changed files with 24 additions and 3 deletions.
2 changes: 1 addition & 1 deletion eclipse_projects/bVNC/AndroidManifest.xml
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@
<intent-filter>
<action android:name="android.intent.action.VIEW" />
<category android:name="android.intent.category.DEFAULT" />
<data android:scheme="vnc" />
<data android:scheme="spice" />
</intent-filter>
<intent-filter>
<action android:name="android.intent.action.VIEW" />
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -465,6 +465,24 @@ void parseFromUri(Uri dataUri) {

// we do not currently use API keys


//TlsPort,CaCertPath,CertSubject
String tlsPortParam = dataUri.getQueryParameter(Constants.PARAM_TLS_PORT);
if (tlsPortParam != null) {
int tlsPort = Integer.parseInt(tlsPortParam);
setTlsPort(tlsPort);
}

String caCertPath = dataUri.getQueryParameter(Constants.PARAM_CA_CERT_PATH);
if (caCertPath != null){
setCaCertPath(caCertPath);
}

String certSubject = dataUri.getQueryParameter(Constants.PARAM_CERT_SUBJECT);
if (certSubject != null){
setCertSubject(certSubject);
}

// check if we need to show data-entry screen
// it may be possible to prompt for data later
m_isReadyForConnection = true;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -56,6 +56,9 @@ public class Constants {
public static final String PARAM_COLORMODEL = "ColorModel";
public static final String PARAM_SAVE_CONN = "SaveConnection";
public static final String PARAM_APIKEY = "ApiKey";
public static final String PARAM_TLS_PORT = "TlsPort";
public static final String PARAM_CA_CERT_PATH = "CaCertPath";
public static final String PARAM_CERT_SUBJECT = "CertSubject";

public static final int SECTYPE_NONE = 1;
public static final int SECTYPE_VNC = 2;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -97,7 +97,7 @@ protected void onCreate(Bundle savedInstanceState) {
setContentView(R.layout.intro_dialog);
getWindow().setLayout(LayoutParams.MATCH_PARENT, LayoutParams.MATCH_PARENT);

StringBuilder sb = new StringBuilder(getContext().getResources().getString(R.string.intro_title));
StringBuilder sb = new StringBuilder(getContext().getResources().getString(R.string.spice_intro_title));
setTitle(sb);
sb.delete(0, sb.length());
if (pkgName.contains("SPICE")) {
Expand Down Expand Up @@ -134,7 +134,7 @@ protected void onCreate(Bundle savedInstanceState) {
}

sb.append(getContext().getResources().getString(R.string.intro_header));
sb.append(getContext().getResources().getString(R.string.intro_text));
sb.append(getContext().getResources().getString(R.string.spice_intro_text));
sb.append("\n");
sb.append(getContext().getResources().getString(R.string.intro_version_text));
TextView introTextView = (TextView)findViewById(R.id.textIntroText);
Expand Down

0 comments on commit 5233d9b

Please sign in to comment.